-
-
Save xkef/b953bc5a199f53a8ece034a51df05fcf to your computer and use it in GitHub Desktop.
SSH into google colab
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
#CODE | |
#Generate root password | |
import random, string | |
password = ''.join(random.choice(string.ascii_letters + string.digits) for i in range(20)) | |
#Download ngrok | |
! wget -q -c -nc https://bin.equinox.io/c/4VmDzA7iaHb/ngrok-stable-linux-amd64.zip | |
! unzip -qq -n ngrok-stable-linux-amd64.zip | |
#Setup sshd | |
! apt-get install -qq -o=Dpkg::Use-Pty=0 openssh-server pwgen > /dev/null | |
#Set root password | |
! echo root:$password | chpasswd | |
! mkdir -p /var/run/sshd | |
! echo "PermitRootLogin yes" >> /etc/ssh/sshd_config | |
! echo "PasswordAuthentication yes" >> /etc/ssh/sshd_config | |
! echo "LD_LIBRARY_PATH=/usr/lib64-nvidia" >> /root/.bashrc | |
! echo "export LD_LIBRARY_PATH" >> /root/.bashrc | |
#Run sshd | |
get_ipython().system_raw('/usr/sbin/sshd -D &') | |
#Ask token | |
print("Copy authtoken from https://dashboard.ngrok.com/auth") | |
import getpass | |
authtoken = getpass.getpass() | |
#Create tunnel | |
get_ipython().system_raw('./ngrok authtoken $authtoken && ./ngrok tcp 22 &') | |
#Print root password | |
print("Root password: {}".format(password)) |
https://sarwiki.informatik.hu-berlin.de/WPA2-Angriff
pip install gpustat
watch -n 0.5 -c gpustat -cp --color
ctrl b : -> :resize-pane -U 30
hashcat -D 2 -w 3 -m 2500 -a 0 '1337.hccapx' 'rockyou.txt' -r '/rules/oscommerce.rule' --potfile-path cracked.pot
wget http://downloads.skullsecurity.org/passwords/rockyou.txt.bz2
bzip2 -d rockyou.txt.bz2
bd4fa7e811a828c7f14af9f5581bcf94:bl0ckch41n42
# create leetspeak rockyou list
cat /content/drive/My\ Drive/rockyou1.txt | hashcat -w4 -r /content/hashcat/rules/unix-ninja-leetspeak.rule --stdout > /content/drive/My\ Drive/combi3_.txt
# create list of numbers
seq 0 100000 > /content/drive/My\ Drive/nrs.txt
# run hashcat in a1 (combi -> lhs leetcode, rhs nrs)
hashcat -m 0 -a 1 -w 4 -o /content/drive/My\ Drive/cracked_out.txt to_crack_hash.txt /content/drive/My\ Drive/combi.txt /content/drive/My\ Drive/nrs.txt -O
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
make session persistent:
open dev console and add: