api

package
v0.0.0-...-af13ce4 Latest Latest
Warning

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

Go to latest
Published: Feb 12, 2022 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Operator_name = map[int32]string{
		0: "And",
		1: "Or",
	}
	Operator_value = map[string]int32{
		"And": 0,
		"Or":  1,
	}
)

Enum value maps for Operator.

View Source
var AgentAPI_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "api.AgentAPI",
	HandlerType: (*AgentAPIServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Announce",
			Handler:    _AgentAPI_Announce_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "pkg/api/agent_api.proto",
}

AgentAPI_ServiceDesc is the grpc.ServiceDesc for AgentAPI service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var ClientAPI_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "api.ClientAPI",
	HandlerType: (*ClientAPIServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Connect",
			Handler:    _ClientAPI_Connect_Handler,
		},
		{
			MethodName: "Watch",
			Handler:    _ClientAPI_Watch_Handler,
		},
		{
			MethodName: "RunCommand",
			Handler:    _ClientAPI_RunCommand_Handler,
		},
		{
			MethodName: "RunScript",
			Handler:    _ClientAPI_RunScript_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "pkg/api/client_api.proto",
}

ClientAPI_ServiceDesc is the grpc.ServiceDesc for ClientAPI service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var File_pkg_api_agent_api_proto protoreflect.FileDescriptor
View Source
var File_pkg_api_announce_proto protoreflect.FileDescriptor
View Source
var File_pkg_api_client_api_proto protoreflect.FileDescriptor
View Source
var File_pkg_api_instructions_proto protoreflect.FileDescriptor
View Source
var File_pkg_api_relay_proto protoreflect.FileDescriptor
View Source
var Instruction_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "api.Instruction",
	HandlerType: (*InstructionServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Command",
			Handler:    _Instruction_Command_Handler,
		},
		{
			MethodName: "Script",
			Handler:    _Instruction_Script_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "pkg/api/agent_api.proto",
}

Instruction_ServiceDesc is the grpc.ServiceDesc for Instruction service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var KeyExchange_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "api.KeyExchange",
	HandlerType: (*KeyExchangeServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "ExchangeKeys",
			Handler:    _KeyExchange_ExchangeKeys_Handler,
		},
		{
			MethodName: "Sign",
			Handler:    _KeyExchange_Sign_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "pkg/api/client_api.proto",
}

KeyExchange_ServiceDesc is the grpc.ServiceDesc for KeyExchange service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var Relay_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "api.Relay",
	HandlerType: (*RelayServer)(nil),
	Methods:     []grpc.MethodDesc{},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "AgentStream",
			Handler:       _Relay_AgentStream_Handler,
			ServerStreams: true,
			ClientStreams: true,
		},
		{
			StreamName:    "ClientStream",
			Handler:       _Relay_ClientStream_Handler,
			ServerStreams: true,
			ClientStreams: true,
		},
	},
	Metadata: "pkg/api/relay.proto",
}

Relay_ServiceDesc is the grpc.ServiceDesc for Relay service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var Watch_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "api.Watch",
	HandlerType: (*WatchServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Notify",
			Handler:    _Watch_Notify_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "pkg/api/client_api.proto",
}

Watch_ServiceDesc is the grpc.ServiceDesc for Watch service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterAgentAPIServer

func RegisterAgentAPIServer(s grpc.ServiceRegistrar, srv AgentAPIServer)

func RegisterClientAPIServer

func RegisterClientAPIServer(s grpc.ServiceRegistrar, srv ClientAPIServer)

func RegisterInstructionServer

func RegisterInstructionServer(s grpc.ServiceRegistrar, srv InstructionServer)

func RegisterKeyExchangeServer

func RegisterKeyExchangeServer(s grpc.ServiceRegistrar, srv KeyExchangeServer)

func RegisterRelayServer

func RegisterRelayServer(s grpc.ServiceRegistrar, srv RelayServer)

func RegisterWatchServer

func RegisterWatchServer(s grpc.ServiceRegistrar, srv WatchServer)

Types

type Addr

type Addr struct {
	Cidr    string `protobuf:"bytes,1,opt,name=Cidr,proto3" json:"Cidr,omitempty"`
	Address string `protobuf:"bytes,2,opt,name=Address,proto3" json:"Address,omitempty"`
	Mask    string `protobuf:"bytes,3,opt,name=Mask,proto3" json:"Mask,omitempty"`
	// contains filtered or unexported fields
}

