kms

package
v0.0.0-...-05fd942 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2020 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type KMS

type KMS struct {
	crypto.Signer    // https://golang.org/pkg/crypto/#Signer
	crypto.Decrypter // https://golang.org/pkg/crypto/#Decrypter

	PublicKeyFile string
	ExtTLSConfig  *tls.Config

	ProjectId  string
	LocationId string
	KeyRing    string
	Key        string
	KeyVersion string
}

func NewKMSCrypto

func NewKMSCrypto(conf *KMS) (KMS, error)

func (KMS) Decrypt

func (t KMS) Decrypt(rand io.Reader, msg []byte, opts crypto.DecrypterOpts) ([]byte, error)

func (KMS) Public

func (t KMS) Public() crypto.PublicKey

func (KMS) Sign

func (t KMS) Sign(_ io.Reader, digest []byte, opts crypto.SignerOpts) ([]byte, error)

func (KMS) TLSCertificate

func (t KMS) TLSCertificate() tls.Certificate

func (KMS) TLSConfig

func (t KMS) TLSConfig() *tls.Config

Jump to

Keyboard shortcuts

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