utils

package
v1.3.2 Latest Latest
Warning

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

Go to latest
Published: Aug 21, 2025 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const SecretSize = 32

Variables

This section is empty.

Functions

func Err

func Err(err error) []zap.Field

func GenerateClientID

func GenerateClientID() (string, error)

func GenerateClientSecret

func GenerateClientSecret() (string, error)

func GenerateKeyID

func GenerateKeyID(publicKey *rsa.PublicKey) (string, error)

func GenerateState added in v1.2.2

func GenerateState() (string, error)

func LoadOrGeneratePrivateKey

func LoadOrGeneratePrivateKey(keyPath string) (*rsa.PrivateKey, error)

func LoadOrGenerateSecret added in v1.0.0

func LoadOrGenerateSecret(secretPath string) ([]byte, error)

func LoadPrivateKey

func LoadPrivateKey(keyPath string) (*rsa.PrivateKey, error)

func SavePrivateKey

func SavePrivateKey(keyPath string, privateKey *rsa.PrivateKey) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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