mirror of
https://github.com/p4gefau1t/trojan-go.git
synced 2024-04-21 12:21:34 +00:00
38 lines
864 B
Go
38 lines
864 B
Go
package client
|
|
|
|
import "github.com/p4gefau1t/trojan-go/config"
|
|
|
|
type MuxConfig struct {
|
|
Enabled bool `json,yaml:"enabled"`
|
|
}
|
|
|
|
type WebsocketConfig struct {
|
|
Enabled bool `json,yaml:"enabled"`
|
|
}
|
|
|
|
type RouterConfig struct {
|
|
Enabled bool `json,yaml:"enabled"`
|
|
}
|
|
|
|
type ShadowsocksConfig struct {
|
|
Enabled bool `json,yaml:"enabled"`
|
|
}
|
|
|
|
type TransportPluginConfig struct {
|
|
Enabled bool `json,yaml:"enabled"`
|
|
}
|
|
|
|
type Config struct {
|
|
Mux MuxConfig `json,yaml:"mux"`
|
|
Websocket WebsocketConfig `json,yaml:"websocket"`
|
|
Router RouterConfig `json,yaml:"router"`
|
|
Shadowsocks ShadowsocksConfig `json,yaml:"shadowsocks"`
|
|
TransportPlugin TransportPluginConfig `json:"transport_plugin" yaml:"transport-plugin"`
|
|
}
|
|
|
|
func init() {
|
|
config.RegisterConfigCreator(Name, func() interface{} {
|
|
return new(Config)
|
|
})
|
|
}
|