Code cleanup for PIP compliance, also added residential proxy usage examples

This commit is contained in:
2023-10-12 15:31:22 -04:00
parent 4d6294a20b
commit cc02b8df44
6 changed files with 109 additions and 26 deletions

View File

@@ -48,7 +48,12 @@ blackholes = {
}
}
def check(proxy):
def check(proxy: str):
'''
Check if a proxy is blackholed.
:param proxy: the proxy to check in the format of ip:port
'''
proxy_ip = proxy.split(':')[0]
formatted_ip = ipaddress.ip_address(proxy_ip).reverse_pointer
for blackhole in blackholes: