Versions in this module Expand all Collapse all v1 v1.19.8 Feb 20, 2024 v1.19.7 Feb 20, 2024 Changes in this version type Config + DNS *DNS + Experimental *Experimental + Hosts *trie.DomainTrie + Inbounds []C.Inbound + Profile *Profile + Providers map[string]providerTypes.ProxyProvider + Tunnels []Tunnel + Users []auth.AuthUser + func Parse(buf []byte) (*Config, error) + func ParseRawConfig(rawCfg *RawConfig) (*Config, error) + type Controller struct + ExternalController string + ExternalUI string + Secret string + type DNS struct + DefaultNameserver []dns.NameServer + Enable bool + EnhancedMode C.DNSMode + FakeIPRange *fakeip.Pool + Fallback []dns.NameServer + FallbackFilter FallbackFilter + Hosts *trie.DomainTrie + IPv6 bool + Listen string + NameServer []dns.NameServer + NameServerPolicy map[string]dns.NameServer + SearchDomains []string + type Experimental struct + UDPFallbackMatch bool + type FallbackFilter struct + Domain []string + GeoIP bool + GeoIPCode string + IPCIDR []*net.IPNet type General + Authentication []string + IPv6 bool + Interface string + RoutingMark int + type LegacyInbound struct + AllowLan bool + BindAddress string + MixedPort int + Port int + RedirPort int + SocksPort int + TProxyPort int + type Profile struct + StoreFakeIP bool + StoreSelected bool + type RawConfig struct + AllowLan bool + Authentication []string + BindAddress string + DNS RawDNS + Experimental Experimental + ExternalController string + ExternalUI string + Hosts map[string]string + IPv6 bool + Inbounds []C.Inbound + Interface string + LogLevel log.LogLevel + MixedPort int + Mode T.TunnelMode + Port int + Profile Profile + Proxy []map[string]any + ProxyGroup []map[string]any + ProxyProvider map[string]map[string]any + RedirPort int + RoutingMark int + Rule []string + Secret string + SocksPort int + TProxyPort int + Tunnels []Tunnel + func UnmarshalRawConfig(buf []byte) (*RawConfig, error) + type RawDNS struct + DefaultNameserver []string + Enable bool + EnhancedMode C.DNSMode + FakeIPFilter []string + FakeIPRange string + Fallback []string + FallbackFilter RawFallbackFilter + IPv6 *bool + Listen string + NameServer []string + NameServerPolicy map[string]string + SearchDomains []string + UseHosts bool + type RawFallbackFilter struct + Domain []string + GeoIP bool + GeoIPCode string + IPCIDR []string + type Tunnel tunnel + func (t *Tunnel) UnmarshalYAML(unmarshal func(any) error) error v0 v0.7.1 Sep 21, 2018 v0.7.0 Sep 16, 2018 v0.6.0 Aug 12, 2018 Changes in this version + var ModeMapping = map[string]Mode + func Init() + type Config struct + func Instance() *Config + func (c *Config) General() General + func (c *Config) Parse() error + func (c *Config) Proxies() map[string]C.Proxy + func (c *Config) Report() chan<- interface{} + func (c *Config) Rules() []C.Rule + func (c *Config) SetLogLevel(level C.LogLevel) + func (c *Config) SetMode(mode Mode) + func (c *Config) Subscribe() observable.Subscription + func (c *Config) UpdateGeneral(general General) + func (c *Config) UpdateProxy(pc ProxyConfig) + func (c *Config) UpdateRules() error + type Event struct + Payload interface{} + Type string + type General struct + AllowLan bool + LogLevel C.LogLevel + Mode Mode + Port int + RedirPort int + SocksPort int + type Mode int + const Direct + const Global + const Rule + func (m Mode) String() string + type ProxyConfig struct + AllowLan *bool + Port *int + RedirPort *int + SocksPort *int