Recursion stack-overflow in parsing YAML configuration
A YAML configuration can be crafted (for example, by a fuzzer) that causes the YAML parser to recurse to a depth where a stack-overflow occurs. This appears to be at about 180. Our default configuration goes to a depth of about 16.
Suggested fix: track the recursion limit and abort at some level, for example 128 should be OK.
Longer term fix if we every have a config that needs more recursion would be to refactor into a loop.
Updated by Victor Julien almost 4 years ago
Additional commit to include https://github.com/OISF/suricata/commit/fe1d36ec7eff8fecbe39f4d7447c0ab24a9d37ee