func (*Addr) Descriptor deprecated

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

Deprecated: Use Addr.ProtoReflect.Descriptor instead.

func (*Addr) GetAddress

func (x *Addr) GetAddress() string

func (*Addr) GetCidr

func (x *Addr) GetCidr() string

func (*Addr) GetMask

func (x *Addr) GetMask() string

func (*Addr) ProtoMessage

func (*Addr) ProtoMessage()

func (*Addr) ProtoReflect

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

func (*Addr) Reset

func (x *Addr) Reset()

func (*Addr) String

func (x *Addr) String() string

type AgentAPIClient

type AgentAPIClient interface {
	Announce(ctx context.Context, in *Announcement, opts ...grpc.CallOption) (*AnnouncementResponse, error)
}

AgentAPIClient is the client API for AgentAPI service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewAgentAPIClient

func NewAgentAPIClient(cc grpc.ClientConnInterface) AgentAPIClient

type AgentAPIServer

type AgentAPIServer interface {
	Announce(context.Context, *Announcement) (*AnnouncementResponse, error)
	// contains filtered or unexported methods
}

AgentAPIServer is the server API for AgentAPI service. All implementations must embed UnimplementedAgentAPIServer for forward compatibility

type Announcement

type Announcement struct {
	Uname                  *UnameInfo       `protobuf:"bytes,1,opt,name=Uname,proto3" json:"Uname,omitempty"`
	Network                *NetworkInfo     `protobuf:"bytes,2,opt,name=Network,proto3" json:"Network,omitempty"`
	PreferredHostPublicKey []byte           `protobuf:"bytes,3,opt,name=PreferredHostPublicKey,proto3" json:"PreferredHostPublicKey,omitempty"`
	AuthorizedKeys         []*AuthorizedKey `protobuf:"bytes,4,rep,name=AuthorizedKeys,proto3" json:"AuthorizedKeys,omitempty"`
	// contains filtered or unexported fields
}

func (*Announcement) Descriptor deprecated

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

Deprecated: Use Announcement.ProtoReflect.Descriptor instead.

func (*Announcement) FilterAccepts

func (a *Announcement) FilterAccepts(m *BasicFilter) bool

func (*Announcement) Fingerprint

func (a *Announcement) Fingerprint() (string, error)

func (*Announcement) GetAuthorizedKeys

func (x *Announcement) GetAuthorizedKeys() []*AuthorizedKey

func (*Announcement) GetNetwork

func (x *Announcement) GetNetwork() *NetworkInfo

func (*Announcement) GetPreferredHostPublicKey

func (x *Announcement) GetPreferredHostPublicKey() []byte

func (*Announcement) GetUname

func (x *Announcement) GetUname() *UnameInfo

func (*Announcement) ProtoMessage

func (*Announcement) ProtoMessage()

func (*Announcement) ProtoReflect

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

func (*Announcement) Reset

func (x *Announcement) Reset()

func (*Announcement) String

func (x *Announcement) String() string

type AnnouncementResponse

type AnnouncementResponse struct {
	Accept  bool   `protobuf:"varint,1,opt,name=Accept,proto3" json:"Accept,omitempty"`
	Message string `protobuf:"bytes,2,opt,name=Message,proto3" json:"Message,omitempty"`
	// contains filtered or unexported fields
}

func (*AnnouncementResponse) Descriptor deprecated

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

Deprecated: Use AnnouncementResponse.ProtoReflect.Descriptor instead.

func (*AnnouncementResponse) GetAccept

func (x *AnnouncementResponse) GetAccept() bool

func (*AnnouncementResponse) GetMessage

func (x *AnnouncementResponse) GetMessage() string

func (*AnnouncementResponse) ProtoMessage

func (*AnnouncementResponse) ProtoMessage()

func (*AnnouncementResponse) ProtoReflect

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

func (*AnnouncementResponse) Reset

func (x *AnnouncementResponse) Reset()

func (*AnnouncementResponse) String

func (x *AnnouncementResponse) String() string

type AuthorizedKey

type AuthorizedKey struct {
	User        string   `protobuf:"bytes,1,opt,name=User,proto3" json:"User,omitempty"`
	Type        string   `protobuf:"bytes,2,opt,name=Type,proto3" json:"Type,omitempty"`
	Fingerprint string   `protobuf:"bytes,3,opt,name=Fingerprint,proto3" json:"Fingerprint,omitempty"`
	Comment     string   `protobuf:"bytes,5,opt,name=Comment,proto3" json:"Comment,omitempty"`
	Options     []string `protobuf:"bytes,4,rep,name=Options,proto3" json:"Options,omitempty"`
	// contains filtered or unexported fields
}

func (*AuthorizedKey) Descriptor deprecated

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

Deprecated: Use AuthorizedKey.ProtoReflect.Descriptor instead.

func (*AuthorizedKey) GetComment

func (x *AuthorizedKey) GetComment() string

func (*AuthorizedKey) GetFingerprint

func (x *AuthorizedKey) GetFingerprint() string

func (*AuthorizedKey) GetOptions

func (x *AuthorizedKey) GetOptions() []string

func (*AuthorizedKey) GetType

func (x *AuthorizedKey) GetType() string

func (*AuthorizedKey) GetUser

func (x *AuthorizedKey) GetUser() string

func (*AuthorizedKey) ProtoMessage

func (*AuthorizedKey) ProtoMessage()

func (*AuthorizedKey) ProtoReflect

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

func (*AuthorizedKey) Reset

func (x *AuthorizedKey) Reset()

func (*AuthorizedKey) String

func (x *AuthorizedKey) String() string

type BasicFilter

type BasicFilter struct {
	Operator         Operator `protobuf:"varint,1,opt,name=Operator,proto3,enum=api.Operator" json:"Operator,omitempty"`
	HasAuthorizedKey string   `protobuf:"bytes,2,opt,name=HasAuthorizedKey,proto3" json:"HasAuthorizedKey,omitempty"`
	HasIPAddress     string   `protobuf:"bytes,3,opt,name=HasIPAddress,proto3" json:"HasIPAddress,omitempty"`
	HasHostname      string   `protobuf:"bytes,4,opt,name=HasHostname,proto3" json:"HasHostname,omitempty"`
	// contains filtered or unexported fields
}

func (*BasicFilter) Descriptor deprecated

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

Deprecated: Use BasicFilter.ProtoReflect.Descriptor instead.

func (*BasicFilter) GetHasAuthorizedKey

func (x *BasicFilter) GetHasAuthorizedKey() string

func (*BasicFilter) GetHasHostname

func (x *BasicFilter) GetHasHostname() string

func (*BasicFilter) GetHasIPAddress

func (x *BasicFilter) GetHasIPAddress() string

func (*BasicFilter) GetOperator

func (x *BasicFilter) GetOperator() Operator

func (*BasicFilter) ProtoMessage

func (*BasicFilter) ProtoMessage()

func (*BasicFilter) ProtoReflect

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

func (*BasicFilter) Reset

func (x *BasicFilter) Reset()

func (*BasicFilter) String

func (x *BasicFilter) String() string

type ClientAPIClient

