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

Possibility to make the stack executable #2

Closed
jfma7 opened this issue Mar 13, 2022 · 1 comment
Closed

Possibility to make the stack executable #2

jfma7 opened this issue Mar 13, 2022 · 1 comment
Assignees
Labels
enhancement New feature or request

Comments

@jfma7
Copy link

jfma7 commented Mar 13, 2022

Hello:

Sometimes we would like to run code on the stack. For example, a msfvenom reverse shell in C that is written and executed from the stack.

Right now the code does not support stack execution but it could be an option for the future.

Greetings.

@arget13 arget13 added the enhancement New feature or request label Mar 13, 2022
@arget13
Copy link
Owner

arget13 commented Mar 13, 2022

Yes, this I think should be easy to implement. When iterating over the program header entries we would need to check if there is any entry of type GNU_STACK and check if its permissions include execution, if so then add another piece of shellcode to call mprotect().

Since this is a feature request I may take my time to do this.

@arget13 arget13 changed the title [Idea] Possibility to make the stack executable Possibility to make the stack executable Mar 13, 2022
@arget13 arget13 closed this as completed Mar 13, 2022
@arget13 arget13 self-assigned this Mar 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants