mirror of
https://github.com/gnh1201/caterpillar.git
synced 2024-11-26 15:31:45 +00:00
Update server2.py
This commit is contained in:
parent
3060d42a05
commit
b78386db03
|
@ -76,11 +76,11 @@ def conn_string(conn, data, addr):
|
|||
if port == 443:
|
||||
scheme = b'https'
|
||||
|
||||
proxy_server(webserver, port, scheme, conn, addr, data)
|
||||
proxy_server(webserver, port, scheme, url, conn, addr, data)
|
||||
except Exception as e:
|
||||
pass
|
||||
|
||||
def proxy_server(webserver, port, scheme, conn, addr, data):
|
||||
def proxy_server(webserver, port, scheme, url, conn, addr, data):
|
||||
try:
|
||||
headers = {
|
||||
"User-Agent": "WebProxyTest",
|
||||
|
@ -91,6 +91,7 @@ def proxy_server(webserver, port, scheme, conn, addr, data):
|
|||
"server": webserver.decode("utf-8"),
|
||||
"port": str(port),
|
||||
"scheme": scheme.decode("utf-8"),
|
||||
"url": url.decode("utf-8"),
|
||||
"length": str(len(data)),
|
||||
"chunksize": str(buffer_size),
|
||||
"datetime": datetime.now().strftime("%Y-%m-%d %H:%M:%S.%f")
|
||||
|
|
Loading…
Reference in New Issue
Block a user