If the load address is not set to 0 in libc elf, the offset of symbols cannot retrieve correctly #2648
Closed
Description
Hi,
When I tried to deploy bcc in an embedded system, i found that invalid argument error orrcured. After troubleshooting, I found that is the offset of 'malloc'(i tried to execute memleak) in libc.so is bigger than the size of libc. That is because the load address is not set to 0 in my libc, so the value of malloc in symbol table is not offset. What i have done to fix it is retrieve the base load address from programe header first, then substracted the value by the base address.
Metadata
Assignees
Labels
No labels