TLS client & server: Support Encrypted Client Hello (ECH) (#3813)

b9a72a4a26

---------

Co-authored-by: yuhan6665 <1588741+yuhan6665@users.noreply.github.com>
This commit is contained in:
风扇滑翔翼 2025-07-26 16:47:27 +08:00 committed by GitHub
parent 3fe02a658a
commit fb7a9d8d61
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
10 changed files with 520 additions and 45 deletions

View file

@ -444,6 +444,12 @@ func (c *Config) GetTLSConfig(opts ...Option) *tls.Config {
config.KeyLogWriter = writer
}
}
if len(c.EchConfigList) > 0 || len(c.EchServerKeys) > 0 {
err := ApplyECH(c, config)
if err != nil {
errors.LogError(context.Background(), err)
}
}
return config
}