TAN
TAN

Reputation: 1

How to find default proxy settings in Ubuntu

I am implementing a program which will capture web browsers GET request, analyze it and then redirects it to the proxy server. To do this I need to find out what are the default proxy settings for my internet connection in UBUNTU. I am using C. Any help would be appreciated.

Upvotes: 0

Views: 3665

Answers (1)

Cédric Julien
Cédric Julien

Reputation: 80771

You can find all the proxy configuration stored by gnome in the GConf-2 keys :

  • /system/http_proxy/use_http_proxy boolean
  • /system/http_proxy/use_authentication boolean
  • /system/http_proxy/host string
  • /system/http_proxy/authentication_user string
  • /system/http_proxy/authentication_password string
  • /system/http_proxy/port int
  • /system/proxy/socks_host string
  • /system/proxy/mode string
  • /system/proxy/ftp_host string
  • /system/proxy/secure_host string
  • /system/proxy/socks_port int
  • /system/proxy/ftp_port int
  • /system/proxy/secure_port int
  • /system/proxy/no_proxy_for list
  • /system/proxy/gopher_host string
  • /system/proxy/gopher_port int

all of them are stored in the /home/user_name/.gconf/ directory. You can access to their value with a call on command line to gconftool-2 or use the C bindings as explained here or there.

Upvotes: 1

Related Questions