fakeservernodeattestor

package
v0.11.0 Latest Latest
Warning

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

Go to latest
Published: Aug 28, 2020 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// DisallowReattestation determines whether or not the attestor allows reattestation
	DisallowReattestation bool

	// TrustDomain is the trust domain for SPIFFE IDs created by the attestor.
	// Defaults to "example.org" if empty.
	TrustDomain string

	// Data is a map from attestation data (as a string) to the associated id
	// produced by the attestor. For example, a mapping from "DATA" ==> "FOO
	// means that an attestation request with the data "DATA" would result in
	// an attestation response with the SPIFFE ID:
	//
	// spiffe://<trustdomain>/spire/agent/<name>/<ID>
	//
	// For example, "spiffe://example.org/spire/agent/foo/bar"
	// In case ReturnLiteral is true value will be returned as base id
	Data map[string]string

	// Challenges is a map from ID to a list of echo challenges. The response
	// to each challenge is expected to match the challenge value.
	Challenges map[string][]string

	// Selectors is a map from ID to a list of selector values to return with that id.
	Selectors map[string][]string

	// Return literal from Data map
	ReturnLiteral bool
}

type NodeAttestor

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

func New

func New(name string, config Config) *NodeAttestor

func (*NodeAttestor) Attest

func (p *NodeAttestor) Attest(stream nodeattestor.NodeAttestor_AttestServer) (err error)

func (*NodeAttestor) Configure

Jump to

Keyboard shortcuts

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