Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-pages.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--internal/auth/auth_code.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/internal/auth/auth_code.go b/internal/auth/auth_code.go
index 8974c544..ffbd5734 100644
--- a/internal/auth/auth_code.go
+++ b/internal/auth/auth_code.go
@@ -30,6 +30,8 @@ func (a *Auth) EncryptAndSignCode(domain, code string) (string, error) {
return "", errEmptyDomainOrCode
}
+ // for FIPS mode, the nonce size has to be equal to the gcmStandardNonceSize i.e. 12
+ // https://gitlab.com/gitlab-org/gitlab-pages/-/issues/726
nonce := securecookie.GenerateRandomKey(12)
if nonce == nil {
// https://github.com/gorilla/securecookie/blob/f37875ef1fb538320ab97fc6c9927d94c280ed5b/securecookie.go#L513