fakedatastore

package
v1.7.1 Latest Latest
Warning

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

Go to latest
Published: Jul 27, 2023 License: Apache-2.0 Imports: 15 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DataStore

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

func New

func New(tb testing.TB) *DataStore

func (*DataStore) AppendBundle

func (s *DataStore) AppendBundle(ctx context.Context, bundle *common.Bundle) (*common.Bundle, error)

func (*DataStore) AppendNextError added in v0.11.0

func (s *DataStore) AppendNextError(err error)

func (*DataStore) CountAttestedNodes added in v0.12.0

func (s *DataStore) CountAttestedNodes(ctx context.Context) (int32, error)

func (*DataStore) CountBundles added in v0.12.0

func (s *DataStore) CountBundles(ctx context.Context) (int32, error)

func (*DataStore) CountRegistrationEntries added in v0.12.0

func (s *DataStore) CountRegistrationEntries(ctx context.Context) (int32, error)

func (*DataStore) CreateAttestedNode

func (s *DataStore) CreateAttestedNode(ctx context.Context, node *common.AttestedNode) (*common.AttestedNode, error)

func (*DataStore) CreateBundle

func (s *DataStore) CreateBundle(ctx context.Context, bundle *common.Bundle) (*common.Bundle, error)

func (*DataStore) CreateFederationRelationship added in v1.1.0

func (s *DataStore) CreateFederationRelationship(c context.Context, fr *datastore.FederationRelationship) (*datastore.FederationRelationship, error)

func (*DataStore) CreateJoinToken

func (s *DataStore) CreateJoinToken(ctx context.Context, token *datastore.JoinToken) error

func (*DataStore) CreateOrReturnRegistrationEntry added in v1.1.0

func (s *DataStore) CreateOrReturnRegistrationEntry(ctx context.Context, entry *common.RegistrationEntry) (*common.RegistrationEntry, bool, error)

func (*DataStore) CreateRegistrationEntry

func (s *DataStore) CreateRegistrationEntry(ctx context.Context, entry *common.RegistrationEntry) (*common.RegistrationEntry, error)

func (*DataStore) DeleteAttestedNode

func (s *DataStore) DeleteAttestedNode(ctx context.Context, spiffeID string) (*common.AttestedNode, error)

func (*DataStore) DeleteBundle

func (s *DataStore) DeleteBundle(ctx context.Context, trustDomain string, mode datastore.DeleteMode) error

func (*DataStore) DeleteFederationRelationship added in v1.1.0

func (s *DataStore) DeleteFederationRelationship(c context.Context, trustDomain spiffeid.TrustDomain) error

func (*DataStore) DeleteJoinToken

func (s *DataStore) DeleteJoinToken(ctx context.Context, token string) error

func (*DataStore) DeleteRegistrationEntry

func (s *DataStore) DeleteRegistrationEntry(ctx context.Context, entryID string) (*common.RegistrationEntry, error)

func (*DataStore) FetchAttestedNode

func (s *DataStore) FetchAttestedNode(ctx context.Context, spiffeID string) (*common.AttestedNode, error)

func (*DataStore) FetchBundle

func (s *DataStore) FetchBundle(ctx context.Context, trustDomain string) (*common.Bundle, error)

func (*DataStore) FetchFederationRelationship added in v1.1.0

func (s *DataStore) FetchFederationRelationship(c context.Context, trustDomain spiffeid.TrustDomain) (*datastore.FederationRelationship, error)

func (*DataStore) FetchJoinToken

func (s *DataStore) FetchJoinToken(ctx context.Context, token string) (*datastore.JoinToken, error)

func (*DataStore) FetchRegistrationEntry

func (s *DataStore) FetchRegistrationEntry(ctx context.Context, entryID string) (*common.RegistrationEntry, error)

func (*DataStore) GetNodeSelectors

func (s *DataStore) GetNodeSelectors(ctx context.Context, spiffeID string, dataConsistency datastore.DataConsistency) ([]*common.Selector, error)

func (*DataStore) ListBundles

func (*DataStore) ListFederationRelationships added in v1.1.0

func (*DataStore) ListNodeSelectors added in v0.12.0

func (*DataStore) PruneBundle

func (s *DataStore) PruneBundle(ctx context.Context, trustDomainID string, expiresBefore time.Time) (bool, error)

func (*DataStore) PruneJoinTokens

func (s *DataStore) PruneJoinTokens(ctx context.Context, expiresBefore time.Time) error

func (*DataStore) PruneRegistrationEntries

func (s *DataStore) PruneRegistrationEntries(ctx context.Context, expiresBefore time.Time) error

func (*DataStore) RevokeJWTKey added in v1.6.3

func (s *DataStore) RevokeJWTKey(ctx context.Context, trustDomainID string, keyID string) (*common.PublicKey, error)

func (*DataStore) RevokeX509CA added in v1.6.3

func (s *DataStore) RevokeX509CA(ctx context.Context, trustDomainID string, publicKey crypto.PublicKey) error

func (*DataStore) SetBundle

func (s *DataStore) SetBundle(ctx context.Context, bundle *common.Bundle) (*common.Bundle, error)

func (*DataStore) SetNextError added in v0.11.0

func (s *DataStore) SetNextError(err error)

func (*DataStore) SetNodeSelectors

func (s *DataStore) SetNodeSelectors(ctx context.Context, spiffeID string, selectors []*common.Selector) error

func (*DataStore) TaintJWTKey added in v1.6.3

func (s *DataStore) TaintJWTKey(ctx context.Context, trustDomainID string, keyID string) (*common.PublicKey, error)

func (*DataStore) TaintX509CA added in v1.6.3

func (s *DataStore) TaintX509CA(ctx context.Context, trustDomainID string, publicKey crypto.PublicKey) error

func (*DataStore) UpdateAttestedNode

func (s *DataStore) UpdateAttestedNode(ctx context.Context, node *common.AttestedNode, mask *common.AttestedNodeMask) (*common.AttestedNode, error)

func (*DataStore) UpdateBundle

func (s *DataStore) UpdateBundle(ctx context.Context, bundle *common.Bundle, mask *common.BundleMask) (*common.Bundle, error)

func (*DataStore) UpdateFederationRelationship added in v1.1.0

func (*DataStore) UpdateRegistrationEntry

func (s *DataStore) UpdateRegistrationEntry(ctx context.Context, entry *common.RegistrationEntry, mask *common.RegistrationEntryMask) (*common.RegistrationEntry, error)

Jump to

Keyboard shortcuts

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