first commit

This commit is contained in:
Adrian Zürcher
2025-10-12 14:56:18 +02:00
parent a9f2e11fe6
commit a908db4f38
92 changed files with 13273 additions and 0 deletions

14
backend/utils/secret.go Normal file
View File

@@ -0,0 +1,14 @@
package utils
import (
"crypto/rand"
)
func GenerateJWTSecret(length int) ([]byte, error) {
bytes := make([]byte, length)
_, err := rand.Read(bytes)
if err != nil {
return nil, err
}
return bytes, nil
}