This commit is contained in:
风扇滑翔翼
2025-08-01 07:35:21 +00:00
committed by GitHub
parent 115825f65c
commit 28bd838318
3 changed files with 23 additions and 11 deletions

View File

@@ -36,7 +36,7 @@ func ApplyECH(c *Config, config *tls.Config) error {
if len(c.EchConfigList) != 0 {
defer func() {
// if failed to get ECHConfig, use an invalid one to make connection fail
if err != nil {
if err != nil && c.EchForceQuery {
ECHConfig = []byte{1, 1, 4, 5, 1, 4}
}
config.EncryptedClientHelloConfigList = ECHConfig