Socks5 proxy
I would like to configure all requests in Miniflux to use a SOCKS5 proxy, and my proxy requires a username and password, for example: socks5://user:[email protected]:1080.
I have read the HTTP_CLIENT_PROXY section in https://miniflux.app/docs/configuration.html, as well as all the related issues, but unfortunately, I haven't found a suitable solution.
For example: https://github.com/miniflux/v2/issues/1229 https://github.com/miniflux/v2/issues/1185 https://github.com/miniflux/v2/issues/543
I have tried all possible methods, including: ALL_PROXY='socks5://user:[email protected]:1080' ALL_PROXY='http://user:[email protected]:1080/' HTTPS_PROXY='socks5://user:[email protected]:1080' HTTPS_PROXY='http://user:[email protected]:1080/'
It seems that the environment variables HTTP_PROXY and HTTPS_PROXY do not support SOCKS5 proxies with usernames and passwords. And the ALL_PROXY variable doesn't seem to have any effect.
Socks proxy and authentication are not implemented.
The official Golang documentation doesn't mention if username/password are supported: https://pkg.go.dev/net/http#ProxyFromEnvironment
Articles that can be used as source of inspiration to implement this feature:
- https://eli.thegreenplace.net/2022/go-and-proxy-servers-part-3-socks-proxies/
- https://www.admfactory.com/how-to-setup-a-proxy-with-authentication-for-http-client-in-golang/
Hello, any progress?
~~Not sure since when, but it looks like ALL_PROXY='socks5://user:[email protected]:1080' now works :)~~
As a matter of fact, using the ALL_PROXY environment variable works for any docker container, even in the format above.
EDIT: Spoke too soon. While ALL_PROXY works inside the container (aka if you do a curl https://myip.wtf you will get the IP of your proxy), making requests from the app are still made from your original IP somehow.
But with HTTPS_PROXY='socks5://user:[email protected]:1080' as OP mentions, does work for me.