type ClientAPIClient interface {
	Connect(ctx context.Context, in *ConnectionRequest, opts ...grpc.CallOption) (*ConnectionResponse, error)
	Watch(ctx context.Context, in *WatchRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
	RunCommand(ctx context.Context, in *CommandRequest, opts ...grpc.CallOption) (*CommandResponse, error)
	RunScript(ctx context.Context, in *ScriptRequest, opts ...grpc.CallOption) (*ScriptResponse, error)
}

ClientAPIClient is the client API for ClientAPI service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewClientAPIClient

func NewClientAPIClient(cc grpc.ClientConnInterface) ClientAPIClient

type ClientAPIServer

type ClientAPIServer interface {
	Connect(context.Context, *ConnectionRequest) (*ConnectionResponse, error)
	Watch(context.Context, *WatchRequest) (*emptypb.Empty, error)
	RunCommand(context.Context, *CommandRequest) (*CommandResponse, error)
	RunScript(context.Context, *ScriptRequest) (*ScriptResponse, error)
	// contains filtered or unexported methods
}

ClientAPIServer is the server API for ClientAPI service. All implementations must embed UnimplementedClientAPIServer for forward compatibility

type Command

type Command struct {
	Command string   `protobuf:"bytes,1,opt,name=Command,proto3" json:"Command,omitempty"`
	Args    []string `protobuf:"bytes,2,rep,name=Args,proto3" json:"Args,omitempty"`
	Env     []string `protobuf:"bytes,3,rep,name=Env,proto3" json:"Env,omitempty"`
	// contains filtered or unexported fields
}

func (*Command) Descriptor deprecated

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

Deprecated: Use Command.ProtoReflect.Descriptor instead.

func (*Command) GetArgs

func (x *Command) GetArgs() []string

func (*Command) GetCommand

func (x *Command) GetCommand() string

func (*Command) GetEnv

func (x *Command) GetEnv() []string

func (*Command) ProtoMessage

func (*Command) ProtoMessage()

func (*Command) ProtoReflect

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

func (*Command) Reset

func (x *Command) Reset()

func (*Command) String

func (x *Command) String() string

type CommandRequest

type CommandRequest struct {
	Meta    *InstructionMeta `protobuf:"bytes,1,opt,name=Meta,proto3" json:"Meta,omitempty"`
	Command *Command         `protobuf:"bytes,2,opt,name=Command,proto3" json:"Command,omitempty"`
	// contains filtered or unexported fields
}

func (*CommandRequest) Descriptor deprecated

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

Deprecated: Use CommandRequest.ProtoReflect.Descriptor instead.

func (*CommandRequest) GetCommand

func (x *CommandRequest) GetCommand() *Command

func (*CommandRequest) GetMeta

func (x *CommandRequest) GetMeta() *InstructionMeta

func (*CommandRequest) ProtoMessage

func (*CommandRequest) ProtoMessage()

func (*CommandRequest) ProtoReflect

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

func (*CommandRequest) Reset

func (x *CommandRequest) Reset()

func (*CommandRequest) String

func (x *CommandRequest) String() string

type CommandResponse

type CommandResponse struct {
	ExitCode int32  `protobuf:"varint,2,opt,name=ExitCode,proto3" json:"ExitCode,omitempty"`
	Stdout   string `protobuf:"bytes,3,opt,name=Stdout,proto3" json:"Stdout,omitempty"`
	Stderr   string `protobuf:"bytes,4,opt,name=Stderr,proto3" json:"Stderr,omitempty"`
	// contains filtered or unexported fields
}

func (*CommandResponse) Descriptor deprecated

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

Deprecated: Use CommandResponse.ProtoReflect.Descriptor instead.

func (*CommandResponse) GetExitCode

func (x *CommandResponse) GetExitCode() int32

func (*CommandResponse) GetStderr

func (x *CommandResponse) GetStderr() string

func (*CommandResponse) GetStdout

func (x *CommandResponse) GetStdout() string

func (*CommandResponse) ProtoMessage

func (*CommandResponse) ProtoMessage()

func (*CommandResponse) ProtoReflect

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

func (*CommandResponse) Reset

func (x *CommandResponse) Reset()

func (*CommandResponse) String

func (x *CommandResponse) String() string

type ConnectionRequest

type ConnectionRequest struct {
	PublicClientKey []byte `protobuf:"bytes,1,opt,name=PublicClientKey,proto3" json:"PublicClientKey,omitempty"`
	// contains filtered or unexported fields
}

func (*ConnectionRequest) Descriptor deprecated

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

Deprecated: Use ConnectionRequest.ProtoReflect.Descriptor instead.

func (*ConnectionRequest) GetPublicClientKey

func (x *ConnectionRequest) GetPublicClientKey() []byte

func (*ConnectionRequest) ProtoMessage

func (*ConnectionRequest) ProtoMessage()

func (*ConnectionRequest) ProtoReflect

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

func (*ConnectionRequest) Reset

func (x *ConnectionRequest) Reset()

func (*ConnectionRequest) String

func (x *ConnectionRequest) String() string

type ConnectionResponse

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

func (*ConnectionResponse) Descriptor deprecated

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

Deprecated: Use ConnectionResponse.ProtoReflect.Descriptor instead.

func (*ConnectionResponse) ProtoMessage

func (*ConnectionResponse) ProtoMessage()

func (*ConnectionResponse) ProtoReflect

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

func (*ConnectionResponse) Reset

func (x *ConnectionResponse) Reset()

func (*ConnectionResponse) String

func (x *ConnectionResponse) String() string

type InstructionClient

type InstructionClient interface {
	Command(ctx context.Context, in *CommandRequest, opts ...grpc.CallOption) (*CommandResponse, error)
	Script(ctx context.Context, in *ScriptRequest, opts ...grpc.CallOption) (*ScriptResponse, error)
}

InstructionClient is the client API for Instruction service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type InstructionMeta

type InstructionMeta struct {
	PeerFingerprint string `protobuf:"bytes,1,opt,name=PeerFingerprint,proto3" json:"PeerFingerprint,omitempty"`
	// contains filtered or unexported fields
}

func (*InstructionMeta) Descriptor deprecated

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

Deprecated: Use InstructionMeta.ProtoReflect.Descriptor instead.

func (*InstructionMeta) GetPeerFingerprint

func (x *InstructionMeta) GetPeerFingerprint() string

func (*InstructionMeta) ProtoMessage

func (*InstructionMeta) ProtoMessage()

func (*InstructionMeta) ProtoReflect

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

func (*InstructionMeta) Reset

func (x *InstructionMeta) Reset()

func (*InstructionMeta) String

func (x *InstructionMeta) String() string

type InstructionServer

type InstructionServer interface {
	Command(context.Context, *CommandRequest) (*CommandResponse, error)
	Script(context.Context, *ScriptRequest) (*ScriptResponse, error)
	// contains filtered or unexported methods
}

InstructionServer is the server API for Instruction service. All implementations must embed UnimplementedInstructionServer for forward compatibility

type KexRequest

type KexRequest struct {
	ServerEphemeralPublicKey []byte `protobuf:"bytes,1,opt,name=ServerEphemeralPublicKey,proto3" json:"ServerEphemeralPublicKey,omitempty"`
	// contains filtered or unexported fields
}

func (*KexRequest) Descriptor deprecated

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

Deprecated: Use KexRequest.ProtoReflect.Descriptor instead.

func (*KexRequest) GetServerEphemeralPublicKey

func (x *KexRequest) GetServerEphemeralPublicKey() []byte

func (*KexRequest) ProtoMessage

func (*KexRequest) ProtoMessage()

func (*KexRequest) ProtoReflect

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

func (*KexRequest) Reset

func (x *KexRequest) Reset()

func (*KexRequest) String

func (x *KexRequest) String() string

type KexResponse

type KexResponse struct {
	ClientEphemeralPublicKey []byte `protobuf:"bytes,1,opt,name=ClientEphemeralPublicKey,proto3" json:"ClientEphemeralPublicKey,omitempty"`
	// contains filtered or unexported fields
}

func (*KexResponse) Descriptor deprecated

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

Deprecated: Use KexResponse.ProtoReflect.Descriptor instead.

func (*KexResponse) GetClientEphemeralPublicKey

func (x *KexResponse) GetClientEphemeralPublicKey() []byte

func (*KexResponse) ProtoMessage

func (*KexResponse) ProtoMessage()

func (*KexResponse) ProtoReflect

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

func (*KexResponse) Reset

func (x *KexResponse) Reset()

func (*KexResponse) String

func (x *KexResponse) String() string

type KeyExchangeClient

type KeyExchangeClient interface {
	ExchangeKeys(ctx context.Context, in *KexRequest, opts ...grpc.CallOption) (*KexResponse, error)
	Sign(ctx context.Context, in *SignRequest, opts ...grpc.CallOption) (*SignResponse, error)
}

KeyExchangeClient is the client API for KeyExchange service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type KeyExchangeServer

type KeyExchangeServer interface {
	ExchangeKeys(context.Context, *KexRequest) (*KexResponse, error)
	Sign(context.Context, *SignRequest) (*SignResponse, error)
	// contains filtered or unexported methods
}

KeyExchangeServer is the server API for KeyExchange service. All implementations must embed UnimplementedKeyExchangeServer for forward compatibility

type NetworkInfo

type NetworkInfo struct {
	NetworkInterfaces []*NetworkInterface `protobuf:"bytes,1,rep,name=NetworkInterfaces,proto3" json:"NetworkInterfaces,omitempty"`
	// contains filtered or unexported fields
}

func (*NetworkInfo) Descriptor deprecated

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

Deprecated: Use NetworkInfo.ProtoReflect.Descriptor instead.

func (*NetworkInfo) GetNetworkInterfaces

func (x *NetworkInfo) GetNetworkInterfaces() []*NetworkInterface

func (*NetworkInfo) ProtoMessage

func (*NetworkInfo) ProtoMessage()

func (*NetworkInfo) ProtoReflect

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

func (*NetworkInfo) Reset

func (x *NetworkInfo) Reset()

func (*NetworkInfo) String

func (x *NetworkInfo) String() string

type NetworkInterface

type NetworkInterface struct {
	Device    string  `protobuf:"bytes,1,opt,name=Device,proto3" json:"Device,omitempty"`
	Up        bool    `protobuf:"varint,2,opt,name=Up,proto3" json:"Up,omitempty"`
	Addresses []*Addr `protobuf:"bytes,3,rep,name=Addresses,proto3" json:"Addresses,omitempty"`
	// contains filtered or unexported fields
}

func (*NetworkInterface) Descriptor deprecated

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

Deprecated: Use NetworkInterface.ProtoReflect.Descriptor instead.

func (*NetworkInterface) GetAddresses

func (x *NetworkInterface) GetAddresses() []*Addr

func (*NetworkInterface) GetDevice

func (x *NetworkInterface) GetDevice() string

func (*NetworkInterface) GetUp

func (x *NetworkInterface) GetUp() bool

func (*NetworkInterface) ProtoMessage

func (*NetworkInterface) ProtoMessage()

func (*NetworkInterface) ProtoReflect

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

func (*NetworkInterface) Reset

func (x *NetworkInterface) Reset()

func (*NetworkInterface) String

func (x *NetworkInterface) String() string

type Operator

type Operator int32
const (
	Operator_And Operator = 0
	Operator_Or  Operator = 1
)

func (Operator) Descriptor

func (Operator) Descriptor() protoreflect.EnumDescriptor

func (Operator) Enum

func (x Operator) Enum() *Operator

func (Operator) EnumDescriptor deprecated

func (Operator) EnumDescriptor() ([]byte, []int)

Deprecated: Use Operator.Descriptor instead.

func (Operator) Number

func (x Operator) Number() protoreflect.EnumNumber

func (Operator) String

func (x Operator) String() string

func (Operator) Type

type RelayClient

type RelayClient interface {
	AgentStream(ctx context.Context, opts ...grpc.CallOption) (Relay_AgentStreamClient, error)
	ClientStream(ctx context.Context, opts ...grpc.CallOption) (Relay_ClientStreamClient, error)
}

RelayClient is the client API for Relay service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewRelayClient

func NewRelayClient(cc grpc.ClientConnInterface) RelayClient

type RelayServer

type RelayServer interface {
	AgentStream(Relay_AgentStreamServer) error
	ClientStream(Relay_ClientStreamServer) error
	// contains filtered or unexported methods
}

RelayServer is the server API for Relay service. All implementations must embed UnimplementedRelayServer for forward compatibility

type Relay_AgentStreamClient

type Relay_AgentStreamClient interface {
	Send(*totem.RPC) error
	Recv() (*totem.RPC, error)
	grpc.ClientStream
}

type Relay_AgentStreamServer

type Relay_AgentStreamServer interface {
	Send(*totem.RPC) error
	Recv() (*totem.RPC, error)
	grpc.ServerStream
}

type Relay_ClientStreamClient

type Relay_ClientStreamClient interface {
	Send(*totem.RPC) error
	Recv() (*totem.RPC, error)
	grpc.ClientStream
}

type Relay_ClientStreamServer

type Relay_ClientStreamServer interface {
	Send(*totem.RPC) error
	Recv() (*totem.RPC, error)
	grpc.ServerStream
}

type Script

type Script struct {
	Interpreter string   `protobuf:"bytes,1,opt,name=Interpreter,proto3" json:"Interpreter,omitempty"`
	Script      string   `protobuf:"bytes,2,opt,name=Script,proto3" json:"Script,omitempty"`
	Args        []string `protobuf:"bytes,3,rep,name=Args,proto3" json:"Args,omitempty"`
	// contains filtered or unexported fields
}

func (*Script) Descriptor deprecated

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

Deprecated: Use Script.ProtoReflect.Descriptor instead.

func (*Script) GetArgs

func (x *Script) GetArgs() []string

func (*Script) GetInterpreter

func (x *Script) GetInterpreter() string

func (*Script) GetScript

func (x *Script) GetScript() string

func (*Script) ProtoMessage

func (*Script) ProtoMessage()

func (*Script) ProtoReflect

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

func (*Script) Reset

func (x *Script) Reset()

func (*Script) String

func (x *Script) String() string

type ScriptRequest

type ScriptRequest struct {
	Meta   *InstructionMeta `protobuf:"bytes,1,opt,name=Meta,proto3" json:"Meta,omitempty"`
	Script *Script          `protobuf:"bytes,2,opt,name=Script,proto3" json:"Script,omitempty"`
	// contains filtered or unexported fields
}

func (*ScriptRequest) Descriptor deprecated

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

Deprecated: Use ScriptRequest.ProtoReflect.Descriptor instead.

func (*ScriptRequest) GetMeta

func (x *ScriptRequest) GetMeta() *InstructionMeta

func (*ScriptRequest) GetScript

func (x *ScriptRequest) GetScript() *Script

func (*ScriptRequest) ProtoMessage

func (*ScriptRequest) ProtoMessage()

func (*ScriptRequest) ProtoReflect

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

func (*ScriptRequest) Reset

func (x *ScriptRequest) Reset()

func (*ScriptRequest) String

func (x *ScriptRequest) String() string

type ScriptResponse

type ScriptResponse struct {
	ExitCode int32  `protobuf:"varint,1,opt,name=ExitCode,proto3" json:"ExitCode,omitempty"`
	Stdout   string `protobuf:"bytes,2,opt,name=Stdout,proto3" json:"Stdout,omitempty"`
	Stderr   string `protobuf:"bytes,3,opt,name=Stderr,proto3" json:"Stderr,omitempty"`
	// contains filtered or unexported fields
}

func (*ScriptResponse) Descriptor deprecated

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

Deprecated: Use ScriptResponse.ProtoReflect.Descriptor instead.

func (*ScriptResponse) GetExitCode

func (x *ScriptResponse) GetExitCode() int32

func (*ScriptResponse) GetStderr

func (x *ScriptResponse) GetStderr() string

func (*ScriptResponse) GetStdout

func (x *ScriptResponse) GetStdout() string

func (*ScriptResponse) ProtoMessage

func (*ScriptResponse) ProtoMessage()

func (*ScriptResponse) ProtoReflect

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

func (*ScriptResponse) Reset

func (x *ScriptResponse) Reset()

func (*ScriptResponse) String

func (x *ScriptResponse) String() string

type SignRequest

type SignRequest struct {
	Nonce []byte `protobuf:"bytes,1,opt,name=Nonce,proto3" json:"Nonce,omitempty"`
	// contains filtered or unexported fields
}

func (*SignRequest) Descriptor deprecated

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

Deprecated: Use SignRequest.ProtoReflect.Descriptor instead.

func (*SignRequest) GetNonce

func (x *SignRequest) GetNonce() []byte

func (*SignRequest) ProtoMessage

func (*SignRequest) ProtoMessage()

func (*SignRequest) ProtoReflect

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

func (*SignRequest) Reset

func (x *SignRequest) Reset()

func (*SignRequest) String

func (x *SignRequest) String() string

type SignResponse

type SignResponse struct {
	Signature []byte `protobuf:"bytes,1,opt,name=Signature,proto3" json:"Signature,omitempty"`
	// contains filtered or unexported fields
}

func (*SignResponse) Descriptor deprecated

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

Deprecated: Use SignResponse.ProtoReflect.Descriptor instead.

func (*SignResponse) GetSignature

func (x *SignResponse) GetSignature() []byte

func (*SignResponse) ProtoMessage

func (*SignResponse) ProtoMessage()

func (*SignResponse) ProtoReflect

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

func (*SignResponse) Reset

func (x *SignResponse) Reset()

func (*SignResponse) String

func (x *SignResponse) String() string

type UnameInfo

type UnameInfo struct {
	KernelName    string `protobuf:"bytes,1,opt,name=KernelName,proto3" json:"KernelName,omitempty"`
	Hostname      string `protobuf:"bytes,2,opt,name=Hostname,proto3" json:"Hostname,omitempty"`
	KernelRelease string `protobuf:"bytes,3,opt,name=KernelRelease,proto3" json:"KernelRelease,omitempty"`
	KernelVersion string `protobuf:"bytes,4,opt,name=KernelVersion,proto3" json:"KernelVersion,omitempty"`
	Machine       string `protobuf:"bytes,5,opt,name=Machine,proto3" json:"Machine,omitempty"`
	// contains filtered or unexported fields
}

func (*UnameInfo) Descriptor deprecated

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

Deprecated: Use UnameInfo.ProtoReflect.Descriptor instead.

func (*UnameInfo) GetHostname

func (x *UnameInfo) GetHostname() string

func (*UnameInfo) GetKernelName

func (x *UnameInfo) GetKernelName() string

func (*UnameInfo) GetKernelRelease

func (x *UnameInfo) GetKernelRelease() string

func (*UnameInfo) GetKernelVersion

func (x *UnameInfo) GetKernelVersion() string

func (*UnameInfo) GetMachine

func (x *UnameInfo) GetMachine() string

func (*UnameInfo) ProtoMessage

func (*UnameInfo) ProtoMessage()

func (*UnameInfo) ProtoReflect

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

func (*UnameInfo) Reset

func (x *UnameInfo) Reset()

func (*UnameInfo) String

func (x *UnameInfo) String() string

type UnimplementedAgentAPIServer

type UnimplementedAgentAPIServer struct {
}

UnimplementedAgentAPIServer must be embedded to have forward compatible implementations.

func (UnimplementedAgentAPIServer) Announce

type UnimplementedClientAPIServer

type UnimplementedClientAPIServer struct {
}

UnimplementedClientAPIServer must be embedded to have forward compatible implementations.

func (UnimplementedClientAPIServer) Connect

func (UnimplementedClientAPIServer) RunCommand

func (UnimplementedClientAPIServer) RunScript

func (UnimplementedClientAPIServer) Watch

type UnimplementedInstructionServer

type UnimplementedInstructionServer struct {
}

UnimplementedInstructionServer must be embedded to have forward compatible implementations.

func (UnimplementedInstructionServer) Command

func (UnimplementedInstructionServer) Script

type UnimplementedKeyExchangeServer

type UnimplementedKeyExchangeServer struct {
}

UnimplementedKeyExchangeServer must be embedded to have forward compatible implementations.

func (UnimplementedKeyExchangeServer) ExchangeKeys

func (UnimplementedKeyExchangeServer) Sign

type UnimplementedRelayServer

type UnimplementedRelayServer struct {
}

UnimplementedRelayServer must be embedded to have forward compatible implementations.

func (UnimplementedRelayServer) AgentStream

func (UnimplementedRelayServer) ClientStream

type UnimplementedWatchServer

type UnimplementedWatchServer struct {
}

UnimplementedWatchServer must be embedded to have forward compatible implementations.

func (UnimplementedWatchServer) Notify

type UnsafeAgentAPIServer

type UnsafeAgentAPIServer interface {
	// contains filtered or unexported methods
}

UnsafeAgentAPIServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to AgentAPIServer will result in compilation errors.

type UnsafeClientAPIServer

type UnsafeClientAPIServer interface {
	// contains filtered or unexported methods
}

UnsafeClientAPIServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ClientAPIServer will result in compilation errors.

type UnsafeInstructionServer

type UnsafeInstructionServer interface {
	// contains filtered or unexported methods
}

UnsafeInstructionServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to InstructionServer will result in compilation errors.

type UnsafeKeyExchangeServer

type UnsafeKeyExchangeServer interface {
	// contains filtered or unexported methods
}

UnsafeKeyExchangeServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to KeyExchangeServer will result in compilation errors.

type UnsafeRelayServer

type UnsafeRelayServer interface {
	// contains filtered or unexported methods
}

UnsafeRelayServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to RelayServer will result in compilation errors.

type UnsafeWatchServer

type UnsafeWatchServer interface {
	// contains filtered or unexported methods
}

UnsafeWatchServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to WatchServer will result in compilation errors.

type WatchClient

type WatchClient interface {
	Notify(ctx context.Context, in *Announcement, opts ...grpc.CallOption) (*emptypb.Empty, error)
}

WatchClient is the client API for Watch service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewWatchClient

func NewWatchClient(cc grpc.ClientConnInterface) WatchClient

type WatchRequest

type WatchRequest struct {
	Filter *BasicFilter `protobuf:"bytes,1,opt,name=Filter,proto3" json:"Filter,omitempty"`
	// contains filtered or unexported fields
}

func (*WatchRequest) Descriptor deprecated

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

Deprecated: Use WatchRequest.ProtoReflect.Descriptor instead.

func (*WatchRequest) GetFilter

func (x *WatchRequest) GetFilter() *BasicFilter

func (*WatchRequest) ProtoMessage

func (*WatchRequest) ProtoMessage()

func (*WatchRequest) ProtoReflect

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

func (*WatchRequest) Reset

func (x *WatchRequest) Reset()

func (*WatchRequest) String

func (x *WatchRequest) String() string

type WatchServer

type WatchServer interface {
	Notify(context.Context, *Announcement) (*emptypb.Empty, error)
	// contains filtered or unexported methods
}

WatchServer is the server API for Watch service. All implementations must embed UnimplementedWatchServer for forward compatibility

Jump to

Keyboard shortcuts

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