where is problem ? i want check server with proxy list but the code errors out:
__init__() got an unexpected keyword argument 'proxies'
If i exclude the proxy key-word argument, it is working fine.
import os, sys, smtplib
with open('proxy.txt') as urls:
for line in urls:
proxies=line.rstrip()
file = open('sever.txt', 'r') # contains <server>:<user>:<pass>:<port>
for line in file.readlines():
list1 = line.split(':')
try:
server=smtplib.SMTP(list1[0]+':'+list1[3], proxies={"https":proxies})
server.starttls()
server.login(list1[1],list1[2])
server.quit()
with open ("valid.txt", "a") as f:
f.write(str (list1[0]+":"+list1[1]))
except Exception as e:
print e