Documentation ¶
Overview ¶
Package proxy config to handle set/get functions of the Windows proxy settings
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ProxyEnvVariables = [3]string{
"https_proxy",
"http_proxy",
"no_proxy",
}
HTTP Proxy environment variables possible values
Functions ¶
func SetProxySettings ¶
func StringFromUTF16Ptr ¶
StringFromUTF16Ptr converts a *uint16 C string to a Go String https://github.com/mattn/go-ieproxy/blob/master/utils.go
Types ¶
type HttpDefaultProxyConfig ¶
type HttpDefaultProxyConfig struct {
// contains filtered or unexported fields
}
HttpDefaultProxyConfig represents the WinHTTP machine proxy configuration.
proxy: specifies the proxy addresses to use. bypass: specifies addresses that should be excluded from proxy
func GetDefaultProxySettings ¶
func GetDefaultProxySettings(log log.T) (p HttpDefaultProxyConfig, err error)
GetDefaultProxySettings returns the machine WinHTTP proxy configuration
type HttpIEProxyConfig ¶
type HttpIEProxyConfig struct {
// contains filtered or unexported fields
}
HttpIEProxyConfig represents the Internet Explorer proxy configuration.
auto: indicates if the 'Automatically detect settings' option in IE is enabled enabled: indicates if the 'Use proxy settings for your LAN' option in IE is enabled proxy: specifies the proxy addresses to use. bypass: specifies addresses that should be excluded from proxy
func GetIEProxySettings ¶
func GetIEProxySettings(log log.T) (p HttpIEProxyConfig, err error)
GetIEProxySettings returns the Internet Explorer proxy configuration for the current user
type ProxySettings ¶
type ProxySettings struct {
// contains filtered or unexported fields
}
ProxySettings represents the proxy settings for https_proxy and http_proxy
func ParseProxySettings ¶
func ParseProxySettings(log log.T, proxy string) ProxySettings
ParseProxySettings parses the proxy-list string The Windows proxy server list contains one or more of the following strings ([<scheme>=][<scheme>"://"]<server>[":"<port>]) Internet Explorer and WinHTTP support 4 proxy types for [<scheme>=]: http=, https=, ftp=, or socks=
type WinHttpIEProxyConfig ¶
type WinHttpIEProxyConfig struct {
// contains filtered or unexported fields
}
WinHttpIEProxyConfig represents the Internet Explorer proxy configuration information
fAutoDetect: If TRUE, indicates that the Internet Explorer proxy configuration for the current user specifies "automatically detect settings". lpszAutoConfigUrl: Pointer to a null-terminated Unicode string that contains the auto-configuration URL if the Internet Explorer proxy configuration for the current user specifies "Use automatic proxy configuration". lpszProxy: Pointer to a null-terminated Unicode string that contains the proxy URL if the Internet Explorer proxy configuration for the current user specifies "use a proxy server". lpszProxyBypass: Pointer to a null-terminated Unicode string that contains the optional proxy by-pass server list.
type WinHttpProxyInfo ¶
type WinHttpProxyInfo struct {
// contains filtered or unexported fields
}
WinHttpProxyInfo represents the WinHTTP machine proxy configuration.
lpszProxy: Pointer to a string value that contains the proxy server list. lpszProxyBypass: Pointer to a string value that contains the proxy bypass list.