Skip to content

stackcmp does not handle esp + [offset] references correctly #23

Open
@jonschz

Description

@jonschz

Stack variables can be addressed both from the base (ebp - [offset]) and the top (esp + offset) of the stack. Debug builds only ever use the former, while release builds use both. This causes two kinds of issues for stackcmp:

  • The top of the stack changes during the execution of a function. This is not currently accounted for, leading to misdetections (both false positives and false negatives).
  • The same variable can be referenced from both the top and the bottom of the stack. These different kinds of references are not matched at the moment.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions