-
Notifications
You must be signed in to change notification settings - Fork 275
Description
Version and Platform (required):
- Binary Ninja Version: 5.3.9003-dev
- Edition: Ultimate
- OS: macOS
- OS Version: 26.2
- CPU Architecture: aarch64
Bug Description:
When I used WARP to save signatures for printf, and then used those signatures to match printf in a new file, the varargs portion of the arguments to printf was not applied. Notably, it gave printf the signature void printf(char* format); missing the varargs. The varargs are a critical part of the type signature, as they indicate to analysis that the remaining arguments (at least in my architecture's case) are passed via the stack and not registers.
Steps To Reproduce:
- Open a stripped binary containing printf
- Navigate to printf
- Name and type printf as
void printf(char* format, ...); - Use
WARP > Include Functionto mark printf for export WARP > Create > From Current Viewand set included functions to SelectedWARP > Load Fileon the generated signatures you just saved- Re-open stripped binary
- Observe printf is detected but now has the signature
void printf(char* format);with no varargs
Expected Behavior:
I expected the function signature I specified to be saved as-is and for the varargs to be reapplied.
Additional Information:
Signatures were generated for a binary using a custom arch plugin which can be provided if requested