DataDog / dd-native-appsec-js

Node.js bindings for libddwaf
Apache License 2.0
1 stars 3 forks source link

ddwaf_object conversion #69

Closed simon-id closed 1 year ago

simon-id commented 1 year ago
simon-id commented 1 year ago

My idea to fix this in a nicer way: In convert.cpp, replace coerceBoolToInt by coerceToString, and only set it to true when used for ddwaf_run in main.cpp That way scalar values will not be coerced for rules, rules_data, and toggle rules, but will be converted to strings for ddwaf_run because it doesn't have automated conversion internally.