-
Notifications
You must be signed in to change notification settings - Fork 114
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implements a Proxy Integration #128
base: master
Are you sure you want to change the base?
Conversation
Now, you can use HTTP or SOCKS5 proxies with this bot. In config.yaml under telegram add the two following lines: http_proxy: http://user:[email protected]:3128 https_proxy: http://user:[email protected]:3128 If you are using SOCKS5 proxy, the lines looks like this: http_proxy: socks5://user:[email protected]:3128 https_proxy: socks5://user:[email protected]:3128 Maybe you have to run the following line to install socks-compability: pip install requests[socks]
Official docs for python Ensure your proxy allows dns resolving: Simulation of local resolver
Simulation of remote resolver (through your socks5)
|
@fabianonline Please take a note on this. Very popular feature in Russia |
I have corrected. Thank you, it works! |
It is very useful! Can't wait for merge. |
It doesn't work any more. Neither socks5 nor socks5h make possible to connect to the server. I receive "Got an exception while initially trying to connect to telegram (Listener not running: HTTPSConnectionPool(host='api.telegram.org', port=443)". Is any idea? |
@Spirituss it works for me. |
Works good for me. Probably your socks provider is dead ? |
You should not change DNS servers. Use "socks5h" instead of "socks5" - this makes DNS resolutions made by socks server, not by client ( "socks5" resolves names NOT through proxy ) |
This does not work! Providers intercept requests for addresses 8.8.8.8 and 8.8.4.4 for the operation of blocking services. |
You can take 1.1.1.1 or 1.0.0.1 DNS |
please, see this way (nging proxy) |
Hi, I will finally try to implement that in the master. |
Now, you can use HTTP or SOCKS5 proxies with this bot.
In config.yaml under telegram add the two following lines:
http_proxy: http://user:[email protected]:3128
https_proxy: http://user:[email protected]:3128
If you are using SOCKS5 proxy, the lines looks like this:
http_proxy: socks5://user:[email protected]:3128
https_proxy: socks5://user:[email protected]:3128
Maybe you have to run the following line to install socks-compability:
pip install requests[socks]