keys

package
v0.0.0-...-a9fda57 Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2015 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrExists happens when a Key already exists in a database
	ErrExists = errors.New("notary-signer: key already in db")
	// ErrInvalidKeyID error happens when a key isn't found
	ErrInvalidKeyID = errors.New("notary-signer: invalid key id")
	// ErrFailedKeyGeneration happens when there is a failure in generating a key
	ErrFailedKeyGeneration = errors.New("notary-signer: failed to generate new key")
)

Functions

This section is empty.

Types

type HSMRSAKey

type HSMRSAKey struct {
	// contains filtered or unexported fields
}

HSMRSAKey represents the information for an HSMRSAKey with ObjectHandle for private portion

func NewHSMRSAKey

func NewHSMRSAKey(public []byte, private pkcs11.ObjectHandle) *HSMRSAKey

NewHSMRSAKey returns a HSMRSAKey

func (*HSMRSAKey) Algorithm

func (rsa *HSMRSAKey) Algorithm() string

Algorithm implements a method of the data.Key interface

func (*HSMRSAKey) ID

func (rsa *HSMRSAKey) ID() string

ID implements a method of the data.Key interface

func (*HSMRSAKey) PKCS11ObjectHandle

func (rsa *HSMRSAKey) PKCS11ObjectHandle() pkcs11.ObjectHandle

PKCS11ObjectHandle returns the PKCS11 object handle stored in the HSMRSAKey structure

func (*HSMRSAKey) Private

func (rsa *HSMRSAKey) Private() []byte

Private implements a method of the data.PrivateKey interface

func (*HSMRSAKey) Public

func (rsa *HSMRSAKey) Public() []byte

Public implements a method of the data.Key interface

Jump to

Keyboard shortcuts

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