Skip to content

recursive from_msgpack implementation will stack overflow #537

@xgzeng

Description

@xgzeng

from_msgpack function(etc) parses data recursively, which will cause stack overflow when process deep nested structure.
It will be DOS vulnerabilities, if we use library to process data from outside.

Following is example code to generate malicious data. msgpack_pack_array is not shown here.

for (int i = 0; i < 10000; ++i) {
    msgpack_pack_array(buffer, 1);
}
msgpack_pack_array(buffer, 0);

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions