Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #86 +/- ##
==========================================
+ Coverage 53.37% 59.25% +5.88%
==========================================
Files 18 18
Lines 622 675 +53
==========================================
+ Hits 332 400 +68
+ Misses 290 275 -15 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
665b0b8 to
9292e9f
Compare
|
huh, I thought progressive lists didn't have any limits? where are the limits defined? |
|
they dont have limits. This adds a guard to decoding so that we dont end up decoding a massive object and OOM ourselves for example we dont have to necessarily include the guard here, but I thought it might be the cleanest option this issue was flagged by one of the security researchers here: |
|
my understanding was that we'd try to enforce bounds one level up at the network later, e.g. don't decode a block larger than X kB I think we have those limits in LH but they are set absurdly high at the moment due to the payload size. We could probably greatly reduce the cap for blocks |
|
I'm coming around to this change, I think we should try to put the length limit checks as "low" and early as possible. I tried putting them into the decode for |
michaelsproul
left a comment
There was a problem hiding this comment.
Impl looks solid, I think this is the way to go.
I'll try cooking up a Lighthouse branch to use these changes.
9292e9f to
742c4c6
Compare
|
rebased on |
|
I checked all your commits and they look good, so I'm happy to merge this. |
Add an optional length limit to
ProgressiveVariableListThis lets Gloas fields easily enforce their spec count limits