From f7ccc58b9899b4098c96b4baa6c7fa3183be262c Mon Sep 17 00:00:00 2001 From: Daniel Date: Tue, 24 Sep 2019 15:38:51 +0200 Subject: [PATCH] Update rng package import --- api/authentication.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api/authentication.go b/api/authentication.go index 80413e9..baeba1d 100644 --- a/api/authentication.go +++ b/api/authentication.go @@ -6,8 +6,8 @@ import ( "sync" "time" - "github.com/safing/portbase/crypto/random" "github.com/safing/portbase/log" + "github.com/safing/portbase/rng" ) var ( @@ -91,7 +91,7 @@ func authMiddleware(next http.Handler) http.Handler { } // write new cookie - token, err := random.Bytes(32) // 256 bit + token, err := rng.Bytes(32) // 256 bit if err != nil { log.Warningf("api: failed to generate random token: %s", err) http.Error(w, "Internal Server Error", http.StatusInternalServerError)