Documentation
¶
Index ¶
- Constants
- Variables
- func RegisterHKPPluginServer(s grpc.ServiceRegistrar, srv HKPPluginServer)
- func RegisterPluginHostServer(s grpc.ServiceRegistrar, srv PluginHostServer)
- type Capability
- func (*Capability) Descriptor() ([]byte, []int)deprecated
- func (x *Capability) GetName() string
- func (x *Capability) GetOptions() map[string]string
- func (x *Capability) GetVersion() string
- func (*Capability) ProtoMessage()
- func (x *Capability) ProtoReflect() protoreflect.Message
- func (x *Capability) Reset()
- func (x *Capability) String() string
- type Empty
- type Event
- func (*Event) Descriptor() ([]byte, []int)deprecated
- func (x *Event) GetData() []byte
- func (x *Event) GetId() string
- func (x *Event) GetMetadata() map[string]string
- func (x *Event) GetSource() string
- func (x *Event) GetTimestamp() int64
- func (x *Event) GetType() string
- func (*Event) ProtoMessage()
- func (x *Event) ProtoReflect() protoreflect.Message
- func (x *Event) Reset()
- func (x *Event) String() string
- type EventFilter
- func (*EventFilter) Descriptor() ([]byte, []int)deprecated
- func (x *EventFilter) GetEventTypes() []string
- func (x *EventFilter) GetMetadataFilters() map[string]string
- func (*EventFilter) ProtoMessage()
- func (x *EventFilter) ProtoReflect() protoreflect.Message
- func (x *EventFilter) Reset()
- func (x *EventFilter) String() string
- type HKPPluginClient
- type HKPPluginServer
- type HKPPlugin_SubscribeEventsClient
- type HKPPlugin_SubscribeEventsServer
- type HTTPRequest
- func (*HTTPRequest) Descriptor() ([]byte, []int)deprecated
- func (x *HTTPRequest) GetBody() []byte
- func (x *HTTPRequest) GetHeaders() map[string]string
- func (x *HTTPRequest) GetId() string
- func (x *HTTPRequest) GetMethod() string
- func (x *HTTPRequest) GetPath() string
- func (x *HTTPRequest) GetQueryParams() map[string]string
- func (x *HTTPRequest) GetRemoteAddr() string
- func (*HTTPRequest) ProtoMessage()
- func (x *HTTPRequest) ProtoReflect() protoreflect.Message
- func (x *HTTPRequest) Reset()
- func (x *HTTPRequest) String() string
- type HTTPResponse
- func (*HTTPResponse) Descriptor() ([]byte, []int)deprecated
- func (x *HTTPResponse) GetBody() []byte
- func (x *HTTPResponse) GetContinueChain() bool
- func (x *HTTPResponse) GetHeaders() map[string]string
- func (x *HTTPResponse) GetStatusCode() int32
- func (*HTTPResponse) ProtoMessage()
- func (x *HTTPResponse) ProtoReflect() protoreflect.Message
- func (x *HTTPResponse) Reset()
- func (x *HTTPResponse) String() string
- type HealthStatus
- func (*HealthStatus) Descriptor() ([]byte, []int)deprecated
- func (x *HealthStatus) GetDetails() map[string]string
- func (x *HealthStatus) GetMessage() string
- func (x *HealthStatus) GetStatus() HealthStatus_Status
- func (x *HealthStatus) GetTimestamp() int64
- func (*HealthStatus) ProtoMessage()
- func (x *HealthStatus) ProtoReflect() protoreflect.Message
- func (x *HealthStatus) Reset()
- func (x *HealthStatus) String() string
- type HealthStatus_Status
- func (HealthStatus_Status) Descriptor() protoreflect.EnumDescriptor
- func (x HealthStatus_Status) Enum() *HealthStatus_Status
- func (HealthStatus_Status) EnumDescriptor() ([]byte, []int)deprecated
- func (x HealthStatus_Status) Number() protoreflect.EnumNumber
- func (x HealthStatus_Status) String() string
- func (HealthStatus_Status) Type() protoreflect.EnumType
- type HostInfo
- func (*HostInfo) Descriptor() ([]byte, []int)deprecated
- func (x *HostInfo) GetConfiguration() map[string]string
- func (x *HostInfo) GetLoadedPlugins() []*PluginInfo
- func (x *HostInfo) GetProtocolVersion() string
- func (x *HostInfo) GetVersion() string
- func (*HostInfo) ProtoMessage()
- func (x *HostInfo) ProtoReflect() protoreflect.Message
- func (x *HostInfo) Reset()
- func (x *HostInfo) String() string
- type InitRequest
- func (*InitRequest) Descriptor() ([]byte, []int)deprecated
- func (x *InitRequest) GetConfigJson() string
- func (x *InitRequest) GetEnvironment() map[string]string
- func (x *InitRequest) GetHockeypuckVersion() string
- func (x *InitRequest) GetProtocolVersion() string
- func (*InitRequest) ProtoMessage()
- func (x *InitRequest) ProtoReflect() protoreflect.Message
- func (x *InitRequest) Reset()
- func (x *InitRequest) String() string
- type InitResponse
- func (*InitResponse) Descriptor() ([]byte, []int)deprecated
- func (x *InitResponse) GetError() string
- func (x *InitResponse) GetInfo() *PluginInfo
- func (x *InitResponse) GetSuccess() bool
- func (*InitResponse) ProtoMessage()
- func (x *InitResponse) ProtoReflect() protoreflect.Message
- func (x *InitResponse) Reset()
- func (x *InitResponse) String() string
- type KeyChangeEvent
- func (*KeyChangeEvent) Descriptor() ([]byte, []int)deprecated
- func (x *KeyChangeEvent) GetChangeType() KeyChangeEvent_ChangeType
- func (x *KeyChangeEvent) GetFingerprint() string
- func (x *KeyChangeEvent) GetId() string
- func (x *KeyChangeEvent) GetKeyData() []byte
- func (x *KeyChangeEvent) GetTimestamp() int64
- func (*KeyChangeEvent) ProtoMessage()
- func (x *KeyChangeEvent) ProtoReflect() protoreflect.Message
- func (x *KeyChangeEvent) Reset()
- func (x *KeyChangeEvent) String() string
- type KeyChangeEvent_ChangeType
- func (KeyChangeEvent_ChangeType) Descriptor() protoreflect.EnumDescriptor
- func (x KeyChangeEvent_ChangeType) Enum() *KeyChangeEvent_ChangeType
- func (KeyChangeEvent_ChangeType) EnumDescriptor() ([]byte, []int)deprecated
- func (x KeyChangeEvent_ChangeType) Number() protoreflect.EnumNumber
- func (x KeyChangeEvent_ChangeType) String() string
- func (KeyChangeEvent_ChangeType) Type() protoreflect.EnumType
- type KeyInfo
- func (*KeyInfo) Descriptor() ([]byte, []int)deprecated
- func (x *KeyInfo) GetCreationTime() int64
- func (x *KeyInfo) GetExpirationTime() int64
- func (x *KeyInfo) GetFingerprint() string
- func (x *KeyInfo) GetKeyData() []byte
- func (x *KeyInfo) GetKeyId() string
- func (x *KeyInfo) GetRevoked() bool
- func (x *KeyInfo) GetUserIds() []string
- func (*KeyInfo) ProtoMessage()
- func (x *KeyInfo) ProtoReflect() protoreflect.Message
- func (x *KeyInfo) Reset()
- func (x *KeyInfo) String() string
- type PluginHostClient
- type PluginHostServer
- type PluginInfo
- func (*PluginInfo) Descriptor() ([]byte, []int)deprecated
- func (x *PluginInfo) GetCapabilities() []string
- func (x *PluginInfo) GetDescription() string
- func (x *PluginInfo) GetMetadata() map[string]string
- func (x *PluginInfo) GetName() string
- func (x *PluginInfo) GetVersion() string
- func (*PluginInfo) ProtoMessage()
- func (x *PluginInfo) ProtoReflect() protoreflect.Message
- func (x *PluginInfo) Reset()
- func (x *PluginInfo) String() string
- type PluginQuery
- func (*PluginQuery) Descriptor() ([]byte, []int)deprecated
- func (x *PluginQuery) GetData() []byte
- func (x *PluginQuery) GetMethod() string
- func (x *PluginQuery) GetTargetPlugin() string
- func (*PluginQuery) ProtoMessage()
- func (x *PluginQuery) ProtoReflect() protoreflect.Message
- func (x *PluginQuery) Reset()
- func (x *PluginQuery) String() string
- type PluginResponse
- func (*PluginResponse) Descriptor() ([]byte, []int)deprecated
- func (x *PluginResponse) GetData() []byte
- func (x *PluginResponse) GetError() string
- func (x *PluginResponse) GetSuccess() bool
- func (*PluginResponse) ProtoMessage()
- func (x *PluginResponse) ProtoReflect() protoreflect.Message
- func (x *PluginResponse) Reset()
- func (x *PluginResponse) String() string
- type RateLimitCheck
- func (*RateLimitCheck) Descriptor() ([]byte, []int)deprecated
- func (x *RateLimitCheck) GetAction() string
- func (x *RateLimitCheck) GetIdentifier() string
- func (x *RateLimitCheck) GetMetadata() map[string]string
- func (*RateLimitCheck) ProtoMessage()
- func (x *RateLimitCheck) ProtoReflect() protoreflect.Message
- func (x *RateLimitCheck) Reset()
- func (x *RateLimitCheck) String() string
- type RateLimitResponse
- func (*RateLimitResponse) Descriptor() ([]byte, []int)deprecated
- func (x *RateLimitResponse) GetAllowed() bool
- func (x *RateLimitResponse) GetHeaders() map[string]string
- func (x *RateLimitResponse) GetReason() string
- func (x *RateLimitResponse) GetRetryAfterSeconds() int32
- func (*RateLimitResponse) ProtoMessage()
- func (x *RateLimitResponse) ProtoReflect() protoreflect.Message
- func (x *RateLimitResponse) Reset()
- func (x *RateLimitResponse) String() string
- type ShutdownRequest
- func (*ShutdownRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ShutdownRequest) GetReason() string
- func (x *ShutdownRequest) GetTimeoutSeconds() int32
- func (*ShutdownRequest) ProtoMessage()
- func (x *ShutdownRequest) ProtoReflect() protoreflect.Message
- func (x *ShutdownRequest) Reset()
- func (x *ShutdownRequest) String() string
- type ShutdownResponse
- func (*ShutdownResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ShutdownResponse) GetError() string
- func (x *ShutdownResponse) GetSuccess() bool
- func (*ShutdownResponse) ProtoMessage()
- func (x *ShutdownResponse) ProtoReflect() protoreflect.Message
- func (x *ShutdownResponse) Reset()
- func (x *ShutdownResponse) String() string
- type StorageQuery
- func (*StorageQuery) Descriptor() ([]byte, []int)deprecated
- func (x *StorageQuery) GetLimit() int32
- func (x *StorageQuery) GetOffset() int32
- func (x *StorageQuery) GetOptions() map[string]string
- func (x *StorageQuery) GetQuery() string
- func (x *StorageQuery) GetType() StorageQuery_QueryType
- func (*StorageQuery) ProtoMessage()
- func (x *StorageQuery) ProtoReflect() protoreflect.Message
- func (x *StorageQuery) Reset()
- func (x *StorageQuery) String() string
- type StorageQuery_QueryType
- func (StorageQuery_QueryType) Descriptor() protoreflect.EnumDescriptor
- func (x StorageQuery_QueryType) Enum() *StorageQuery_QueryType
- func (StorageQuery_QueryType) EnumDescriptor() ([]byte, []int)deprecated
- func (x StorageQuery_QueryType) Number() protoreflect.EnumNumber
- func (x StorageQuery_QueryType) String() string
- func (StorageQuery_QueryType) Type() protoreflect.EnumType
- type StorageResponse
- func (*StorageResponse) Descriptor() ([]byte, []int)deprecated
- func (x *StorageResponse) GetError() string
- func (x *StorageResponse) GetKeys() []*KeyInfo
- func (x *StorageResponse) GetSuccess() bool
- func (x *StorageResponse) GetTotalCount() int32
- func (*StorageResponse) ProtoMessage()
- func (x *StorageResponse) ProtoReflect() protoreflect.Message
- func (x *StorageResponse) Reset()
- func (x *StorageResponse) String() string
- type ThreatInfo
- func (*ThreatInfo) Descriptor() ([]byte, []int)deprecated
- func (x *ThreatInfo) GetDescription() string
- func (x *ThreatInfo) GetId() string
- func (x *ThreatInfo) GetIndicators() map[string]string
- func (x *ThreatInfo) GetLevel() ThreatInfo_ThreatLevel
- func (x *ThreatInfo) GetSource() string
- func (x *ThreatInfo) GetTimestamp() int64
- func (x *ThreatInfo) GetType() string
- func (*ThreatInfo) ProtoMessage()
- func (x *ThreatInfo) ProtoReflect() protoreflect.Message
- func (x *ThreatInfo) Reset()
- func (x *ThreatInfo) String() string
- type ThreatInfo_ThreatLevel
- func (ThreatInfo_ThreatLevel) Descriptor() protoreflect.EnumDescriptor
- func (x ThreatInfo_ThreatLevel) Enum() *ThreatInfo_ThreatLevel
- func (ThreatInfo_ThreatLevel) EnumDescriptor() ([]byte, []int)deprecated
- func (x ThreatInfo_ThreatLevel) Number() protoreflect.EnumNumber
- func (x ThreatInfo_ThreatLevel) String() string
- func (ThreatInfo_ThreatLevel) Type() protoreflect.EnumType
- type UnimplementedHKPPluginServer
- func (UnimplementedHKPPluginServer) CheckRateLimit(context.Context, *RateLimitCheck) (*RateLimitResponse, error)
- func (UnimplementedHKPPluginServer) GetInfo(context.Context, *Empty) (*PluginInfo, error)
- func (UnimplementedHKPPluginServer) HandleHTTPRequest(context.Context, *HTTPRequest) (*HTTPResponse, error)
- func (UnimplementedHKPPluginServer) HandleKeyChange(context.Context, *KeyChangeEvent) (*Event, error)
- func (UnimplementedHKPPluginServer) HealthCheck(context.Context, *Empty) (*HealthStatus, error)
- func (UnimplementedHKPPluginServer) Initialize(context.Context, *InitRequest) (*InitResponse, error)
- func (UnimplementedHKPPluginServer) PublishEvent(context.Context, *Event) (*Empty, error)
- func (UnimplementedHKPPluginServer) QueryStorage(context.Context, *StorageQuery) (*StorageResponse, error)
- func (UnimplementedHKPPluginServer) ReportThreat(context.Context, *ThreatInfo) (*Empty, error)
- func (UnimplementedHKPPluginServer) Shutdown(context.Context, *ShutdownRequest) (*ShutdownResponse, error)
- func (UnimplementedHKPPluginServer) SubscribeEvents(*EventFilter, grpc.ServerStreamingServer[Event]) error
- type UnimplementedPluginHostServer
- func (UnimplementedPluginHostServer) GetHostInfo(context.Context, *Empty) (*HostInfo, error)
- func (UnimplementedPluginHostServer) PublishEvent(context.Context, *Event) (*Empty, error)
- func (UnimplementedPluginHostServer) QueryPlugin(context.Context, *PluginQuery) (*PluginResponse, error)
- func (UnimplementedPluginHostServer) RequestStorage(context.Context, *StorageQuery) (*StorageResponse, error)
- type UnsafeHKPPluginServer
- type UnsafePluginHostServer
Constants ¶
const ( HKPPlugin_Initialize_FullMethodName = "/hkpplugin.HKPPlugin/Initialize" HKPPlugin_Shutdown_FullMethodName = "/hkpplugin.HKPPlugin/Shutdown" HKPPlugin_GetInfo_FullMethodName = "/hkpplugin.HKPPlugin/GetInfo" HKPPlugin_HandleHTTPRequest_FullMethodName = "/hkpplugin.HKPPlugin/HandleHTTPRequest" HKPPlugin_HandleKeyChange_FullMethodName = "/hkpplugin.HKPPlugin/HandleKeyChange" HKPPlugin_SubscribeEvents_FullMethodName = "/hkpplugin.HKPPlugin/SubscribeEvents" HKPPlugin_PublishEvent_FullMethodName = "/hkpplugin.HKPPlugin/PublishEvent" HKPPlugin_QueryStorage_FullMethodName = "/hkpplugin.HKPPlugin/QueryStorage" HKPPlugin_HealthCheck_FullMethodName = "/hkpplugin.HKPPlugin/HealthCheck" HKPPlugin_CheckRateLimit_FullMethodName = "/hkpplugin.HKPPlugin/CheckRateLimit" HKPPlugin_ReportThreat_FullMethodName = "/hkpplugin.HKPPlugin/ReportThreat" )
const ( PluginHost_GetHostInfo_FullMethodName = "/hkpplugin.PluginHost/GetHostInfo" PluginHost_RequestStorage_FullMethodName = "/hkpplugin.PluginHost/RequestStorage" PluginHost_PublishEvent_FullMethodName = "/hkpplugin.PluginHost/PublishEvent" PluginHost_QueryPlugin_FullMethodName = "/hkpplugin.PluginHost/QueryPlugin" )
Variables ¶
var ( KeyChangeEvent_ChangeType_name = map[int32]string{ 0: "UNKNOWN", 1: "CREATE", 2: "UPDATE", 3: "DELETE", } KeyChangeEvent_ChangeType_value = map[string]int32{ "UNKNOWN": 0, "CREATE": 1, "UPDATE": 2, "DELETE": 3, } )
Enum value maps for KeyChangeEvent_ChangeType.
var ( StorageQuery_QueryType_name = map[int32]string{ 0: "LOOKUP", 1: "SEARCH", 2: "FETCH", } StorageQuery_QueryType_value = map[string]int32{ "LOOKUP": 0, "SEARCH": 1, "FETCH": 2, } )
Enum value maps for StorageQuery_QueryType.
var ( HealthStatus_Status_name = map[int32]string{ 0: "UNKNOWN", 1: "HEALTHY", 2: "DEGRADED", 3: "UNHEALTHY", } HealthStatus_Status_value = map[string]int32{ "UNKNOWN": 0, "HEALTHY": 1, "DEGRADED": 2, "UNHEALTHY": 3, } )
Enum value maps for HealthStatus_Status.
var ( ThreatInfo_ThreatLevel_name = map[int32]string{ 0: "UNKNOWN", 1: "LOW", 2: "MEDIUM", 3: "HIGH", 4: "CRITICAL", } ThreatInfo_ThreatLevel_value = map[string]int32{ "UNKNOWN": 0, "LOW": 1, "MEDIUM": 2, "HIGH": 3, "CRITICAL": 4, } )
Enum value maps for ThreatInfo_ThreatLevel.
var File_proto_hkp_plugin_proto protoreflect.FileDescriptor
var HKPPlugin_ServiceDesc = grpc.ServiceDesc{ ServiceName: "hkpplugin.HKPPlugin", HandlerType: (*HKPPluginServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Initialize", Handler: _HKPPlugin_Initialize_Handler, }, { MethodName: "Shutdown", Handler: _HKPPlugin_Shutdown_Handler, }, { MethodName: "GetInfo", Handler: _HKPPlugin_GetInfo_Handler, }, { MethodName: "HandleHTTPRequest", Handler: _HKPPlugin_HandleHTTPRequest_Handler, }, { MethodName: "HandleKeyChange", Handler: _HKPPlugin_HandleKeyChange_Handler, }, { MethodName: "PublishEvent", Handler: _HKPPlugin_PublishEvent_Handler, }, { MethodName: "QueryStorage", Handler: _HKPPlugin_QueryStorage_Handler, }, { MethodName: "HealthCheck", Handler: _HKPPlugin_HealthCheck_Handler, }, { MethodName: "CheckRateLimit", Handler: _HKPPlugin_CheckRateLimit_Handler, }, { MethodName: "ReportThreat", Handler: _HKPPlugin_ReportThreat_Handler, }, }, Streams: []grpc.StreamDesc{ { StreamName: "SubscribeEvents", Handler: _HKPPlugin_SubscribeEvents_Handler, ServerStreams: true, }, }, Metadata: "proto/hkp_plugin.proto", }
HKPPlugin_ServiceDesc is the grpc.ServiceDesc for HKPPlugin service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var PluginHost_ServiceDesc = grpc.ServiceDesc{ ServiceName: "hkpplugin.PluginHost", HandlerType: (*PluginHostServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GetHostInfo", Handler: _PluginHost_GetHostInfo_Handler, }, { MethodName: "RequestStorage", Handler: _PluginHost_RequestStorage_Handler, }, { MethodName: "PublishEvent", Handler: _PluginHost_PublishEvent_Handler, }, { MethodName: "QueryPlugin", Handler: _PluginHost_QueryPlugin_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "proto/hkp_plugin.proto", }
PluginHost_ServiceDesc is the grpc.ServiceDesc for PluginHost service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterHKPPluginServer ¶
func RegisterHKPPluginServer(s grpc.ServiceRegistrar, srv HKPPluginServer)
func RegisterPluginHostServer ¶
func RegisterPluginHostServer(s grpc.ServiceRegistrar, srv PluginHostServer)
Types ¶
type Capability ¶
type Capability struct {
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
Version string `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"`
Options map[string]string `` /* 141-byte string literal not displayed */
// contains filtered or unexported fields
}
Plugin capabilities
func (*Capability) Descriptor
deprecated
func (*Capability) Descriptor() ([]byte, []int)
Deprecated: Use Capability.ProtoReflect.Descriptor instead.
func (*Capability) GetName ¶
func (x *Capability) GetName() string
func (*Capability) GetOptions ¶
func (x *Capability) GetOptions() map[string]string
func (*Capability) GetVersion ¶
func (x *Capability) GetVersion() string
func (*Capability) ProtoMessage ¶
func (*Capability) ProtoMessage()
func (*Capability) ProtoReflect ¶
func (x *Capability) ProtoReflect() protoreflect.Message
func (*Capability) Reset ¶
func (x *Capability) Reset()
func (*Capability) String ¶
func (x *Capability) String() string
type Empty ¶
type Empty struct {
// contains filtered or unexported fields
}
Empty message for methods that don't require parameters
func (*Empty) Descriptor
deprecated
func (*Empty) ProtoMessage ¶
func (*Empty) ProtoMessage()
func (*Empty) ProtoReflect ¶
func (x *Empty) ProtoReflect() protoreflect.Message
type Event ¶
type Event struct {
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
Type string `protobuf:"bytes,2,opt,name=type,proto3" json:"type,omitempty"`
Data []byte `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"` // JSON-encoded event data
Timestamp int64 `protobuf:"varint,4,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
Source string `protobuf:"bytes,5,opt,name=source,proto3" json:"source,omitempty"`
Metadata map[string]string `` /* 143-byte string literal not displayed */
// contains filtered or unexported fields
}
func (*Event) Descriptor
deprecated
func (*Event) GetMetadata ¶
func (*Event) GetTimestamp ¶
func (*Event) ProtoMessage ¶
func (*Event) ProtoMessage()
func (*Event) ProtoReflect ¶
func (x *Event) ProtoReflect() protoreflect.Message
type EventFilter ¶
type EventFilter struct {
EventTypes []string `protobuf:"bytes,1,rep,name=event_types,json=eventTypes,proto3" json:"event_types,omitempty"`
MetadataFilters map[string]string `` /* 180-byte string literal not displayed */
// contains filtered or unexported fields
}
Event subscription
func (*EventFilter) Descriptor
deprecated
func (*EventFilter) Descriptor() ([]byte, []int)
Deprecated: Use EventFilter.ProtoReflect.Descriptor instead.
func (*EventFilter) GetEventTypes ¶
func (x *EventFilter) GetEventTypes() []string
func (*EventFilter) GetMetadataFilters ¶
func (x *EventFilter) GetMetadataFilters() map[string]string
func (*EventFilter) ProtoMessage ¶
func (*EventFilter) ProtoMessage()
func (*EventFilter) ProtoReflect ¶
func (x *EventFilter) ProtoReflect() protoreflect.Message
func (*EventFilter) Reset ¶
func (x *EventFilter) Reset()
func (*EventFilter) String ¶
func (x *EventFilter) String() string
type HKPPluginClient ¶
type HKPPluginClient interface {
// Lifecycle management
Initialize(ctx context.Context, in *InitRequest, opts ...grpc.CallOption) (*InitResponse, error)
Shutdown(ctx context.Context, in *ShutdownRequest, opts ...grpc.CallOption) (*ShutdownResponse, error)
// Plugin information
GetInfo(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*PluginInfo, error)
// HTTP middleware
HandleHTTPRequest(ctx context.Context, in *HTTPRequest, opts ...grpc.CallOption) (*HTTPResponse, error)
// Event handling
HandleKeyChange(ctx context.Context, in *KeyChangeEvent, opts ...grpc.CallOption) (*Event, error)
SubscribeEvents(ctx context.Context, in *EventFilter, opts ...grpc.CallOption) (grpc.ServerStreamingClient[Event], error)
PublishEvent(ctx context.Context, in *Event, opts ...grpc.CallOption) (*Empty, error)
// Storage access (proxied)
QueryStorage(ctx context.Context, in *StorageQuery, opts ...grpc.CallOption) (*StorageResponse, error)
// Health monitoring
HealthCheck(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*HealthStatus, error)
// Rate limiting
CheckRateLimit(ctx context.Context, in *RateLimitCheck, opts ...grpc.CallOption) (*RateLimitResponse, error)
// Threat detection
ReportThreat(ctx context.Context, in *ThreatInfo, opts ...grpc.CallOption) (*Empty, error)
}
HKPPluginClient is the client API for HKPPlugin 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.
The main plugin service
func NewHKPPluginClient ¶
func NewHKPPluginClient(cc grpc.ClientConnInterface) HKPPluginClient
type HKPPluginServer ¶
type HKPPluginServer interface {
// Lifecycle management
Initialize(context.Context, *InitRequest) (*InitResponse, error)
Shutdown(context.Context, *ShutdownRequest) (*ShutdownResponse, error)
// Plugin information
GetInfo(context.Context, *Empty) (*PluginInfo, error)
// HTTP middleware
HandleHTTPRequest(context.Context, *HTTPRequest) (*HTTPResponse, error)
// Event handling
HandleKeyChange(context.Context, *KeyChangeEvent) (*Event, error)
SubscribeEvents(*EventFilter, grpc.ServerStreamingServer[Event]) error
PublishEvent(context.Context, *Event) (*Empty, error)
// Storage access (proxied)
QueryStorage(context.Context, *StorageQuery) (*StorageResponse, error)
// Health monitoring
HealthCheck(context.Context, *Empty) (*HealthStatus, error)
// Rate limiting
CheckRateLimit(context.Context, *RateLimitCheck) (*RateLimitResponse, error)
// Threat detection
ReportThreat(context.Context, *ThreatInfo) (*Empty, error)
// contains filtered or unexported methods
}
HKPPluginServer is the server API for HKPPlugin service. All implementations must embed UnimplementedHKPPluginServer for forward compatibility.
The main plugin service
type HKPPlugin_SubscribeEventsClient ¶
type HKPPlugin_SubscribeEventsClient = grpc.ServerStreamingClient[Event]
This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.
type HKPPlugin_SubscribeEventsServer ¶
type HKPPlugin_SubscribeEventsServer = grpc.ServerStreamingServer[Event]
This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.
type HTTPRequest ¶
type HTTPRequest struct {
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
Method string `protobuf:"bytes,2,opt,name=method,proto3" json:"method,omitempty"`
Path string `protobuf:"bytes,3,opt,name=path,proto3" json:"path,omitempty"`
Headers map[string]string `` /* 141-byte string literal not displayed */
Body []byte `protobuf:"bytes,5,opt,name=body,proto3" json:"body,omitempty"`
RemoteAddr string `protobuf:"bytes,6,opt,name=remote_addr,json=remoteAddr,proto3" json:"remote_addr,omitempty"`
QueryParams map[string]string `` /* 168-byte string literal not displayed */
// contains filtered or unexported fields
}
HTTP request handling
func (*HTTPRequest) Descriptor
deprecated
func (*HTTPRequest) Descriptor() ([]byte, []int)
Deprecated: Use HTTPRequest.ProtoReflect.Descriptor instead.
func (*HTTPRequest) GetBody ¶
func (x *HTTPRequest) GetBody() []byte
func (*HTTPRequest) GetHeaders ¶
func (x *HTTPRequest) GetHeaders() map[string]string
func (*HTTPRequest) GetId ¶
func (x *HTTPRequest) GetId() string
func (*HTTPRequest) GetMethod ¶
func (x *HTTPRequest) GetMethod() string
func (*HTTPRequest) GetPath ¶
func (x *HTTPRequest) GetPath() string
func (*HTTPRequest) GetQueryParams ¶
func (x *HTTPRequest) GetQueryParams() map[string]string
func (*HTTPRequest) GetRemoteAddr ¶
func (x *HTTPRequest) GetRemoteAddr() string
func (*HTTPRequest) ProtoMessage ¶
func (*HTTPRequest) ProtoMessage()
func (*HTTPRequest) ProtoReflect ¶
func (x *HTTPRequest) ProtoReflect() protoreflect.Message
func (*HTTPRequest) Reset ¶
func (x *HTTPRequest) Reset()
func (*HTTPRequest) String ¶
func (x *HTTPRequest) String() string
type HTTPResponse ¶
type HTTPResponse struct {
StatusCode int32 `protobuf:"varint,1,opt,name=status_code,json=statusCode,proto3" json:"status_code,omitempty"`
Headers map[string]string `` /* 141-byte string literal not displayed */
Body []byte `protobuf:"bytes,3,opt,name=body,proto3" json:"body,omitempty"`
ContinueChain bool `protobuf:"varint,4,opt,name=continue_chain,json=continueChain,proto3" json:"continue_chain,omitempty"` // Whether to continue middleware chain
// contains filtered or unexported fields
}
func (*HTTPResponse) Descriptor
deprecated
func (*HTTPResponse) Descriptor() ([]byte, []int)
Deprecated: Use HTTPResponse.ProtoReflect.Descriptor instead.
func (*HTTPResponse) GetBody ¶
func (x *HTTPResponse) GetBody() []byte
func (*HTTPResponse) GetContinueChain ¶
func (x *HTTPResponse) GetContinueChain() bool
func (*HTTPResponse) GetHeaders ¶
func (x *HTTPResponse) GetHeaders() map[string]string
func (*HTTPResponse) GetStatusCode ¶
func (x *HTTPResponse) GetStatusCode() int32
func (*HTTPResponse) ProtoMessage ¶
func (*HTTPResponse) ProtoMessage()
func (*HTTPResponse) ProtoReflect ¶
func (x *HTTPResponse) ProtoReflect() protoreflect.Message
func (*HTTPResponse) Reset ¶
func (x *HTTPResponse) Reset()
func (*HTTPResponse) String ¶
func (x *HTTPResponse) String() string
type HealthStatus ¶
type HealthStatus struct {
Status HealthStatus_Status `protobuf:"varint,1,opt,name=status,proto3,enum=hkpplugin.HealthStatus_Status" json:"status,omitempty"`
Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
Details map[string]string `` /* 141-byte string literal not displayed */
Timestamp int64 `protobuf:"varint,4,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
// contains filtered or unexported fields
}
Health checks
func (*HealthStatus) Descriptor
deprecated
func (*HealthStatus) Descriptor() ([]byte, []int)
Deprecated: Use HealthStatus.ProtoReflect.Descriptor instead.
func (*HealthStatus) GetDetails ¶
func (x *HealthStatus) GetDetails() map[string]string
func (*HealthStatus) GetMessage ¶
func (x *HealthStatus) GetMessage() string
func (*HealthStatus) GetStatus ¶
func (x *HealthStatus) GetStatus() HealthStatus_Status
func (*HealthStatus) GetTimestamp ¶
func (x *HealthStatus) GetTimestamp() int64
func (*HealthStatus) ProtoMessage ¶
func (*HealthStatus) ProtoMessage()
func (*HealthStatus) ProtoReflect ¶
func (x *HealthStatus) ProtoReflect() protoreflect.Message
func (*HealthStatus) Reset ¶
func (x *HealthStatus) Reset()
func (*HealthStatus) String ¶
func (x *HealthStatus) String() string
type HealthStatus_Status ¶
type HealthStatus_Status int32
const ( HealthStatus_UNKNOWN HealthStatus_Status = 0 HealthStatus_HEALTHY HealthStatus_Status = 1 HealthStatus_DEGRADED HealthStatus_Status = 2 HealthStatus_UNHEALTHY HealthStatus_Status = 3 )
func (HealthStatus_Status) Descriptor ¶
func (HealthStatus_Status) Descriptor() protoreflect.EnumDescriptor
func (HealthStatus_Status) Enum ¶
func (x HealthStatus_Status) Enum() *HealthStatus_Status
func (HealthStatus_Status) EnumDescriptor
deprecated
func (HealthStatus_Status) EnumDescriptor() ([]byte, []int)
Deprecated: Use HealthStatus_Status.Descriptor instead.
func (HealthStatus_Status) Number ¶
func (x HealthStatus_Status) Number() protoreflect.EnumNumber
func (HealthStatus_Status) String ¶
func (x HealthStatus_Status) String() string
func (HealthStatus_Status) Type ¶
func (HealthStatus_Status) Type() protoreflect.EnumType
type HostInfo ¶
type HostInfo struct {
Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"`
ProtocolVersion string `protobuf:"bytes,2,opt,name=protocol_version,json=protocolVersion,proto3" json:"protocol_version,omitempty"`
LoadedPlugins []*PluginInfo `protobuf:"bytes,3,rep,name=loaded_plugins,json=loadedPlugins,proto3" json:"loaded_plugins,omitempty"`
Configuration map[string]string `` /* 153-byte string literal not displayed */
// contains filtered or unexported fields
}
func (*HostInfo) Descriptor
deprecated
func (*HostInfo) GetConfiguration ¶
func (*HostInfo) GetLoadedPlugins ¶
func (x *HostInfo) GetLoadedPlugins() []*PluginInfo
func (*HostInfo) GetProtocolVersion ¶
func (*HostInfo) GetVersion ¶
func (*HostInfo) ProtoMessage ¶
func (*HostInfo) ProtoMessage()
func (*HostInfo) ProtoReflect ¶
func (x *HostInfo) ProtoReflect() protoreflect.Message
type InitRequest ¶
type InitRequest struct {
ConfigJson string `protobuf:"bytes,1,opt,name=config_json,json=configJson,proto3" json:"config_json,omitempty"` // JSON-encoded configuration
HockeypuckVersion string `protobuf:"bytes,2,opt,name=hockeypuck_version,json=hockeypuckVersion,proto3" json:"hockeypuck_version,omitempty"`
ProtocolVersion string `protobuf:"bytes,3,opt,name=protocol_version,json=protocolVersion,proto3" json:"protocol_version,omitempty"`
Environment map[string]string `` /* 149-byte string literal not displayed */
// contains filtered or unexported fields
}
Plugin initialization
func (*InitRequest) Descriptor
deprecated
func (*InitRequest) Descriptor() ([]byte, []int)
Deprecated: Use InitRequest.ProtoReflect.Descriptor instead.
func (*InitRequest) GetConfigJson ¶
func (x *InitRequest) GetConfigJson() string
func (*InitRequest) GetEnvironment ¶
func (x *InitRequest) GetEnvironment() map[string]string
func (*InitRequest) GetHockeypuckVersion ¶
func (x *InitRequest) GetHockeypuckVersion() string
func (*InitRequest) GetProtocolVersion ¶
func (x *InitRequest) GetProtocolVersion() string
func (*InitRequest) ProtoMessage ¶
func (*InitRequest) ProtoMessage()
func (*InitRequest) ProtoReflect ¶
func (x *InitRequest) ProtoReflect() protoreflect.Message
func (*InitRequest) Reset ¶
func (x *InitRequest) Reset()
func (*InitRequest) String ¶
func (x *InitRequest) String() string
type InitResponse ¶
type InitResponse struct {
Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"`
Error string `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"`
Info *PluginInfo `protobuf:"bytes,3,opt,name=info,proto3" json:"info,omitempty"`
// contains filtered or unexported fields
}
func (*InitResponse) Descriptor
deprecated
func (*InitResponse) Descriptor() ([]byte, []int)
Deprecated: Use InitResponse.ProtoReflect.Descriptor instead.
func (*InitResponse) GetError ¶
func (x *InitResponse) GetError() string
func (*InitResponse) GetInfo ¶
func (x *InitResponse) GetInfo() *PluginInfo
func (*InitResponse) GetSuccess ¶
func (x *InitResponse) GetSuccess() bool
func (*InitResponse) ProtoMessage ¶
func (*InitResponse) ProtoMessage()
func (*InitResponse) ProtoReflect ¶
func (x *InitResponse) ProtoReflect() protoreflect.Message
func (*InitResponse) Reset ¶
func (x *InitResponse) Reset()
func (*InitResponse) String ¶
func (x *InitResponse) String() string
type KeyChangeEvent ¶
type KeyChangeEvent struct {
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
ChangeType KeyChangeEvent_ChangeType `` /* 133-byte string literal not displayed */
Fingerprint string `protobuf:"bytes,3,opt,name=fingerprint,proto3" json:"fingerprint,omitempty"`
KeyData []byte `protobuf:"bytes,4,opt,name=key_data,json=keyData,proto3" json:"key_data,omitempty"` // OpenPGP key data
Timestamp int64 `protobuf:"varint,5,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
// contains filtered or unexported fields
}
Key change events (Hockeypuck compatibility)
func (*KeyChangeEvent) Descriptor
deprecated
func (*KeyChangeEvent) Descriptor() ([]byte, []int)
Deprecated: Use KeyChangeEvent.ProtoReflect.Descriptor instead.
func (*KeyChangeEvent) GetChangeType ¶
func (x *KeyChangeEvent) GetChangeType() KeyChangeEvent_ChangeType
func (*KeyChangeEvent) GetFingerprint ¶
func (x *KeyChangeEvent) GetFingerprint() string
func (*KeyChangeEvent) GetId ¶
func (x *KeyChangeEvent) GetId() string
func (*KeyChangeEvent) GetKeyData ¶
func (x *KeyChangeEvent) GetKeyData() []byte
func (*KeyChangeEvent) GetTimestamp ¶
func (x *KeyChangeEvent) GetTimestamp() int64
func (*KeyChangeEvent) ProtoMessage ¶
func (*KeyChangeEvent) ProtoMessage()
func (*KeyChangeEvent) ProtoReflect ¶
func (x *KeyChangeEvent) ProtoReflect() protoreflect.Message
func (*KeyChangeEvent) Reset ¶
func (x *KeyChangeEvent) Reset()
func (*KeyChangeEvent) String ¶
func (x *KeyChangeEvent) String() string
type KeyChangeEvent_ChangeType ¶
type KeyChangeEvent_ChangeType int32
const ( KeyChangeEvent_UNKNOWN KeyChangeEvent_ChangeType = 0 KeyChangeEvent_CREATE KeyChangeEvent_ChangeType = 1 KeyChangeEvent_UPDATE KeyChangeEvent_ChangeType = 2 KeyChangeEvent_DELETE KeyChangeEvent_ChangeType = 3 )
func (KeyChangeEvent_ChangeType) Descriptor ¶
func (KeyChangeEvent_ChangeType) Descriptor() protoreflect.EnumDescriptor
func (KeyChangeEvent_ChangeType) Enum ¶
func (x KeyChangeEvent_ChangeType) Enum() *KeyChangeEvent_ChangeType
func (KeyChangeEvent_ChangeType) EnumDescriptor
deprecated
func (KeyChangeEvent_ChangeType) EnumDescriptor() ([]byte, []int)
Deprecated: Use KeyChangeEvent_ChangeType.Descriptor instead.
func (KeyChangeEvent_ChangeType) Number ¶
func (x KeyChangeEvent_ChangeType) Number() protoreflect.EnumNumber
func (KeyChangeEvent_ChangeType) String ¶
func (x KeyChangeEvent_ChangeType) String() string
func (KeyChangeEvent_ChangeType) Type ¶
func (KeyChangeEvent_ChangeType) Type() protoreflect.EnumType
type KeyInfo ¶
type KeyInfo struct {
Fingerprint string `protobuf:"bytes,1,opt,name=fingerprint,proto3" json:"fingerprint,omitempty"`
KeyId string `protobuf:"bytes,2,opt,name=key_id,json=keyId,proto3" json:"key_id,omitempty"`
UserIds []string `protobuf:"bytes,3,rep,name=user_ids,json=userIds,proto3" json:"user_ids,omitempty"`
CreationTime int64 `protobuf:"varint,4,opt,name=creation_time,json=creationTime,proto3" json:"creation_time,omitempty"`
ExpirationTime int64 `protobuf:"varint,5,opt,name=expiration_time,json=expirationTime,proto3" json:"expiration_time,omitempty"`
Revoked bool `protobuf:"varint,6,opt,name=revoked,proto3" json:"revoked,omitempty"`
KeyData []byte `protobuf:"bytes,7,opt,name=key_data,json=keyData,proto3" json:"key_data,omitempty"`
// contains filtered or unexported fields
}
func (*KeyInfo) Descriptor
deprecated
func (*KeyInfo) GetCreationTime ¶
func (*KeyInfo) GetExpirationTime ¶
func (*KeyInfo) GetFingerprint ¶
func (*KeyInfo) GetKeyData ¶
func (*KeyInfo) GetRevoked ¶
func (*KeyInfo) GetUserIds ¶
func (*KeyInfo) ProtoMessage ¶
func (*KeyInfo) ProtoMessage()
func (*KeyInfo) ProtoReflect ¶
func (x *KeyInfo) ProtoReflect() protoreflect.Message
type PluginHostClient ¶
type PluginHostClient interface {
// Plugins can query host for information
GetHostInfo(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*HostInfo, error)
// Plugins can request storage operations
RequestStorage(ctx context.Context, in *StorageQuery, opts ...grpc.CallOption) (*StorageResponse, error)
// Plugins can publish events to other plugins
PublishEvent(ctx context.Context, in *Event, opts ...grpc.CallOption) (*Empty, error)
// Plugins can query other plugins
QueryPlugin(ctx context.Context, in *PluginQuery, opts ...grpc.CallOption) (*PluginResponse, error)
}
PluginHostClient is the client API for PluginHost 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.
Optional: Bidirectional communication service for plugins
func NewPluginHostClient ¶
func NewPluginHostClient(cc grpc.ClientConnInterface) PluginHostClient
type PluginHostServer ¶
type PluginHostServer interface {
// Plugins can query host for information
GetHostInfo(context.Context, *Empty) (*HostInfo, error)
// Plugins can request storage operations
RequestStorage(context.Context, *StorageQuery) (*StorageResponse, error)
// Plugins can publish events to other plugins
PublishEvent(context.Context, *Event) (*Empty, error)
// Plugins can query other plugins
QueryPlugin(context.Context, *PluginQuery) (*PluginResponse, error)
// contains filtered or unexported methods
}
PluginHostServer is the server API for PluginHost service. All implementations must embed UnimplementedPluginHostServer for forward compatibility.
Optional: Bidirectional communication service for plugins
type PluginInfo ¶
type PluginInfo struct {
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
Version string `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"`
Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"`
Capabilities []string `protobuf:"bytes,4,rep,name=capabilities,proto3" json:"capabilities,omitempty"`
Metadata map[string]string `` /* 143-byte string literal not displayed */
// contains filtered or unexported fields
}
Plugin metadata and capabilities
func (*PluginInfo) Descriptor
deprecated
func (*PluginInfo) Descriptor() ([]byte, []int)
Deprecated: Use PluginInfo.ProtoReflect.Descriptor instead.
func (*PluginInfo) GetCapabilities ¶
func (x *PluginInfo) GetCapabilities() []string
func (*PluginInfo) GetDescription ¶
func (x *PluginInfo) GetDescription() string
func (*PluginInfo) GetMetadata ¶
func (x *PluginInfo) GetMetadata() map[string]string
func (*PluginInfo) GetName ¶
func (x *PluginInfo) GetName() string
func (*PluginInfo) GetVersion ¶
func (x *PluginInfo) GetVersion() string
func (*PluginInfo) ProtoMessage ¶
func (*PluginInfo) ProtoMessage()
func (*PluginInfo) ProtoReflect ¶
func (x *PluginInfo) ProtoReflect() protoreflect.Message
func (*PluginInfo) Reset ¶
func (x *PluginInfo) Reset()
func (*PluginInfo) String ¶
func (x *PluginInfo) String() string
type PluginQuery ¶
type PluginQuery struct {
TargetPlugin string `protobuf:"bytes,1,opt,name=target_plugin,json=targetPlugin,proto3" json:"target_plugin,omitempty"`
Method string `protobuf:"bytes,2,opt,name=method,proto3" json:"method,omitempty"`
Data []byte `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"` // JSON-encoded query data
// contains filtered or unexported fields
}
func (*PluginQuery) Descriptor
deprecated
func (*PluginQuery) Descriptor() ([]byte, []int)
Deprecated: Use PluginQuery.ProtoReflect.Descriptor instead.
func (*PluginQuery) GetData ¶
func (x *PluginQuery) GetData() []byte
func (*PluginQuery) GetMethod ¶
func (x *PluginQuery) GetMethod() string
func (*PluginQuery) GetTargetPlugin ¶
func (x *PluginQuery) GetTargetPlugin() string
func (*PluginQuery) ProtoMessage ¶
func (*PluginQuery) ProtoMessage()
func (*PluginQuery) ProtoReflect ¶
func (x *PluginQuery) ProtoReflect() protoreflect.Message
func (*PluginQuery) Reset ¶
func (x *PluginQuery) Reset()
func (*PluginQuery) String ¶
func (x *PluginQuery) String() string
type PluginResponse ¶
type PluginResponse struct {
Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"`
Error string `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"`
Data []byte `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"` // JSON-encoded response data
// contains filtered or unexported fields
}
func (*PluginResponse) Descriptor
deprecated
func (*PluginResponse) Descriptor() ([]byte, []int)
Deprecated: Use PluginResponse.ProtoReflect.Descriptor instead.
func (*PluginResponse) GetData ¶
func (x *PluginResponse) GetData() []byte
func (*PluginResponse) GetError ¶
func (x *PluginResponse) GetError() string
func (*PluginResponse) GetSuccess ¶
func (x *PluginResponse) GetSuccess() bool
func (*PluginResponse) ProtoMessage ¶
func (*PluginResponse) ProtoMessage()
func (*PluginResponse) ProtoReflect ¶
func (x *PluginResponse) ProtoReflect() protoreflect.Message
func (*PluginResponse) Reset ¶
func (x *PluginResponse) Reset()
func (*PluginResponse) String ¶
func (x *PluginResponse) String() string
type RateLimitCheck ¶
type RateLimitCheck struct {
Identifier string `protobuf:"bytes,1,opt,name=identifier,proto3" json:"identifier,omitempty"` // IP, key ID, etc.
Action string `protobuf:"bytes,2,opt,name=action,proto3" json:"action,omitempty"` // "lookup", "submit", etc.
Metadata map[string]string `` /* 143-byte string literal not displayed */
// contains filtered or unexported fields
}
Rate limiting
func (*RateLimitCheck) Descriptor
deprecated
func (*RateLimitCheck) Descriptor() ([]byte, []int)
Deprecated: Use RateLimitCheck.ProtoReflect.Descriptor instead.
func (*RateLimitCheck) GetAction ¶
func (x *RateLimitCheck) GetAction() string
func (*RateLimitCheck) GetIdentifier ¶
func (x *RateLimitCheck) GetIdentifier() string
func (*RateLimitCheck) GetMetadata ¶
func (x *RateLimitCheck) GetMetadata() map[string]string
func (*RateLimitCheck) ProtoMessage ¶
func (*RateLimitCheck) ProtoMessage()
func (*RateLimitCheck) ProtoReflect ¶
func (x *RateLimitCheck) ProtoReflect() protoreflect.Message
func (*RateLimitCheck) Reset ¶
func (x *RateLimitCheck) Reset()
func (*RateLimitCheck) String ¶
func (x *RateLimitCheck) String() string
type RateLimitResponse ¶
type RateLimitResponse struct {
Allowed bool `protobuf:"varint,1,opt,name=allowed,proto3" json:"allowed,omitempty"`
Reason string `protobuf:"bytes,2,opt,name=reason,proto3" json:"reason,omitempty"`
RetryAfterSeconds int32 `protobuf:"varint,3,opt,name=retry_after_seconds,json=retryAfterSeconds,proto3" json:"retry_after_seconds,omitempty"`
Headers map[string]string `` // Headers to add to HTTP response
/* 141-byte string literal not displayed */
// contains filtered or unexported fields
}
func (*RateLimitResponse) Descriptor
deprecated
func (*RateLimitResponse) Descriptor() ([]byte, []int)
Deprecated: Use RateLimitResponse.ProtoReflect.Descriptor instead.
func (*RateLimitResponse) GetAllowed ¶
func (x *RateLimitResponse) GetAllowed() bool
func (*RateLimitResponse) GetHeaders ¶
func (x *RateLimitResponse) GetHeaders() map[string]string
func (*RateLimitResponse) GetReason ¶
func (x *RateLimitResponse) GetReason() string
func (*RateLimitResponse) GetRetryAfterSeconds ¶
func (x *RateLimitResponse) GetRetryAfterSeconds() int32
func (*RateLimitResponse) ProtoMessage ¶
func (*RateLimitResponse) ProtoMessage()
func (*RateLimitResponse) ProtoReflect ¶
func (x *RateLimitResponse) ProtoReflect() protoreflect.Message
func (*RateLimitResponse) Reset ¶
func (x *RateLimitResponse) Reset()
func (*RateLimitResponse) String ¶
func (x *RateLimitResponse) String() string
type ShutdownRequest ¶
type ShutdownRequest struct {
TimeoutSeconds int32 `protobuf:"varint,1,opt,name=timeout_seconds,json=timeoutSeconds,proto3" json:"timeout_seconds,omitempty"`
Reason string `protobuf:"bytes,2,opt,name=reason,proto3" json:"reason,omitempty"`
// contains filtered or unexported fields
}
Plugin shutdown
func (*ShutdownRequest) Descriptor
deprecated
func (*ShutdownRequest) Descriptor() ([]byte, []int)
Deprecated: Use ShutdownRequest.ProtoReflect.Descriptor instead.
func (*ShutdownRequest) GetReason ¶
func (x *ShutdownRequest) GetReason() string
func (*ShutdownRequest) GetTimeoutSeconds ¶
func (x *ShutdownRequest) GetTimeoutSeconds() int32
func (*ShutdownRequest) ProtoMessage ¶
func (*ShutdownRequest) ProtoMessage()
func (*ShutdownRequest) ProtoReflect ¶
func (x *ShutdownRequest) ProtoReflect() protoreflect.Message
func (*ShutdownRequest) Reset ¶
func (x *ShutdownRequest) Reset()
func (*ShutdownRequest) String ¶
func (x *ShutdownRequest) String() string
type ShutdownResponse ¶
type ShutdownResponse struct {
Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"`
Error string `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"`
// contains filtered or unexported fields
}
func (*ShutdownResponse) Descriptor
deprecated
func (*ShutdownResponse) Descriptor() ([]byte, []int)
Deprecated: Use ShutdownResponse.ProtoReflect.Descriptor instead.
func (*ShutdownResponse) GetError ¶
func (x *ShutdownResponse) GetError() string
func (*ShutdownResponse) GetSuccess ¶
func (x *ShutdownResponse) GetSuccess() bool
func (*ShutdownResponse) ProtoMessage ¶
func (*ShutdownResponse) ProtoMessage()
func (*ShutdownResponse) ProtoReflect ¶
func (x *ShutdownResponse) ProtoReflect() protoreflect.Message
func (*ShutdownResponse) Reset ¶
func (x *ShutdownResponse) Reset()
func (*ShutdownResponse) String ¶
func (x *ShutdownResponse) String() string
type StorageQuery ¶
type StorageQuery struct {
Type StorageQuery_QueryType `protobuf:"varint,1,opt,name=type,proto3,enum=hkpplugin.StorageQuery_QueryType" json:"type,omitempty"`
Query string `protobuf:"bytes,2,opt,name=query,proto3" json:"query,omitempty"`
Options map[string]string `` /* 141-byte string literal not displayed */
Limit int32 `protobuf:"varint,4,opt,name=limit,proto3" json:"limit,omitempty"`
Offset int32 `protobuf:"varint,5,opt,name=offset,proto3" json:"offset,omitempty"`
// contains filtered or unexported fields
}
Storage queries (proxy through gRPC)
func (*StorageQuery) Descriptor
deprecated
func (*StorageQuery) Descriptor() ([]byte, []int)
Deprecated: Use StorageQuery.ProtoReflect.Descriptor instead.
func (*StorageQuery) GetLimit ¶
func (x *StorageQuery) GetLimit() int32
func (*StorageQuery) GetOffset ¶
func (x *StorageQuery) GetOffset() int32
func (*StorageQuery) GetOptions ¶
func (x *StorageQuery) GetOptions() map[string]string
func (*StorageQuery) GetQuery ¶
func (x *StorageQuery) GetQuery() string
func (*StorageQuery) GetType ¶
func (x *StorageQuery) GetType() StorageQuery_QueryType
func (*StorageQuery) ProtoMessage ¶
func (*StorageQuery) ProtoMessage()
func (*StorageQuery) ProtoReflect ¶
func (x *StorageQuery) ProtoReflect() protoreflect.Message
func (*StorageQuery) Reset ¶
func (x *StorageQuery) Reset()
func (*StorageQuery) String ¶
func (x *StorageQuery) String() string
type StorageQuery_QueryType ¶
type StorageQuery_QueryType int32
const ( StorageQuery_LOOKUP StorageQuery_QueryType = 0 StorageQuery_SEARCH StorageQuery_QueryType = 1 StorageQuery_FETCH StorageQuery_QueryType = 2 )
func (StorageQuery_QueryType) Descriptor ¶
func (StorageQuery_QueryType) Descriptor() protoreflect.EnumDescriptor
func (StorageQuery_QueryType) Enum ¶
func (x StorageQuery_QueryType) Enum() *StorageQuery_QueryType
func (StorageQuery_QueryType) EnumDescriptor
deprecated
func (StorageQuery_QueryType) EnumDescriptor() ([]byte, []int)
Deprecated: Use StorageQuery_QueryType.Descriptor instead.
func (StorageQuery_QueryType) Number ¶
func (x StorageQuery_QueryType) Number() protoreflect.EnumNumber
func (StorageQuery_QueryType) String ¶
func (x StorageQuery_QueryType) String() string
func (StorageQuery_QueryType) Type ¶
func (StorageQuery_QueryType) Type() protoreflect.EnumType
type StorageResponse ¶
type StorageResponse struct {
Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"`
Error string `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"`
Keys []*KeyInfo `protobuf:"bytes,3,rep,name=keys,proto3" json:"keys,omitempty"`
TotalCount int32 `protobuf:"varint,4,opt,name=total_count,json=totalCount,proto3" json:"total_count,omitempty"`
// contains filtered or unexported fields
}
func (*StorageResponse) Descriptor
deprecated
func (*StorageResponse) Descriptor() ([]byte, []int)
Deprecated: Use StorageResponse.ProtoReflect.Descriptor instead.
func (*StorageResponse) GetError ¶
func (x *StorageResponse) GetError() string
func (*StorageResponse) GetKeys ¶
func (x *StorageResponse) GetKeys() []*KeyInfo
func (*StorageResponse) GetSuccess ¶
func (x *StorageResponse) GetSuccess() bool
func (*StorageResponse) GetTotalCount ¶
func (x *StorageResponse) GetTotalCount() int32
func (*StorageResponse) ProtoMessage ¶
func (*StorageResponse) ProtoMessage()
func (*StorageResponse) ProtoReflect ¶
func (x *StorageResponse) ProtoReflect() protoreflect.Message
func (*StorageResponse) Reset ¶
func (x *StorageResponse) Reset()
func (*StorageResponse) String ¶
func (x *StorageResponse) String() string
type ThreatInfo ¶
type ThreatInfo struct {
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
Level ThreatInfo_ThreatLevel `protobuf:"varint,2,opt,name=level,proto3,enum=hkpplugin.ThreatInfo_ThreatLevel" json:"level,omitempty"`
Type string `protobuf:"bytes,3,opt,name=type,proto3" json:"type,omitempty"`
Description string `protobuf:"bytes,4,opt,name=description,proto3" json:"description,omitempty"`
Source string `protobuf:"bytes,5,opt,name=source,proto3" json:"source,omitempty"`
Indicators map[string]string `` /* 147-byte string literal not displayed */
Timestamp int64 `protobuf:"varint,7,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
// contains filtered or unexported fields
}
Threat detection
func (*ThreatInfo) Descriptor
deprecated
func (*ThreatInfo) Descriptor() ([]byte, []int)
Deprecated: Use ThreatInfo.ProtoReflect.Descriptor instead.
func (*ThreatInfo) GetDescription ¶
func (x *ThreatInfo) GetDescription() string
func (*ThreatInfo) GetId ¶
func (x *ThreatInfo) GetId() string
func (*ThreatInfo) GetIndicators ¶
func (x *ThreatInfo) GetIndicators() map[string]string
func (*ThreatInfo) GetLevel ¶
func (x *ThreatInfo) GetLevel() ThreatInfo_ThreatLevel
func (*ThreatInfo) GetSource ¶
func (x *ThreatInfo) GetSource() string
func (*ThreatInfo) GetTimestamp ¶
func (x *ThreatInfo) GetTimestamp() int64
func (*ThreatInfo) GetType ¶
func (x *ThreatInfo) GetType() string
func (*ThreatInfo) ProtoMessage ¶
func (*ThreatInfo) ProtoMessage()
func (*ThreatInfo) ProtoReflect ¶
func (x *ThreatInfo) ProtoReflect() protoreflect.Message
func (*ThreatInfo) Reset ¶
func (x *ThreatInfo) Reset()
func (*ThreatInfo) String ¶
func (x *ThreatInfo) String() string
type ThreatInfo_ThreatLevel ¶
type ThreatInfo_ThreatLevel int32
const ( ThreatInfo_UNKNOWN ThreatInfo_ThreatLevel = 0 ThreatInfo_LOW ThreatInfo_ThreatLevel = 1 ThreatInfo_MEDIUM ThreatInfo_ThreatLevel = 2 ThreatInfo_HIGH ThreatInfo_ThreatLevel = 3 ThreatInfo_CRITICAL ThreatInfo_ThreatLevel = 4 )
func (ThreatInfo_ThreatLevel) Descriptor ¶
func (ThreatInfo_ThreatLevel) Descriptor() protoreflect.EnumDescriptor
func (ThreatInfo_ThreatLevel) Enum ¶
func (x ThreatInfo_ThreatLevel) Enum() *ThreatInfo_ThreatLevel
func (ThreatInfo_ThreatLevel) EnumDescriptor
deprecated
func (ThreatInfo_ThreatLevel) EnumDescriptor() ([]byte, []int)
Deprecated: Use ThreatInfo_ThreatLevel.Descriptor instead.
func (ThreatInfo_ThreatLevel) Number ¶
func (x ThreatInfo_ThreatLevel) Number() protoreflect.EnumNumber
func (ThreatInfo_ThreatLevel) String ¶
func (x ThreatInfo_ThreatLevel) String() string
func (ThreatInfo_ThreatLevel) Type ¶
func (ThreatInfo_ThreatLevel) Type() protoreflect.EnumType
type UnimplementedHKPPluginServer ¶
type UnimplementedHKPPluginServer struct{}
UnimplementedHKPPluginServer must be embedded to have forward compatible implementations.
NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.
func (UnimplementedHKPPluginServer) CheckRateLimit ¶
func (UnimplementedHKPPluginServer) CheckRateLimit(context.Context, *RateLimitCheck) (*RateLimitResponse, error)
func (UnimplementedHKPPluginServer) GetInfo ¶
func (UnimplementedHKPPluginServer) GetInfo(context.Context, *Empty) (*PluginInfo, error)
func (UnimplementedHKPPluginServer) HandleHTTPRequest ¶
func (UnimplementedHKPPluginServer) HandleHTTPRequest(context.Context, *HTTPRequest) (*HTTPResponse, error)
func (UnimplementedHKPPluginServer) HandleKeyChange ¶
func (UnimplementedHKPPluginServer) HandleKeyChange(context.Context, *KeyChangeEvent) (*Event, error)
func (UnimplementedHKPPluginServer) HealthCheck ¶
func (UnimplementedHKPPluginServer) HealthCheck(context.Context, *Empty) (*HealthStatus, error)
func (UnimplementedHKPPluginServer) Initialize ¶
func (UnimplementedHKPPluginServer) Initialize(context.Context, *InitRequest) (*InitResponse, error)
func (UnimplementedHKPPluginServer) PublishEvent ¶
func (UnimplementedHKPPluginServer) QueryStorage ¶
func (UnimplementedHKPPluginServer) QueryStorage(context.Context, *StorageQuery) (*StorageResponse, error)
func (UnimplementedHKPPluginServer) ReportThreat ¶
func (UnimplementedHKPPluginServer) ReportThreat(context.Context, *ThreatInfo) (*Empty, error)
func (UnimplementedHKPPluginServer) Shutdown ¶
func (UnimplementedHKPPluginServer) Shutdown(context.Context, *ShutdownRequest) (*ShutdownResponse, error)
func (UnimplementedHKPPluginServer) SubscribeEvents ¶
func (UnimplementedHKPPluginServer) SubscribeEvents(*EventFilter, grpc.ServerStreamingServer[Event]) error
type UnimplementedPluginHostServer ¶
type UnimplementedPluginHostServer struct{}
UnimplementedPluginHostServer must be embedded to have forward compatible implementations.
NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.
func (UnimplementedPluginHostServer) GetHostInfo ¶
func (UnimplementedPluginHostServer) PublishEvent ¶
func (UnimplementedPluginHostServer) QueryPlugin ¶
func (UnimplementedPluginHostServer) QueryPlugin(context.Context, *PluginQuery) (*PluginResponse, error)
func (UnimplementedPluginHostServer) RequestStorage ¶
func (UnimplementedPluginHostServer) RequestStorage(context.Context, *StorageQuery) (*StorageResponse, error)
type UnsafeHKPPluginServer ¶
type UnsafeHKPPluginServer interface {
// contains filtered or unexported methods
}
UnsafeHKPPluginServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to HKPPluginServer will result in compilation errors.
type UnsafePluginHostServer ¶
type UnsafePluginHostServer interface {
// contains filtered or unexported methods
}
UnsafePluginHostServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to PluginHostServer will result in compilation errors.