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

[shellcraft] Avoid recursive walk of all templates for command line #1651

Merged
merged 4 commits into from
Jul 28, 2020

Conversation

heapcrash
Copy link
Collaborator

@heapcrash heapcrash commented Jul 27, 2020

This mechanism is much faster (up to ~5x)

Before: pwn shellcraft i386.linux.sh 0.57s user 1.47s system 20% cpu 10.060 total
After: pwn shellcraft i386.linux.sh 0.42s user 0.27s system 25% cpu 2.722 total

This also has the side-effect of allowing e.g. shellcraft amd64.open which mimics the in-Python behavior:

$ shellcraft amd64.open '/dev/null' 0 0
6a6c48b82f6465762f6e756c504889e731d231f66a02580f05

Fixes #1650

@heapcrash
Copy link
Collaborator Author

heapcrash commented Jul 28, 2020

PyLint failed, but it failed because we removed a warning. I need to add logic to that checker to only show added warnings.

@heapcrash heapcrash merged commit 8080af8 into Gallopsled:dev Jul 28, 2020
@heapcrash heapcrash deleted the shellcraft-faster-enumeration branch May 31, 2021 20:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Pwn shellcraft is slower than needed
1 participant