[ovs-dev] [PATCH] odp-util: Return an error on actions overflow while parsing from string.

Ilya Maximets i.maximets at ovn.org
Mon Jun 14 15:57:04 UTC 2021


On 6/14/21 5:53 PM, Ilya Maximets wrote:
> On 6/14/21 5:40 PM, Ben Pfaff wrote:
>> On Mon, Jun 14, 2021 at 05:17:01PM +0200, Ilya Maximets wrote:
>>> We don't need to continue parsing if already oversized.  This is not
>>> very important, but fuzzer times out while parsing very long list of
>>> actions.
>>>
>>> Reported-at: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=29190
>>> Signed-off-by: Ilya Maximets <i.maximets at ovn.org>
>>
>> Is {1..8190} portable shell syntax?  It's not in POSIX.  The "dash"
>> shell doesn't understand it.
>>
>> I'd tend to write $(seq 8190) instead.
> 
> Good point.  Thanks for spotting!
> I'll fix that in v2.

And yes, FreeBSD CI failed with this check, so I should have spotted
this myself, sorry for the noise.

> 
>>
>>> +data_valid=$(  printf 'set(encap()),%.0s' {1..8190})
>>> +data_invalid=$(printf 'set(encap()),%.0s' {1..8191})
>>
>> Thanks,
>>
>> Ben.
>>
> 



More information about the dev mailing list