aboutsummaryrefslogtreecommitdiffstats
path: root/cookie.go
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2018-02-12 20:10:44 +0100
committerJason A. Donenfeld <Jason@zx2c4.com>2018-02-12 20:13:03 +0100
commitbffe99aeadae09abd02f2bd3184925af6b680535 (patch)
tree556d223ebcd32b957e62e15353087b93a824641c /cookie.go
parentMoved test-processes to background (diff)
downloadwireguard-go-bffe99aeadae09abd02f2bd3184925af6b680535.tar.xz
wireguard-go-bffe99aeadae09abd02f2bd3184925af6b680535.zip
Don't use modules
Feel free to revert this if you have a strong feeling about it. But so far as I can see, it adds a lot of complexity for basically no upsides.
Diffstat (limited to 'cookie.go')
-rw-r--r--cookie.go5
1 files changed, 2 insertions, 3 deletions
diff --git a/cookie.go b/cookie.go
index 72455a4..9572901 100644
--- a/cookie.go
+++ b/cookie.go
@@ -3,7 +3,6 @@ package main
import (
"crypto/hmac"
"crypto/rand"
- "git.zx2c4.com/wireguard-go/internal/xchacha20poly1305"
"golang.org/x/crypto/blake2s"
"golang.org/x/crypto/chacha20poly1305"
"sync"
@@ -158,7 +157,7 @@ func (st *CookieChecker) CreateReply(
return nil, err
}
- xchacha20poly1305.Encrypt(
+ XChaCha20Poly1305Encrypt(
reply.Cookie[:0],
&reply.Nonce,
cookie[:],
@@ -202,7 +201,7 @@ func (st *CookieGenerator) ConsumeReply(msg *MessageCookieReply) bool {
var cookie [blake2s.Size128]byte
- _, err := xchacha20poly1305.Decrypt(
+ _, err := XChaCha20Poly1305Decrypt(
cookie[:0],
&msg.Nonce,
msg.Cookie[:],