v1

package
v0.13.0 Latest Latest
Warning

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

Go to latest
Published: Jul 10, 2023 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_credentials_v1_config_proto protoreflect.FileDescriptor

Functions

func NewFromConfig

func NewFromConfig(conf *Credentials, l log.Logger) (credentials.ReaderWriter, error)

Types

type Credentials

type Credentials struct {

	// Types that are assignable to Backend:
	//
	//	*Credentials_AwsSecretManager
	//	*Credentials_Vault_
	//	*Credentials_GcpSecretManager
	Backend isCredentials_Backend `protobuf_oneof:"backend"`
	// contains filtered or unexported fields
}

Where the credentials to access the backends are stored

func (*Credentials) Descriptor deprecated

func (*Credentials) Descriptor() ([]byte, []int)

Deprecated: Use Credentials.ProtoReflect.Descriptor instead.

func (*Credentials) GetAwsSecretManager

func (x *Credentials) GetAwsSecretManager() *Credentials_AWSSecretManager

func (*Credentials) GetBackend

func (m *Credentials) GetBackend() isCredentials_Backend

func (*Credentials) GetGcpSecretManager

func (x *Credentials) GetGcpSecretManager() *Credentials_GCPSecretManager

func (*Credentials) GetVault

func (x *Credentials) GetVault() *Credentials_Vault

func (*Credentials) ProtoMessage

func (*Credentials) ProtoMessage()

func (*Credentials) ProtoReflect

func (x *Credentials) ProtoReflect() protoreflect.Message

func (*Credentials) Reset

func (x *Credentials) Reset()

func (*Credentials) String

func (x *Credentials) String() string

func (*Credentials) Validate

func (m *Credentials) Validate() error

Validate checks the field values on Credentials with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Credentials) ValidateAll

func (m *Credentials) ValidateAll() error

ValidateAll checks the field values on Credentials with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in CredentialsMultiError, or nil if none found.

type CredentialsMultiError

type CredentialsMultiError []error

CredentialsMultiError is an error wrapping multiple validation errors returned by Credentials.ValidateAll() if the designated constraints aren't met.

func (CredentialsMultiError) AllErrors

func (m CredentialsMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (CredentialsMultiError) Error

func (m CredentialsMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type CredentialsValidationError

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

CredentialsValidationError is the validation error returned by Credentials.Validate if the designated constraints aren't met.

func (CredentialsValidationError) Cause

Cause function returns cause value.

func (CredentialsValidationError) Error

Error satisfies the builtin error interface

func (CredentialsValidationError) ErrorName

func (e CredentialsValidationError) ErrorName() string

ErrorName returns error name.

func (CredentialsValidationError) Field

Field function returns field value.

func (CredentialsValidationError) Key

Key function returns key value.

func (CredentialsValidationError) Reason

Reason function returns reason value.

type Credentials_AWSSecretManager

type Credentials_AWSSecretManager struct {
	Creds  *Credentials_AWSSecretManager_Creds `protobuf:"bytes,1,opt,name=creds,proto3" json:"creds,omitempty"`
	Region string                              `protobuf:"bytes,2,opt,name=region,proto3" json:"region,omitempty"`
	// contains filtered or unexported fields
}

Top level is deprecated now

func (*Credentials_AWSSecretManager) Descriptor deprecated

func (*Credentials_AWSSecretManager) Descriptor() ([]byte, []int)

Deprecated: Use Credentials_AWSSecretManager.ProtoReflect.Descriptor instead.

func (*Credentials_AWSSecretManager) GetCreds

func (*Credentials_AWSSecretManager) GetRegion

func (x *Credentials_AWSSecretManager) GetRegion() string

func (*Credentials_AWSSecretManager) ProtoMessage

func (*Credentials_AWSSecretManager) ProtoMessage()

func (*Credentials_AWSSecretManager) ProtoReflect

func (*Credentials_AWSSecretManager) Reset

func (x *Credentials_AWSSecretManager) Reset()

func (*Credentials_AWSSecretManager) String

func (*Credentials_AWSSecretManager) Validate

func (m *Credentials_AWSSecretManager) Validate() error

Validate checks the field values on Credentials_AWSSecretManager with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Credentials_AWSSecretManager) ValidateAll

func (m *Credentials_AWSSecretManager) ValidateAll() error

ValidateAll checks the field values on Credentials_AWSSecretManager with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in Credentials_AWSSecretManagerMultiError, or nil if none found.

type Credentials_AWSSecretManagerMultiError

type Credentials_AWSSecretManagerMultiError []error

Credentials_AWSSecretManagerMultiError is an error wrapping multiple validation errors returned by Credentials_AWSSecretManager.ValidateAll() if the designated constraints aren't met.

func (Credentials_AWSSecretManagerMultiError) AllErrors

AllErrors returns a list of validation violation errors.

func (Credentials_AWSSecretManagerMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type Credentials_AWSSecretManagerValidationError

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

Credentials_AWSSecretManagerValidationError is the validation error returned by Credentials_AWSSecretManager.Validate if the designated constraints aren't met.

func (Credentials_AWSSecretManagerValidationError) Cause

Cause function returns cause value.

func (Credentials_AWSSecretManagerValidationError) Error

Error satisfies the builtin error interface

func (Credentials_AWSSecretManagerValidationError) ErrorName

ErrorName returns error name.

func (Credentials_AWSSecretManagerValidationError) Field

Field function returns field value.

func (Credentials_AWSSecretManagerValidationError) Key

Key function returns key value.

func (Credentials_AWSSecretManagerValidationError) Reason

Reason function returns reason value.

type Credentials_AWSSecretManager_Creds

type Credentials_AWSSecretManager_Creds struct {
	AccessKey string `protobuf:"bytes,1,opt,name=access_key,json=accessKey,proto3" json:"access_key,omitempty"`
	SecretKey string `protobuf:"bytes,2,opt,name=secret_key,json=secretKey,proto3" json:"secret_key,omitempty"`
	// contains filtered or unexported fields
}

func (*Credentials_AWSSecretManager_Creds) Descriptor deprecated

func (*Credentials_AWSSecretManager_Creds) Descriptor() ([]byte, []int)

Deprecated: Use Credentials_AWSSecretManager_Creds.ProtoReflect.Descriptor instead.

func (*Credentials_AWSSecretManager_Creds) GetAccessKey

func (x *Credentials_AWSSecretManager_Creds) GetAccessKey() string

func (*Credentials_AWSSecretManager_Creds) GetSecretKey

func (x *Credentials_AWSSecretManager_Creds) GetSecretKey() string

func (*Credentials_AWSSecretManager_Creds) ProtoMessage

func (*Credentials_AWSSecretManager_Creds) ProtoMessage()

func (*Credentials_AWSSecretManager_Creds) ProtoReflect

func (*Credentials_AWSSecretManager_Creds) Reset

func (*Credentials_AWSSecretManager_Creds) String

func (*Credentials_AWSSecretManager_Creds) Validate

Validate checks the field values on Credentials_AWSSecretManager_Creds with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Credentials_AWSSecretManager_Creds) ValidateAll

func (m *Credentials_AWSSecretManager_Creds) ValidateAll() error

ValidateAll checks the field values on Credentials_AWSSecretManager_Creds with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in Credentials_AWSSecretManager_CredsMultiError, or nil if none found.

type Credentials_AWSSecretManager_CredsMultiError

type Credentials_AWSSecretManager_CredsMultiError []error

Credentials_AWSSecretManager_CredsMultiError is an error wrapping multiple validation errors returned by Credentials_AWSSecretManager_Creds.ValidateAll() if the designated constraints aren't met.

func (Credentials_AWSSecretManager_CredsMultiError) AllErrors

AllErrors returns a list of validation violation errors.

func (Credentials_AWSSecretManager_CredsMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type Credentials_AWSSecretManager_CredsValidationError

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

Credentials_AWSSecretManager_CredsValidationError is the validation error returned by Credentials_AWSSecretManager_Creds.Validate if the designated constraints aren't met.

func (Credentials_AWSSecretManager_CredsValidationError) Cause

Cause function returns cause value.

func (Credentials_AWSSecretManager_CredsValidationError) Error

Error satisfies the builtin error interface

func (Credentials_AWSSecretManager_CredsValidationError) ErrorName

ErrorName returns error name.

func (Credentials_AWSSecretManager_CredsValidationError) Field

Field function returns field value.

func (Credentials_AWSSecretManager_CredsValidationError) Key

Key function returns key value.

func (Credentials_AWSSecretManager_CredsValidationError) Reason

Reason function returns reason value.

type Credentials_AwsSecretManager

type Credentials_AwsSecretManager struct {
	AwsSecretManager *Credentials_AWSSecretManager `protobuf:"bytes,1,opt,name=aws_secret_manager,json=awsSecretManager,proto3,oneof"`
}

type Credentials_GCPSecretManager

type Credentials_GCPSecretManager struct {

	// project number
	ProjectId string `protobuf:"bytes,1,opt,name=project_id,json=projectId,proto3" json:"project_id,omitempty"`
	// path to service account key in json format
	ServiceAccountKey string `protobuf:"bytes,2,opt,name=service_account_key,json=serviceAccountKey,proto3" json:"service_account_key,omitempty"`
	// contains filtered or unexported fields
}

func (*Credentials_GCPSecretManager) Descriptor deprecated

func (*Credentials_GCPSecretManager) Descriptor() ([]byte, []int)

Deprecated: Use Credentials_GCPSecretManager.ProtoReflect.Descriptor instead.

func (*Credentials_GCPSecretManager) GetProjectId

func (x *Credentials_GCPSecretManager) GetProjectId() string

func (*Credentials_GCPSecretManager) GetServiceAccountKey

func (x *Credentials_GCPSecretManager) GetServiceAccountKey() string

func (*Credentials_GCPSecretManager) ProtoMessage

func (*Credentials_GCPSecretManager) ProtoMessage()

func (*Credentials_GCPSecretManager) ProtoReflect

func (*Credentials_GCPSecretManager) Reset

func (x *Credentials_GCPSecretManager) Reset()

func (*Credentials_GCPSecretManager) String

func (*Credentials_GCPSecretManager) Validate

func (m *Credentials_GCPSecretManager) Validate() error

Validate checks the field values on Credentials_GCPSecretManager with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Credentials_GCPSecretManager) ValidateAll

func (m *Credentials_GCPSecretManager) ValidateAll() error

ValidateAll checks the field values on Credentials_GCPSecretManager with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in Credentials_GCPSecretManagerMultiError, or nil if none found.

type Credentials_GCPSecretManagerMultiError

type Credentials_GCPSecretManagerMultiError []error

Credentials_GCPSecretManagerMultiError is an error wrapping multiple validation errors returned by Credentials_GCPSecretManager.ValidateAll() if the designated constraints aren't met.

func (Credentials_GCPSecretManagerMultiError) AllErrors

AllErrors returns a list of validation violation errors.

func (Credentials_GCPSecretManagerMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type Credentials_GCPSecretManagerValidationError

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

Credentials_GCPSecretManagerValidationError is the validation error returned by Credentials_GCPSecretManager.Validate if the designated constraints aren't met.

func (Credentials_GCPSecretManagerValidationError) Cause

Cause function returns cause value.

func (Credentials_GCPSecretManagerValidationError) Error

Error satisfies the builtin error interface

func (Credentials_GCPSecretManagerValidationError) ErrorName

ErrorName returns error name.

func (Credentials_GCPSecretManagerValidationError) Field

Field function returns field value.

func (Credentials_GCPSecretManagerValidationError) Key

Key function returns key value.

func (Credentials_GCPSecretManagerValidationError) Reason

Reason function returns reason value.

type Credentials_GcpSecretManager

type Credentials_GcpSecretManager struct {
	GcpSecretManager *Credentials_GCPSecretManager `protobuf:"bytes,3,opt,name=gcp_secret_manager,json=gcpSecretManager,proto3,oneof"`
}

type Credentials_Vault

type Credentials_Vault struct {

	// TODO: Use application role auth instead
	Token string `protobuf:"bytes,1,opt,name=token,proto3" json:"token,omitempty"`
	// Instance address, including port
	// i.e "http://127.0.0.1:8200"
	Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"`
	// mount path of the kv engine, default /secret
	MountPath string `protobuf:"bytes,3,opt,name=mount_path,json=mountPath,proto3" json:"mount_path,omitempty"`
	// contains filtered or unexported fields
}

func (*Credentials_Vault) Descriptor deprecated

func (*Credentials_Vault) Descriptor() ([]byte, []int)

Deprecated: Use Credentials_Vault.ProtoReflect.Descriptor instead.

func (*Credentials_Vault) GetAddress

func (x *Credentials_Vault) GetAddress() string

func (*Credentials_Vault) GetMountPath

func (x *Credentials_Vault) GetMountPath() string

func (*Credentials_Vault) GetToken

func (x *Credentials_Vault) GetToken() string

func (*Credentials_Vault) ProtoMessage

func (*Credentials_Vault) ProtoMessage()

func (*Credentials_Vault) ProtoReflect

func (x *Credentials_Vault) ProtoReflect() protoreflect.Message

func (*Credentials_Vault) Reset

func (x *Credentials_Vault) Reset()

func (*Credentials_Vault) String

func (x *Credentials_Vault) String() string

func (*Credentials_Vault) Validate

func (m *Credentials_Vault) Validate() error

Validate checks the field values on Credentials_Vault with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Credentials_Vault) ValidateAll

func (m *Credentials_Vault) ValidateAll() error

ValidateAll checks the field values on Credentials_Vault with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in Credentials_VaultMultiError, or nil if none found.

type Credentials_VaultMultiError

type Credentials_VaultMultiError []error

Credentials_VaultMultiError is an error wrapping multiple validation errors returned by Credentials_Vault.ValidateAll() if the designated constraints aren't met.

func (Credentials_VaultMultiError) AllErrors

func (m Credentials_VaultMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (Credentials_VaultMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type Credentials_VaultValidationError

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

Credentials_VaultValidationError is the validation error returned by Credentials_Vault.Validate if the designated constraints aren't met.

func (Credentials_VaultValidationError) Cause

Cause function returns cause value.

func (Credentials_VaultValidationError) Error

Error satisfies the builtin error interface

func (Credentials_VaultValidationError) ErrorName

ErrorName returns error name.

func (Credentials_VaultValidationError) Field

Field function returns field value.

func (Credentials_VaultValidationError) Key

Key function returns key value.

func (Credentials_VaultValidationError) Reason

Reason function returns reason value.

type Credentials_Vault_

type Credentials_Vault_ struct {
	Vault *Credentials_Vault `protobuf:"bytes,2,opt,name=vault,proto3,oneof"`
}

Jump to

Keyboard shortcuts

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