This commit is contained in:
风扇滑翔翼
2025-08-01 09:09:17 +00:00
committed by GitHub
parent 28bd838318
commit c90b9b054c
5 changed files with 119 additions and 57 deletions

View File

@@ -412,8 +412,8 @@ type TLSConfig struct {
MasterKeyLog string `json:"masterKeyLog"`
ServerNameToVerify string `json:"serverNameToVerify"`
VerifyPeerCertInNames []string `json:"verifyPeerCertInNames"`
ECHConfigList string `json:"echConfigList"`
ECHServerKeys string `json:"echServerKeys"`
ECHConfigList string `json:"echConfigList"`
ECHForceQuery bool `json:"echForceQuery"`
}
@@ -486,8 +486,6 @@ func (c *TLSConfig) Build() (proto.Message, error) {
}
config.VerifyPeerCertInNames = c.VerifyPeerCertInNames
config.EchConfigList = c.ECHConfigList
if c.ECHServerKeys != "" {
EchPrivateKey, err := base64.StdEncoding.DecodeString(c.ECHServerKeys)
if err != nil {
@@ -496,6 +494,7 @@ func (c *TLSConfig) Build() (proto.Message, error) {
config.EchServerKeys = EchPrivateKey
}
config.EchForceQuery = c.ECHForceQuery
config.EchConfigList = c.ECHConfigList
return config, nil
}