secret

package
v1.4.1 Latest Latest
Warning

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

Go to latest
Published: Dec 14, 2022 License: Apache-2.0 Imports: 11 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_proto_secret_proto protoreflect.FileDescriptor

Functions

func NewSecretEndpoints

func NewSecretEndpoints() []*api.Endpoint

func RegisterSecretHandler

func RegisterSecretHandler(s server.Server, hdlr SecretHandler, opts ...server.HandlerOption) error

Types

type DeleteRequest

type DeleteRequest struct {

	// The key to delete
	Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// Optional path
	Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"`
	// contains filtered or unexported fields
}

Delete a secret. If key not found a success response is returned.

func (*DeleteRequest) Descriptor deprecated

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

Deprecated: Use DeleteRequest.ProtoReflect.Descriptor instead.

func (*DeleteRequest) GetKey

func (x *DeleteRequest) GetKey() string

func (*DeleteRequest) GetPath

func (x *DeleteRequest) GetPath() string

func (*DeleteRequest) ProtoMessage

func (*DeleteRequest) ProtoMessage()

func (*DeleteRequest) ProtoReflect

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

func (*DeleteRequest) Reset

func (x *DeleteRequest) Reset()

func (*DeleteRequest) String

func (x *DeleteRequest) String() string

type DeleteResponse

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

func (*DeleteResponse) Descriptor deprecated

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

Deprecated: Use DeleteResponse.ProtoReflect.Descriptor instead.

func (*DeleteResponse) ProtoMessage

func (*DeleteResponse) ProtoMessage()

func (*DeleteResponse) ProtoReflect

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

func (*DeleteResponse) Reset

func (x *DeleteResponse) Reset()

func (*DeleteResponse) String

func (x *DeleteResponse) String() string

type GetRequest

type GetRequest struct {

	// The key to retrieve
	Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// Optional path
	Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"`
	// contains filtered or unexported fields
}

Get a secret by key.

func (*GetRequest) Descriptor deprecated

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

Deprecated: Use GetRequest.ProtoReflect.Descriptor instead.

func (*GetRequest) GetKey

func (x *GetRequest) GetKey() string

func (*GetRequest) GetPath

func (x *GetRequest) GetPath() string

func (*GetRequest) ProtoMessage

func (*GetRequest) ProtoMessage()

func (*GetRequest) ProtoReflect

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

func (*GetRequest) Reset

func (x *GetRequest) Reset()

func (*GetRequest) String

func (x *GetRequest) String() string

type GetResponse

type GetResponse struct {

	// The key e.g foo
	Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// Path of value e.g bar/baz
	Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"`
	// The value e.g cat
	Value string `protobuf:"bytes,3,opt,name=value,proto3" json:"value,omitempty"`
	// time of creation
	Created string `protobuf:"bytes,4,opt,name=created,proto3" json:"created,omitempty"`
	// time of update
	Updated string `protobuf:"bytes,5,opt,name=updated,proto3" json:"updated,omitempty"`
	// contains filtered or unexported fields
}

func (*GetResponse) Descriptor deprecated

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

Deprecated: Use GetResponse.ProtoReflect.Descriptor instead.

func (*GetResponse) GetCreated

func (x *GetResponse) GetCreated() string

func (*GetResponse) GetKey

func (x *GetResponse) GetKey() string

func (*GetResponse) GetPath

func (x *GetResponse) GetPath() string

func (*GetResponse) GetUpdated

func (x *GetResponse) GetUpdated() string

func (*GetResponse) GetValue

func (x *GetResponse) GetValue() string

func (*GetResponse) ProtoMessage

func (*GetResponse) ProtoMessage()

func (*GetResponse) ProtoReflect

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

func (*GetResponse) Reset

func (x *GetResponse) Reset()

func (*GetResponse) String

func (x *GetResponse) String() string

type ListRequest

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

List all the available secrets

func (*ListRequest) Descriptor deprecated

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

Deprecated: Use ListRequest.ProtoReflect.Descriptor instead.

func (*ListRequest) ProtoMessage

func (*ListRequest) ProtoMessage()

func (*ListRequest) ProtoReflect

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

func (*ListRequest) Reset

func (x *ListRequest) Reset()

func (*ListRequest) String

func (x *ListRequest) String() string

type ListResponse

type ListResponse struct {
	Keys []string `protobuf:"bytes,1,rep,name=keys,proto3" json:"keys,omitempty"`
	// contains filtered or unexported fields
}

func (*ListResponse) Descriptor deprecated

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

Deprecated: Use ListResponse.ProtoReflect.Descriptor instead.

func (*ListResponse) GetKeys

func (x *ListResponse) GetKeys() []string

func (*ListResponse) ProtoMessage

func (*ListResponse) ProtoMessage()

func (*ListResponse) ProtoReflect

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

func (*ListResponse) Reset

func (x *ListResponse) Reset()

func (*ListResponse) String

func (x *ListResponse) String() string

type SecretService

type SecretService interface {
	Get(ctx context.Context, in *GetRequest, opts ...client.CallOption) (*GetResponse, error)
	Set(ctx context.Context, in *SetRequest, opts ...client.CallOption) (*SetResponse, error)
	Delete(ctx context.Context, in *DeleteRequest, opts ...client.CallOption) (*DeleteResponse, error)
	List(ctx context.Context, in *ListRequest, opts ...client.CallOption) (*ListResponse, error)
}

func NewSecretService

func NewSecretService(name string, c client.Client) SecretService

type SetRequest

type SetRequest struct {

	// The key to update
	Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// Optional path e.g bar/baz
	Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"`
	// The value to set
	Value string `protobuf:"bytes,3,opt,name=value,proto3" json:"value,omitempty"`
	// contains filtered or unexported fields
}

Set a secret. Overwrites any existing value already set.

func (*SetRequest) Descriptor deprecated

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

Deprecated: Use SetRequest.ProtoReflect.Descriptor instead.

func (*SetRequest) GetKey

func (x *SetRequest) GetKey() string

func (*SetRequest) GetPath

func (x *SetRequest) GetPath() string

func (*SetRequest) GetValue

func (x *SetRequest) GetValue() string

func (*SetRequest) ProtoMessage

func (*SetRequest) ProtoMessage()

func (*SetRequest) ProtoReflect

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

func (*SetRequest) Reset

func (x *SetRequest) Reset()

func (*SetRequest) String

func (x *SetRequest) String() string

type SetResponse

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

func (*SetResponse) Descriptor deprecated

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

Deprecated: Use SetResponse.ProtoReflect.Descriptor instead.

func (*SetResponse) ProtoMessage

func (*SetResponse) ProtoMessage()

func (*SetResponse) ProtoReflect

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

func (*SetResponse) Reset

func (x *SetResponse) Reset()

func (*SetResponse) String

func (x *SetResponse) String() string

Jump to

Keyboard shortcuts

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