OP 07 April, 2024 - 07:13 PM
Your proxy appears to only use HTTP and not HTTPS
Quote: def getProxies(self):
try:
print(f"[{Fore.LIGHTBLUE_EX}>{Fore.RESET}] Path to proxy file> ")
path = easygui.fileopenbox(
default="*.txt",
filetypes=["*.txt"],
title="Flingster Checker - Select proxy",
multiple=False,
)
try:
open(path, "r", encoding="utf-8")
except:
print(f"[{Fore.LIGHTRED_EX}!{Fore.RESET}] Failed to open proxyfile")
os.system("pause >nul")
quit()
with open(path, "r", encoding="utf-8") as f:
for line in f:
line = line.strip()
if line:
proxy_parts = line.split(':')
if len(proxy_parts) == 2: # IP:Port format
proxy_dict = {'http': f"http://{line}", 'https': f"https://{line}"}
elif len(proxy_parts) == 4: # IP:Port:User:Pass format
proxy_dict = {
'http': f"http://{proxy_parts[2]}:{proxy_parts[3]}@{proxy_parts[0]}:{proxy_parts[1]}",
'https': f"https://{proxy_parts[2]}:{proxy_parts[3]}@{proxy_parts[0]}:{proxy_parts[1]}"
}
else:
print(f"[{Fore.RED}!{Fore.RESET}] Invalid proxy format: {line}")
continue
self.proxies.append(proxy_dict)
print(f"[{Fore.GREEN}+{Fore.RESET}] Loaded {len(self.proxies)} proxies!")
except Exception as e:
print(f"[{Fore.RED}!{Fore.RESET}] {e}")