vault

package
v1.15.1 Latest Latest
Warning

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

Go to latest
Published: Sep 9, 2024 License: GPL-3.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 VaultClient

type VaultClient interface {
	ReadWithContext(ctx context.Context, path string) (*api.Secret, error)
	WriteWithContext(ctx context.Context, path string, data map[string]any) (*api.Secret, error)
	ReadRawWithContext(ctx context.Context, path string) (*api.Response, error)
}

type VaultOpts

type VaultOpts func(client *VaultPki) error

func WithAcmePrefix

func WithAcmePrefix(prefix string) VaultOpts

func WithKv2Mount

func WithKv2Mount(mountPath string) VaultOpts

func WithPkiMount

func WithPkiMount(mountPath string) VaultOpts

type VaultPki

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

func NewVaultPki

func NewVaultPki(client VaultClient, roleName string, opts ...VaultOpts) (*VaultPki, error)

func (*VaultPki) FetchCa

func (c *VaultPki) FetchCa(binary bool) ([]byte, error)

func (*VaultPki) FetchCaChain

func (c *VaultPki) FetchCaChain() ([]byte, error)

func (*VaultPki) FetchCrl

func (c *VaultPki) FetchCrl(binary bool) ([]byte, error)

func (*VaultPki) Issue

func (c *VaultPki) Issue(ctx context.Context, args pkg.IssueArgs) (*pkg.CertData, error)

func (*VaultPki) ReadAcme

func (c *VaultPki) ReadAcme(ctx context.Context, commonName string) (*pkg.CertData, error)

func (*VaultPki) Revoke

func (c *VaultPki) Revoke(ctx context.Context, serial string) error

func (*VaultPki) Sign

func (c *VaultPki) Sign(ctx context.Context, csr string, args pkg.SignatureArgs) (*pkg.Signature, error)

func (*VaultPki) Tidy

func (c *VaultPki) Tidy(ctx context.Context) error

Jump to

Keyboard shortcuts

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