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

Add a python/exec payload to execute OS commands #19528

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

zeroSteiner
Copy link
Contributor

This adds a single ARCH_PYTHON payload that is capable of executing arbitrary OS commands. It uses subprocess.Popen to execute commands through a shell environment as defined in the docs. Tested with Python 2.7, 3.4 and 3.12.

Verification

  • Start msfconsole
  • use payload/python/exec
  • set CMD somecommand (try and trick it with quotes and what not, make sure it works as intended)

@smcintyre-r7 smcintyre-r7 added module rn-modules release notes for new or majorly enhanced modules labels Oct 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
module rn-modules release notes for new or majorly enhanced modules
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants