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

Do not attempt to populate the libraries used by statically-linked binaries #1043

Merged

Conversation

zachriggle
Copy link
Member

This causes a background instance to be spawned, which is not intended.

@zachriggle zachriggle added the bug label Sep 27, 2017
@zachriggle zachriggle added this to the 3.9.0 milestone Sep 27, 2017
@zachriggle zachriggle self-assigned this Sep 27, 2017
@zachriggle zachriggle force-pushed the statically-linked-populate-libraries branch from 9ffef8e to df62ccf Compare September 27, 2017 22:50
…naries

This causes a background instance to be spawned, which is not intended.
@zachriggle zachriggle force-pushed the statically-linked-populate-libraries branch from df62ccf to a535bec Compare September 27, 2017 22:52
@zachriggle zachriggle merged commit b234b31 into Gallopsled:stable Sep 29, 2017
@zachriggle
Copy link
Member Author

zachriggle commented Sep 29, 2017

This issue can be demonstrated pretty easily by making a "dynamically linked" (read: PT_DYN) ELF which doesn't have a PT_INTERP section.

A better fix is likely to invoke the interpreter directly -- but this will cause weird issues with foreign architecture binaries / QEMU / binfmt_misc.

from pwn import *

elf_path = make_elf(asm(shellcraft.infloop()), shared=True, extract=False)

ELF(elf_path) # Invokes the elf with LD_TRACE_LOADED_OBJECTS=1

@zachriggle
Copy link
Member Author

FYI @idolf I had intended this to merge before 3.9.1

@zachriggle zachriggle deleted the statically-linked-populate-libraries branch September 29, 2017 21:38
@TethysSvensson
Copy link
Contributor

Do you want me to cut 3.9.2?

@zachriggle
Copy link
Member Author

If it's not a big hassle. This is relevant for a particular CTF challenge that's not released yet.

@TethysSvensson
Copy link
Contributor

Sure, I'll cut it today.

@TethysSvensson
Copy link
Contributor

Done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants