certgen

package
v0.0.0-...-2db412b Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2024 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ExtNameTokenID     = asn1.ObjectIdentifier([]int{1, 3, 6, 1, 4, 1, 65535, 10, 0})
	ExtNameTouchPolicy = asn1.ObjectIdentifier([]int{1, 3, 6, 1, 4, 1, 65535, 10, 1})
	ExtNamePinPolicy   = asn1.ObjectIdentifier([]int{1, 3, 6, 1, 4, 1, 65535, 10, 2})
)

Functions

func GenCertificateFor

func GenCertificateFor(commonName string, pub crypto.PublicKey, days int, extraNames []pkix.AttributeTypeAndValue) ([]byte, error)

func GenCommonName

func GenCommonName(user, name string) string

Types

type ExtraName

type ExtraName struct {
	TokenID     string
	TouchPolicy string
	PinPolicy   string
}

func ParseExtraNames

func ParseExtraNames(names []pkix.AttributeTypeAndValue) (*ExtraName, error)

Jump to

Keyboard shortcuts

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