Skip to content

[BUG] Null pointer dereference vulnerability in classifier.c #2649

@shiyujunz

Description

@shiyujunz

I have found a potential null pointer dereference bug in classifier.c and would like to report it to the maintainers. This vulnerability has the potential to cause unexpected application behavior, crashes. Can you please help me check it? Thank you for your effort and patience!

Below is the execution sequence of the program that may produce null pointer dereference bug .
First, in file classifier.c, function get_regression_values calls strchr on line 23, which may return null. p is assigned to null.
Second, p is dereferenced on line 24, which leads to a null pointer dereference vulnerability.

Image

In addition, in other places where the strchr function is used in this project, there are judgments about whether the function's return value is null or not. For example, in the file getopt.c, on line 169, the return value of the function strchr is judged.

Image

Thank you very much for reading and I look forward to hearing from you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions