mirror of https://github.com/dnomd343/ProxyC
dnomd343
2 years ago
1 changed files with 26 additions and 23 deletions
@ -1,29 +1,32 @@ |
|||
#!/usr/bin/env python3 |
|||
# -*- coding: utf-8 -*- |
|||
|
|||
import time |
|||
from Builder import Builder |
|||
from Basis.Logger import logging |
|||
|
|||
import ProxyBuilder as Builder |
|||
import ProxyDecoder as Decoder |
|||
import ProxyFilter as Filter |
|||
import Check as Checker |
|||
proxy = { |
|||
'type': 'ss', |
|||
'info': { |
|||
'server': '127.0.0.1', |
|||
'port': 12345, |
|||
'passwd': 'dnomd343', |
|||
'method': 'aes-128-ctr', |
|||
'plugin': None |
|||
} |
|||
} |
|||
|
|||
# ret = Decoder.decode(url) |
|||
# print(ret) |
|||
client = Builder(proxy) |
|||
|
|||
info = { |
|||
'type': 'hysteria', |
|||
'server': '127.0.0.1', |
|||
'port': 443, |
|||
'protocol': 'faketcp', |
|||
'obfs': '770091573', |
|||
'auth': 'dnomd343', |
|||
'sni': 'local.343.re' |
|||
} |
|||
logging.critical(client.id) |
|||
logging.critical(client.proxyType) |
|||
logging.critical(client.proxyInfo) |
|||
logging.critical(client.socksAddr) |
|||
logging.critical(client.socksPort) |
|||
|
|||
status, ret = Filter.filte(info, isExtra = True) |
|||
print(status) |
|||
print(ret) |
|||
time.sleep(5) |
|||
logging.critical(client.status()) |
|||
|
|||
result = Checker.proxyTest({ |
|||
'check': ['http'], |
|||
'info': ret |
|||
}) |
|||
print(result) |
|||
client.destroy() |
|||
logging.critical(client.status()) |
|||
logging.critical('Client output:\n' + str(client.output)) |
|||
|
Loading…
Reference in new issue