authcore

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 5, 2026 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateActivationToken

func GenerateActivationToken(baseKey string) string

GenerateActivationToken produces a 100-character URL-safe token. The user key and the current timestamp are mixed into HKDF-derived entropy. The function is intentionally simple and uses only standard library components.

func GenerateRecoveryCode

func GenerateRecoveryCode(baseKey string) (string, error)

GenerateRecoveryCode creates an 11-character uppercase alphanumeric code. The entropy source is HKDF derived from secure randomness and the base key.

Output uses Base32 without padding, trimmed to a fixed length.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL