Tugas tabel

This commit is contained in:
farrel
2026-09-28 18:27:16 +07:00
parent c7e17bf89e
commit f40a0ab1fd
17 changed files with 862 additions and 35 deletions
+14
View File
@@ -0,0 +1,14 @@
package auth
import (
"crypto/rand"
"encoding/hex"
)
func GenerateToken() (string, error) {
b := make([]byte, 32)
if _, err := rand.Read(b); err != nil {
return "", err
}
return hex.EncodeToString(b), nil
}