openfortivpn icon indicating copy to clipboard operation
openfortivpn copied to clipboard

Using authenticated proxy

Open diegoortizmatajira opened this issue 5 years ago • 5 comments

I'm using openfortivpn on corporate network, where I have to use authenticated proxy I use this script to initialize proxy settings

PROXY="http://user:[email protected]:8080"
export {http,https,ftp,rsync}_proxy=$PROXY
export {HTTP,HTTPS,FTP,RSYNC}_PROXY=$PROXY

Often I have to connect to VPN using forticlient VPN, but when it comes I have to use the VPN, I need to connect to a proxyless access point (my phone) and remove all proxy settings in order to use openfortivpn.

I've tried using the proxy server IP instead of hostname (proxy.company.com) without success.

When I try to use openfortivpn with proxy settings the app doesn't show any text it just prints an empty line on the terminal. Using the verbose option I've got:

DEBUG:  openfortivpn 1.8.1
DEBUG:  Loaded config file "/home/user/path/config-file.config".
DEBUG:  Config host = "186.116.XX.XX"
DEBUG:  Config realm = ""
DEBUG:  Config port = "443"
DEBUG:  Config username = "vpn_user"
DEBUG:  Config password = "********"
DEBUG:  Resolving gateway host ip
DEBUG:  Establishing ssl connection
DEBUG:  server_addr: 186.116.XX.XX
DEBUG:  server_port: 443
DEBUG:  gateway_addr: 186.116.XX.XX
DEBUG:  gateway_port: 443
ERROR:  connect: Connection timed out
INFO:   Closed connection to gateway.
DEBUG:  server_addr: 186.116.XX.XX
DEBUG:  server_port: 443
DEBUG:  gateway_addr: 186.116.XX.XX
DEBUG:  gateway_port: 443

Information about my configuration OS: Manjaro Linux x86_64 Kernel: 4.19.28-1-MANJARO Package: openfortivpn from AUR

diegoortizmatajira avatar Mar 26 '19 19:03 diegoortizmatajira

As far as I know authentication is not implemented yet in proxy support code: ccaa359

DimitriPapadopoulos avatar Mar 26 '19 22:03 DimitriPapadopoulos

yes, authentication is one of the items on the agenda for improving the proxy support in #226

mrbaseman avatar Mar 26 '19 22:03 mrbaseman

I vote +1 for this feature ;)

Raoul555 avatar May 25 '21 17:05 Raoul555

For reference I managed to overcome this by running a local squid proxy that is using the authenticated proxy as a parent. Sample squid.conf:

http_port 3128
http_access allow all
cache_peer parent.proxy.example.com  parent   8080      0  no-query no-digest default login=username:password
never_direct allow all

jmartasek avatar Jan 24 '22 19:01 jmartasek

We probably need libproxy for proper proxy support.

DimitriPapadopoulos avatar Mar 28 '22 15:03 DimitriPapadopoulos