Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bcov -m patch / Error: string offset exceeds section size #2

Open
Semnodime opened this issue Nov 20, 2021 · 2 comments
Open

bcov -m patch / Error: string offset exceeds section size #2

Semnodime opened this issue Nov 20, 2021 · 2 comments

Comments

@Semnodime
Copy link

$ bcov -m patch -p any -v 5 -i ./foo -o ./foo_patched

terminate called after throwing an instance of 'std::range_error'
  what():  string offset 2425393159 exceeds section size

Further info provided by rizin

fd       3
file     foo
size     0xbb8728
humansz  11.7M
mode     r-x
format   elf64
iorw     false
block    0x100
type     EXEC (Executable file)
arch     x86
baddr    0x400000
binsz    12287845
bintype  elf
bits     64
canary   true
class    ELF64
compiler GCC: (Ubuntu 4.8.4-2ubuntu1~14.04.3) 4.8.4
crypto   false
endian   little
havecode true
intrp    /lib64/ld-linux-x86-64.so.2
laddr    0x0
lang     c++
linenum  false
lsyms    false
machine  AMD x86-64 architecture
maxopsz  16
minopsz  1
nx       true
os       linux
pcalign  0
pic      false
relocs   false
relro    partial
rpath    $ORIGIN:$ORIGIN/foo:$ORIGIN/../foo
sanitiz  false
static   false
stripped true
subsys   linux
va       true
@Semnodime
Copy link
Author

@abenkhadra
Copy link
Owner

Thank you for giving bcov a try.

Yes, I think that the exception is thrown by libelfin as you have mentioned. So I see two options:

  • open an issue (or better a pull request) to resolve this issue on https://github.com/aclements/libelfin. Once resolved, I can backport the fixes to the version of libelfin that is distributed with bcov .

  • open a pull request here that fixes this issue. I'm happy to accept it, if concise and easy to review.

Unfortunately, I cannot offer more help because I have moved on to pursue other projects.

@Semnodime Semnodime changed the title bcov -m patch / string offset exceeds section size bcov -m patch / Error: string offset exceeds section size Dec 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants