mirror of
https://github.com/refraction-networking/utls.git
synced 2025-04-01 19:17:36 +03:00
fix: nil dereference in when getting public master secret
This commit is contained in:
parent
d24af4ae55
commit
6c3c017a94
1 changed files with 6 additions and 1 deletions
|
@ -23,4 +23,9 @@ func NewMasterSecretFromSecret[H fips140.Hash](hash func() H, secret []byte) *Ma
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (s *MasterSecret) Secret() []byte { return s.secret }
|
func (s *MasterSecret) Secret() []byte {
|
||||||
|
if s != nil {
|
||||||
|
return s.secret
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue