From 57b5fd2f1473e7b3ee3b145ad34550a41226672f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=F0=90=B2=93=F0=90=B3=9B=F0=90=B3=AA=F0=90=B3=82?= =?UTF-8?q?=F0=90=B3=90=20=F0=90=B2=80=F0=90=B3=A2=F0=90=B3=A6=F0=90=B3=AB?= =?UTF-8?q?=F0=90=B3=A2=20=F0=90=B2=A5=F0=90=B3=94=F0=90=B3=9B=F0=90=B3=AA?= =?UTF-8?q?=F0=90=B3=8C=F0=90=B3=91=F0=90=B3=96=F0=90=B3=87?= <26771058+KobeArthurScofield@users.noreply.github.com> Date: Thu, 11 Sep 2025 21:31:57 +0800 Subject: [PATCH] Unifying the order of outbound settings --- infra/conf/http.go | 4 ++-- infra/conf/shadowsocks.go | 12 ++++++------ infra/conf/socks.go | 4 ++-- infra/conf/trojan.go | 12 ++++++------ infra/conf/vmess.go | 2 +- 5 files changed, 17 insertions(+), 17 deletions(-) diff --git a/infra/conf/http.go b/infra/conf/http.go index 9232a21c..d4092f88 100644 --- a/infra/conf/http.go +++ b/infra/conf/http.go @@ -53,10 +53,10 @@ type HTTPRemoteConfig struct { type HTTPClientConfig struct { Address *Address `json:"address"` Port uint16 `json:"port"` - Username string `json:"user"` - Password string `json:"pass"` Level uint32 `json:"level"` Email string `json:"email"` + Username string `json:"user"` + Password string `json:"pass"` Servers []*HTTPRemoteConfig `json:"servers"` Headers map[string]string `json:"headers"` } diff --git a/infra/conf/shadowsocks.go b/infra/conf/shadowsocks.go index dac38fb8..a05c1dc5 100644 --- a/infra/conf/shadowsocks.go +++ b/infra/conf/shadowsocks.go @@ -162,10 +162,10 @@ func buildShadowsocks2022(v *ShadowsocksServerConfig) (proto.Message, error) { type ShadowsocksServerTarget struct { Address *Address `json:"address"` Port uint16 `json:"port"` + Level byte `json:"level"` + Email string `json:"email"` Cipher string `json:"method"` Password string `json:"password"` - Email string `json:"email"` - Level byte `json:"level"` IVCheck bool `json:"ivCheck"` UoT bool `json:"uot"` UoTVersion int `json:"uotVersion"` @@ -174,10 +174,10 @@ type ShadowsocksServerTarget struct { type ShadowsocksClientConfig struct { Address *Address `json:"address"` Port uint16 `json:"port"` + Level byte `json:"level"` + Email string `json:"email"` Cipher string `json:"method"` Password string `json:"password"` - Email string `json:"email"` - Level byte `json:"level"` IVCheck bool `json:"ivCheck"` UoT bool `json:"uot"` UoTVersion int `json:"uotVersion"` @@ -190,10 +190,10 @@ func (v *ShadowsocksClientConfig) Build() (proto.Message, error) { { Address: v.Address, Port: v.Port, + Level: v.Level, + Email: v.Email, Cipher: v.Cipher, Password: v.Password, - Email: v.Email, - Level: v.Level, IVCheck: v.IVCheck, UoT: v.UoT, UoTVersion: v.UoTVersion, diff --git a/infra/conf/socks.go b/infra/conf/socks.go index e43781ad..6955001f 100644 --- a/infra/conf/socks.go +++ b/infra/conf/socks.go @@ -72,10 +72,10 @@ type SocksRemoteConfig struct { type SocksClientConfig struct { Address *Address `json:"address"` Port uint16 `json:"port"` + Level uint32 `json:"level"` + Email string `json:"email"` Username string `json:"user"` Password string `json:"pass"` - Email string `json:"email"` - Level uint32 `json:"level"` Servers []*SocksRemoteConfig `json:"servers"` } diff --git a/infra/conf/trojan.go b/infra/conf/trojan.go index 2d29b9cc..d7d4ea17 100644 --- a/infra/conf/trojan.go +++ b/infra/conf/trojan.go @@ -20,9 +20,9 @@ import ( type TrojanServerTarget struct { Address *Address `json:"address"` Port uint16 `json:"port"` - Password string `json:"password"` - Email string `json:"email"` Level byte `json:"level"` + Email string `json:"email"` + Password string `json:"password"` Flow string `json:"flow"` } @@ -30,9 +30,9 @@ type TrojanServerTarget struct { type TrojanClientConfig struct { Address *Address `json:"address"` Port uint16 `json:"port"` - Password string `json:"password"` - Email string `json:"email"` Level byte `json:"level"` + Email string `json:"email"` + Password string `json:"password"` Flow string `json:"flow"` Servers []*TrojanServerTarget `json:"servers"` } @@ -44,9 +44,9 @@ func (c *TrojanClientConfig) Build() (proto.Message, error) { { Address: c.Address, Port: c.Port, - Password: c.Password, - Email: c.Email, Level: c.Level, + Email: c.Email, + Password: c.Password, Flow: c.Flow, }, } diff --git a/infra/conf/vmess.go b/infra/conf/vmess.go index a513f616..c0171c4b 100644 --- a/infra/conf/vmess.go +++ b/infra/conf/vmess.go @@ -119,9 +119,9 @@ type VMessOutboundTarget struct { type VMessOutboundConfig struct { Address *Address `json:"address"` Port uint16 `json:"port"` - ID string `json:"id"` Level uint32 `json:"level"` Email string `json:"email"` + ID string `json:"id"` Security string `json:"security"` Experiments string `json:"experiments"` Receivers []*VMessOutboundTarget `json:"vnext"`