Documentation
¶
Index ¶
Constants ¶
View Source
const ( TransportTCP = "tcp" TransportUDP = "udp" TransportAll = "all" )
Rule transports
View Source
const ( ActionDirect = "direct" ActionProxy = "proxy" ActionBlock = "block" )
Rule actions
View Source
const ( ProxyTypeHTTP = "http" ProxyTypeHTTPS = "https" ProxyTypeShadowSocks = "shadowsocks" ProxyTypeSocks4 = "socks4" ProxyTypeSocks5 = "socks5" ProxyTypeSSH = "ssh" )
Proxy types
View Source
const ( AuthenticationMethodNone = "none" AuthenticationMethodPassword = "password" AuthenticationMethodIntegrated = "integrated" AuthenticationMethodGssAPI = "gssapi" AuthenticationMethodKey = "key" )
Authentication methods
View Source
const DefaultVersion = 535
DefaultVersion for RuleSet
Variables ¶
View Source
var Ciphers = []string{
"aes128-ctr",
"aes192-ctr",
"aes256-ctr",
"aes128-gcm@openssh.com",
"aes256-gcm@openssh.com",
"arcfour256",
"arcfour128",
"aes128-cbc",
"3des-cbc",
"blowfish-cbc",
"cast128-cbc",
"aes192-cbc",
"aes256-cbc",
"arcfour",
}
Ciphers suites
View Source
var ShadowSocksCiphers = []string{
"rc4",
"rc4-md5",
"aes-128-cfb",
"aes-192-cfb",
"aes-256-cfb",
"aes-128-ctr",
"aes-192-ctr",
"aes-256-ctr",
"bf-cfb",
"camellia-128-cfb",
"camellia-192-cfb",
"camellia-256-cfb",
"aes-128-gcm",
"aes-192-gcm",
"aes-256-gcm",
"chacha20-ietf-poly1305",
}
ShadowSocksCiphers suites
Functions ¶
This section is empty.
Types ¶
type HostNameRangeColl ¶
type HostNameRangeColl struct {
HostNameRanges []HostWildcard `xml:"hostname,omitempty"`
}
HostNameRangeColl element
type HostWildcard ¶
type HostWildcard struct {
Wildcard string `xml:"wildcard,attr"`
}
HostWildcard element
type IPRangeColl ¶
type IPRangeColl struct {
IPRanges []IPRange `xml:"ip_range,omitempty"`
}
IPRangeColl element
type PortRangeColl ¶
type PortRangeColl struct {
PortRanges []PortRange `xml:"port_range,omitempty"`
}
PortRangeColl element
type ProgramColl ¶
type ProgramColl struct {
Programs []Program `xml:"program,omitempty"`
}
ProgramColl element
type ProxyChain ¶
ProxyChain element
type ProxyServer ¶
type ProxyServer struct { Name string `xml:"name,attr"` Type string `xml:"type,attr"` HostName string `xml:"hostname,attr"` Port uint `xml:"port,attr"` AuthMethod string `xml:"auth_method,attr"` PrefferedCipher string `xml:"pref_cipher,attr,omitempty"` ShadowSocksCipher string `xml:"ss_cipher,attr,omitempty"` Default bool `xml:"is_default,attr"` UserName string `xml:"username,attr,omitempty"` Password string `xml:"password,attr,omitempty"` Key string `xml:"key,attr,omitempty"` HostKey string `xml:"hostkey,attr,omitempty"` }
ProxyServer element
type RemoteDNSExceptionsColl ¶
type RemoteDNSExceptionsColl struct {
RemoteDNSExceptions []HostWildcard `xml:"remote_dns_exception,omitempty"`
}
RemoteDNSExceptionsColl element
type RoutingRule ¶
type RoutingRule struct { Name string `xml:"name,attr"` Action string `xml:"action,attr"` RemoteDNS bool `xml:"remote_dns,attr"` Disabled bool `xml:"disabled,attr"` Transports string `xml:"transports,attr"` ProxiesOrChains []NamedRef `xml:"proxy_or_chain,omitempty"` Programs *ProgramColl `xml:"programs,omitempty"` PortRanges *PortRangeColl `xml:"ports,omitempty"` IPRanges *IPRangeColl `xml:"ip_addresses,omitempty"` HostNames *HostNameRangeColl `xml:"hostnames,omitempty"` RemoteDNSExceptions *RemoteDNSExceptionsColl `xml:"remote_dns_exceptions,omitempty"` }
RoutingRule element
type RuleSet ¶
type RuleSet struct { XMLName xml.Name `xml:"proxycap_ruleset"` Version uint `xml:"version,attr"` ProxyServers []ProxyServer `xml:"proxy_servers>proxy_server"` ProxyChains []ProxyChain `xml:"proxy_chains>proxy_chain,omitempty"` RoutingRules []RoutingRule `xml:"routing_rules>routing_rule"` }
RuleSet element
Click to show internal directories.
Click to hide internal directories.