common

package
v0.0.8 Latest Latest
Warning

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

Go to latest
Published: Mar 5, 2024 License: MIT Imports: 7 Imported by: 1

Documentation

Index

Constants

View Source
const DEFAULT_IMAGE_SIZE = 512
View Source
const MODULUS_SIZE = 8

Variables

View Source
var ErrorEmptyIssuer = errors.New("Issuer cannot be empty")
View Source
var ErrorEmptyUserID = errors.New("UserID cannot be empty")
View Source
var ErrorInvalidSecret = errors.New("invalid base32 encoding of the secret")
View Source
var ErrorNilOtpKeyOptions = errors.New("OtpKeyOptions cannot be nil")
View Source
var ErrorWrongCodeSize = errors.New("Code length is not of expected length")

Functions

This section is empty.

Types

type Algorithm

type Algorithm uint
const (
	SHA1Algorithm Algorithm = iota
	SHA256Algorithm
	SHA512Algorithm
)

func (Algorithm) Hash

func (a Algorithm) Hash() hash.Hash

func (Algorithm) String

func (a Algorithm) String() string

type PassCodeSize

type PassCodeSize uint
const (
	SixDigits   PassCodeSize = 6
	SevenDigits PassCodeSize = 7
	EightDigits PassCodeSize = 8
)

func (PassCodeSize) Format

func (d PassCodeSize) Format(value uint64) string

func (PassCodeSize) Length

func (d PassCodeSize) Length() int

func (PassCodeSize) String

func (d PassCodeSize) String() string

Jump to

Keyboard shortcuts

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