mirror of
https://github.com/nadoo/glider.git
synced 2026-11-19 07:09:42 +08:00
trojan: add new scheme trojanc (trojan cleartext)
This commit is contained in:
1 parent
175ef16a5c
commit
40ddd1be3a
8 files changed
+71
-29
No files matched your search
+14
-7
@@ -18,20 +18,27 @@ import (
|
||||
|
||||
// Trojan is a base trojan struct.
|
||||
type Trojan struct {
|
||||
dialer proxy.Dialer
|
||||
proxy proxy.Proxy
|
||||
addr string
|
||||
pass [56]byte
|
||||
dialer proxy.Dialer
|
||||
proxy proxy.Proxy
|
||||
addr string
|
||||
pass [56]byte
|
||||
|
||||
clearText bool
|
||||
|
||||
tlsConfig *tls.Config
|
||||
|
||||
serverName string
|
||||
skipVerify bool
|
||||
tlsConfig *tls.Config
|
||||
certFile string
|
||||
keyFile string
|
||||
|
||||
certFile string
|
||||
keyFile string
|
||||
}
|
||||
|
||||
func init() {
|
||||
proxy.RegisterDialer("trojan", NewTrojanDialer)
|
||||
proxy.RegisterServer("trojan", NewTrojanServer)
|
||||
proxy.RegisterDialer("trojanc", NewClearTextDialer) // cleartext
|
||||
proxy.RegisterServer("trojanc", NewClearTextServer) // cleartext
|
||||
}
|
||||
|
||||
// NewTrojan returns a trojan proxy.
|
||||
|
||||
Reference in new issue
Block a user