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

Fixes attachment of dns uprobes when libc is stripped of symbol names #666

Merged
merged 1 commit into from
Jun 7, 2022
Merged

Conversation

JeremyMahieu
Copy link
Contributor

@JeremyMahieu JeremyMahieu commented Jun 6, 2022

On arch linux, and likely other distros, libc.so.6 is shipped stripped by default. this means .symtab does not exist and elffile.Symbols() returns with "no symbol section" error resulting in dns uprobes being unable to be attached. This pr changes the call to .DynamicSymbols() to alleviate this problem. This ensures a broader range of distro compatibility.

EBPF-DNS: Failed to find symbol for uprobe uprobe/getaddrinfo : no symbol section
EBPF-DNS: Failed to find symbol for uprobe uretprobe/getaddrinfo : no symbol section
EBPF-DNS: Failed to find symbols for uprobes.
EBPF-DNS: Unable to attach ebpf listener.```

@JeremyMahieu JeremyMahieu changed the title fixes attachment of dns uprobes when libc is stripped of symbol names… Fixes attachment of dns uprobes when libc is stripped of symbol names Jun 6, 2022
@gustavo-iniguez-goya gustavo-iniguez-goya merged commit 2ca8bb4 into evilsocket:master Jun 7, 2022
@gustavo-iniguez-goya
Copy link
Collaborator

Thank you @JeremyMahieu ! Tested on Debian (symbols stripped) and Fedora 3x (not stripped) 👍

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

Successfully merging this pull request may close these issues.

2 participants