qrcode

package
v0.2.7 Latest Latest
Warning

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

Go to latest
Published: Jun 27, 2021 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const FormatString string = "otpauth://totp/%s:%s@%s?algorithm=SHA1&digits=%d&issuer=%s&period=30&secret=%s"

FormatString is a predefined String that is used when generating a QR Code

Variables

This section is empty.

Functions

func GenerateQrCode

func GenerateQrCode(user structs.User, bgcolor, fgcolor structs.ColorSetting, digits uint8) ([]byte, error)

GenerateQrCode Generates a QRCode of the totp url

func WriteQrCodeImage

func WriteQrCodeImage(user structs.User, filePath string, digits uint8) error

WriteQrCodeImage writes a png to the filesystem

Types

This section is empty.

Jump to

Keyboard shortcuts

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