create account, create email

This commit is contained in:
2024-09-03 15:56:34 +02:00
parent fd8fdc899c
commit 80289f1929
20 changed files with 409 additions and 158 deletions

14
util/random.go Normal file
View File

@ -0,0 +1,14 @@
package util
import (
"crypto/rand"
"io"
)
func GenerateRandomKey(length int) []byte {
k := make([]byte, length)
if _, err := io.ReadFull(rand.Reader, k); err != nil {
return nil
}
return k
}