securityscanadapter

package
v0.0.0-...-e7c744b Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ClusterService

type ClusterService interface {
	// GetClusterUID returns the unique ID of a cluster.
	GetClusterUID(ctx context.Context, clusterID uint) (string, error)
}

ClusterService provides access to clusters.

func NewClusterService

func NewClusterService(getter CommonClusterGetter) ClusterService

NewClusterService returns a new ClusterService instance.

type CommonClusterGetter

type CommonClusterGetter interface {
	GetClusterByIDOnly(ctx context.Context, clusterID uint) (cluster.CommonCluster, error)
}

CommonClusterGetter defines cluster getter methods that return a CommonCluster

type UserNameGenerator

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

UserNameGenerator generates an Anchore username for a cluster.

func NewUserNameGenerator

func NewUserNameGenerator(clusterService ClusterService) UserNameGenerator

NewUserNameGenerator returns a new UserNameGenerator.

func (UserNameGenerator) GenerateUsername

func (g UserNameGenerator) GenerateUsername(ctx context.Context, clusterID uint) (string, error)

GenerateUsername generates a unique username using the cluster's UUID

type UserSecretStore

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

UserSecretStore stores Anchore user secrets.

func NewUserSecretStore

func NewUserSecretStore(secretStore services.SecretStore) UserSecretStore

NewUserSecretStore returns a new UserSecretStore.

func (UserSecretStore) GetPasswordForUser

func (s UserSecretStore) GetPasswordForUser(ctx context.Context, userName string) (string, error)

Jump to

Keyboard shortcuts

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