I'm trying to make a program that gets a proxy list from Charon, which looks like
202.43.178.31:3128
202.109.80.106:8080
193.165.79.13:3128
222.177.13.25:3128
125.40.181.247:8080
222.134.33.146:8080
and make it into one that can work with proxychains
http 141.219.252.132 68664
http 118.174.0.155 8080
http 91.194.246.169 8080
http 91.194.246.81 8080
http 201.245.110.138 8888
I did this, but I need some way to determine the proxy type. Right now my program puts 'http' in front of everything, at most checks if the proxy works and if it does not comments it out. Any suggestions to find the proxy type in Python (and make it as portable as possible, as in not using any linux-specific tools)?
One way to do it would be to connect to an external server and retrieve the HTTP header and get the information from that. You could also find some site that checks the proxy type when you connect to it and scrape the page for the answer.
I don't think it's possible without some kind of server you connect to, as the headers aren't passed back to the client, only the server.
Another, less appropriate way to do it might be to try connecting as each type of proxy and see which one works.
I hope this can help you in the right direction.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With