Help us shape the future of Go! Take the 2026 Go Developer Survey

credential

package
v0.1.0-rc.1 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrBrokerNotConfigured = errors.New("credential broker not configured")
	ErrEmptyRef            = errors.New("credential ref is empty")
)

Functions

This section is empty.

Types

type Broker

type Broker interface {
	Resolve(ctx context.Context, ref string, scope string) (Data, error)
}

Broker resolves opaque credential references into usable secret material. Implementations must never leak secret values through returned errors.

type Data

type Data struct {
	Payload map[string][]byte `json:"-"`
	Expires *time.Time        `json:"-"`
}

Data contains resolved secret material for a single operation. Payload and expiry metadata are deliberately excluded from JSON output.

type NoopBroker

type NoopBroker struct{}

NoopBroker is the safe default when no secret backend is configured.

func (NoopBroker) Resolve

func (NoopBroker) Resolve(_ context.Context, ref string, _ string) (Data, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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