keystore

package
v0.0.0-...-e979ea2 Latest Latest
Warning

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

Go to latest
Published: Sep 4, 2022 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

this package implements auth.KeyStore interface for in-memory keystore for JWT support

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type KeyStore

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

func NewFS

func NewFS(fsys fs.FS) (*KeyStore, error)

func NewStore

func NewStore() *KeyStore

func (*KeyStore) Add

func (ks *KeyStore) Add(kid string, key *rsa.PrivateKey)

func (*KeyStore) Delete

func (ks *KeyStore) Delete(kid string)

func (*KeyStore) PrivateKey

func (ks *KeyStore) PrivateKey(kid string) (*rsa.PrivateKey, error)

PrivateKey find key by kid and returns private key.

func (*KeyStore) PublicKey

func (ks *KeyStore) PublicKey(kid string) (*rsa.PublicKey, error)

PublicKey find key by kid and returns public key.

Jump to

Keyboard shortcuts

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