0
mirror of https://github.com/XTLS/Xray-core.git synced 2025-06-12 19:39:35 +03:00

Add fingerprint xray_random (#1540)

* Add fingerprint xray_random

xray_random means to pick a random uTLS fingerprint at the core startup
This way, the fingerprint is stable for a user for some days. While there is no identifiable signature for the whole xray community

* Fingerprint "random" refine

Exclude old fingerprint from RNG
This commit is contained in:
yuhan6665
2023-01-20 23:36:08 -05:00
committed by GitHub
parent 77d2f9edd7
commit 3fb67f065a
5 changed files with 56 additions and 18 deletions

View File

@ -75,7 +75,7 @@ func getHTTPClient(ctx context.Context, dest net.Destination, streamSettings *in
}
var cn tls.Interface
if fingerprint, ok := tls.Fingerprints[tlsConfigs.Fingerprint]; ok {
if fingerprint, ok := tls.GetFingerprint(ctx, tlsConfigs.Fingerprint); ok {
cn = tls.UClient(pconn, tlsConfig, fingerprint).(*tls.UConn)
} else {
cn = tls.Client(pconn, tlsConfig).(*tls.Conn)