MCPcopy
hub / github.com/XTLS/REALITY / deriveSecret

Function deriveSecret

tls13/tls13.go:51–56  ·  view source on GitHub ↗
(hash func() H, secret []byte, label string, transcript hash.Hash)

Source from the content-addressed store, hash-verified

49}
50
51func deriveSecret[H hash.Hash](hash func() H, secret []byte, label string, transcript hash.Hash) []byte {
52 if transcript == nil {
53 transcript = hash()
54 }
55 return ExpandLabel(hash, secret, label, transcript.Sum(nil), transcript.Size())
56}
57
58const (
59 resumptionBinderLabel = "res binder"

Callers 12

ResumptionBinderKeyMethod · 0.85
HandshakeSecretMethod · 0.85
MasterSecretMethod · 0.85
ExporterMasterSecretMethod · 0.85
ExporterMethod · 0.85

Calls 3

ExpandLabelFunction · 0.85
SizeMethod · 0.80
SumMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…