qilingframework / qiling

A True Instrumentable Binary Emulation Framework
https://qiling.io
GNU General Public License v2.0
5.06k stars 737 forks source link

When I add ql.os.set_api('strcasecmp', pre_strcasecmp, QL_INTERCEPT.ENTER), it reports Syscall ERROR: ql_syscall_brk DEBUG: Invalid memory mapping (UC_ERR_MAP) #1468

Open DockTree opened 4 months ago

DockTree commented 4 months ago

*Describe the bug When I add ql.os.set_api('strcasecmp', pre_strcasecmp, QL_INTERCEPT.ENTER), it reports Syscall ERROR: ql_syscall_brk DEBUG: Invalid memory mapping (UC_ERR_MAP)

Sample Code

ql.os.set_api('strcasecmp', pre_strcasecmp, QL_INTERCEPT.ENTER)

no matter what code in pre_strcasecmp, it's always an error.

Screenshots image

elicn commented 2 months ago

There is context missing. If possible, please re-run the example with debug verbosity and upload the log.