DataDog / libddwaf-rb

Bindings to libddwaf for Ruby
Other
0 stars 1 forks source link

set correct max string length when running #17

Closed GustavoCaso closed 1 year ago

GustavoCaso commented 1 year ago

When parsing the input we were not using the right constant when calling ruby_to_object. The constant previously used was DDWAF_MAX_CONTAINER_SIZE which is 256. That value was use as the max length a string could be.

That was causing issues with long input types.

Fix: Use the right constant DDWAF_MAX_STRING_LENGTH with a value of 4096

lloeki commented 1 year ago

Note: I'll fix the steep error in a separate PR.