mirror of
https://github.com/KusakabeShi/EtherGuard-VPN.git
synced 2025-08-10 08:04:49 +02:00
Added missing mutex acquisition
This commit is contained in:
@ -62,6 +62,9 @@ func (st *CookieChecker) Init(pk NoisePublicKey) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (st *CookieChecker) CheckMAC1(msg []byte) bool {
|
func (st *CookieChecker) CheckMAC1(msg []byte) bool {
|
||||||
|
st.mutex.RLock()
|
||||||
|
defer st.mutex.RUnlock()
|
||||||
|
|
||||||
size := len(msg)
|
size := len(msg)
|
||||||
smac2 := size - blake2s.Size128
|
smac2 := size - blake2s.Size128
|
||||||
smac1 := smac2 - blake2s.Size128
|
smac1 := smac2 - blake2s.Size128
|
||||||
|
Reference in New Issue
Block a user