Documentation ¶
Index ¶
- Variables
- func RegisterEvidenceStoreServer(s grpc.ServiceRegistrar, srv EvidenceStoreServer)
- type Evidence
- func (*Evidence) Descriptor() ([]byte, []int)deprecated
- func (x *Evidence) GetApplicableMetrics() []int32
- func (x *Evidence) GetId() string
- func (x *Evidence) GetRaw() string
- func (x *Evidence) GetResource() *structpb.Value
- func (x *Evidence) GetResourceId() string
- func (x *Evidence) GetServiceId() string
- func (x *Evidence) GetTimestamp() *timestamppb.Timestamp
- func (*Evidence) ProtoMessage()
- func (x *Evidence) ProtoReflect() protoreflect.Message
- func (x *Evidence) Reset()
- func (x *Evidence) String() string
- type EvidenceStoreClient
- type EvidenceStoreServer
- type EvidenceStore_StoreEvidencesClient
- type EvidenceStore_StoreEvidencesServer
- type ListEvidencesRequest
- type ListEvidencesResponse
- func (*ListEvidencesResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ListEvidencesResponse) GetEvidences() []*Evidence
- func (*ListEvidencesResponse) ProtoMessage()
- func (x *ListEvidencesResponse) ProtoReflect() protoreflect.Message
- func (x *ListEvidencesResponse) Reset()
- func (x *ListEvidencesResponse) String() string
- type StoreEvidenceResponse
- func (*StoreEvidenceResponse) Descriptor() ([]byte, []int)deprecated
- func (x *StoreEvidenceResponse) GetStatus() bool
- func (*StoreEvidenceResponse) ProtoMessage()
- func (x *StoreEvidenceResponse) ProtoReflect() protoreflect.Message
- func (x *StoreEvidenceResponse) Reset()
- func (x *StoreEvidenceResponse) String() string
- type UnimplementedEvidenceStoreServer
- func (UnimplementedEvidenceStoreServer) ListEvidences(context.Context, *ListEvidencesRequest) (*ListEvidencesResponse, error)
- func (UnimplementedEvidenceStoreServer) StoreEvidence(context.Context, *Evidence) (*StoreEvidenceResponse, error)
- func (UnimplementedEvidenceStoreServer) StoreEvidences(EvidenceStore_StoreEvidencesServer) error
- type UnsafeEvidenceStoreServer
Constants ¶
This section is empty.
Variables ¶
var EvidenceStore_ServiceDesc = grpc.ServiceDesc{ ServiceName: "clouditor.EvidenceStore", HandlerType: (*EvidenceStoreServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "StoreEvidence", Handler: _EvidenceStore_StoreEvidence_Handler, }, { MethodName: "ListEvidences", Handler: _EvidenceStore_ListEvidences_Handler, }, }, Streams: []grpc.StreamDesc{ { StreamName: "StoreEvidences", Handler: _EvidenceStore_StoreEvidences_Handler, ClientStreams: true, }, }, Metadata: "evidence_store.proto", }
EvidenceStore_ServiceDesc is the grpc.ServiceDesc for EvidenceStore service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_evidence_proto protoreflect.FileDescriptor
var File_evidence_store_proto protoreflect.FileDescriptor
Functions ¶
func RegisterEvidenceStoreServer ¶
func RegisterEvidenceStoreServer(s grpc.ServiceRegistrar, srv EvidenceStoreServer)
Types ¶
type Evidence ¶
type Evidence struct { // the ID in a uuid format Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // reference to a service this evidence was gathered from ServiceId string `protobuf:"bytes,2,opt,name=service_id,json=serviceId,proto3" json:"service_id,omitempty"` // reference to the resource this evidence was gathered from ResourceId string `protobuf:"bytes,3,opt,name=resource_id,json=resourceId,proto3" json:"resource_id,omitempty"` // TODO: replace with google/type/date.proto timestamp.proto or date.proto? Timestamp *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=timestamp,proto3" json:"timestamp,omitempty"` ApplicableMetrics []int32 `protobuf:"varint,5,rep,packed,name=applicable_metrics,json=applicableMetrics,proto3" json:"applicable_metrics,omitempty"` // "raw" evidence (for the auditor), for example the raw JSON response from // the API. This does not follow a defined schema Raw string `protobuf:"bytes,6,opt,name=raw,proto3" json:"raw,omitempty"` // optional; a semantic representation of the Cloud resource according to our // defined ontology. a JSON serialized node of our semantic graph. This may be // Clouditor-specific. Resource *structpb.Value `protobuf:"bytes,7,opt,name=resource,proto3" json:"resource,omitempty"` // contains filtered or unexported fields }
An evidence resource
func (*Evidence) Descriptor
deprecated
func (*Evidence) GetApplicableMetrics ¶
func (*Evidence) GetResource ¶
func (*Evidence) GetResourceId ¶
func (*Evidence) GetServiceId ¶
func (*Evidence) GetTimestamp ¶
func (x *Evidence) GetTimestamp() *timestamppb.Timestamp
func (*Evidence) ProtoMessage ¶
func (*Evidence) ProtoMessage()
func (*Evidence) ProtoReflect ¶
func (x *Evidence) ProtoReflect() protoreflect.Message
type EvidenceStoreClient ¶
type EvidenceStoreClient interface { // Stores an evidence to the evidence storage StoreEvidence(ctx context.Context, in *Evidence, opts ...grpc.CallOption) (*StoreEvidenceResponse, error) // Stores a stream of evidences to the evidence storage StoreEvidences(ctx context.Context, opts ...grpc.CallOption) (EvidenceStore_StoreEvidencesClient, error) // Returns the evidences lying in the evidence storage ListEvidences(ctx context.Context, in *ListEvidencesRequest, opts ...grpc.CallOption) (*ListEvidencesResponse, error) }
EvidenceStoreClient is the client API for EvidenceStore 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 NewEvidenceStoreClient ¶
func NewEvidenceStoreClient(cc grpc.ClientConnInterface) EvidenceStoreClient
type EvidenceStoreServer ¶
type EvidenceStoreServer interface { // Stores an evidence to the evidence storage StoreEvidence(context.Context, *Evidence) (*StoreEvidenceResponse, error) // Stores a stream of evidences to the evidence storage StoreEvidences(EvidenceStore_StoreEvidencesServer) error // Returns the evidences lying in the evidence storage ListEvidences(context.Context, *ListEvidencesRequest) (*ListEvidencesResponse, error) // contains filtered or unexported methods }
EvidenceStoreServer is the server API for EvidenceStore service. All implementations must embed UnimplementedEvidenceStoreServer for forward compatibility
type ListEvidencesRequest ¶
type ListEvidencesRequest struct {
// contains filtered or unexported fields
}
func (*ListEvidencesRequest) Descriptor
deprecated
func (*ListEvidencesRequest) Descriptor() ([]byte, []int)
Deprecated: Use ListEvidencesRequest.ProtoReflect.Descriptor instead.
func (*ListEvidencesRequest) ProtoMessage ¶
func (*ListEvidencesRequest) ProtoMessage()
func (*ListEvidencesRequest) ProtoReflect ¶
func (x *ListEvidencesRequest) ProtoReflect() protoreflect.Message
func (*ListEvidencesRequest) Reset ¶
func (x *ListEvidencesRequest) Reset()
func (*ListEvidencesRequest) String ¶
func (x *ListEvidencesRequest) String() string
type ListEvidencesResponse ¶
type ListEvidencesResponse struct { Evidences []*Evidence `protobuf:"bytes,1,rep,name=evidences,proto3" json:"evidences,omitempty"` // contains filtered or unexported fields }
func (*ListEvidencesResponse) Descriptor
deprecated
func (*ListEvidencesResponse) Descriptor() ([]byte, []int)
Deprecated: Use ListEvidencesResponse.ProtoReflect.Descriptor instead.
func (*ListEvidencesResponse) GetEvidences ¶
func (x *ListEvidencesResponse) GetEvidences() []*Evidence
func (*ListEvidencesResponse) ProtoMessage ¶
func (*ListEvidencesResponse) ProtoMessage()
func (*ListEvidencesResponse) ProtoReflect ¶
func (x *ListEvidencesResponse) ProtoReflect() protoreflect.Message
func (*ListEvidencesResponse) Reset ¶
func (x *ListEvidencesResponse) Reset()
func (*ListEvidencesResponse) String ¶
func (x *ListEvidencesResponse) String() string
type StoreEvidenceResponse ¶
type StoreEvidenceResponse struct { Status bool `protobuf:"varint,1,opt,name=status,proto3" json:"status,omitempty"` // contains filtered or unexported fields }
func (*StoreEvidenceResponse) Descriptor
deprecated
func (*StoreEvidenceResponse) Descriptor() ([]byte, []int)
Deprecated: Use StoreEvidenceResponse.ProtoReflect.Descriptor instead.
func (*StoreEvidenceResponse) GetStatus ¶
func (x *StoreEvidenceResponse) GetStatus() bool
func (*StoreEvidenceResponse) ProtoMessage ¶
func (*StoreEvidenceResponse) ProtoMessage()
func (*StoreEvidenceResponse) ProtoReflect ¶
func (x *StoreEvidenceResponse) ProtoReflect() protoreflect.Message
func (*StoreEvidenceResponse) Reset ¶
func (x *StoreEvidenceResponse) Reset()
func (*StoreEvidenceResponse) String ¶
func (x *StoreEvidenceResponse) String() string
type UnimplementedEvidenceStoreServer ¶
type UnimplementedEvidenceStoreServer struct { }
UnimplementedEvidenceStoreServer must be embedded to have forward compatible implementations.
func (UnimplementedEvidenceStoreServer) ListEvidences ¶
func (UnimplementedEvidenceStoreServer) ListEvidences(context.Context, *ListEvidencesRequest) (*ListEvidencesResponse, error)
func (UnimplementedEvidenceStoreServer) StoreEvidence ¶
func (UnimplementedEvidenceStoreServer) StoreEvidence(context.Context, *Evidence) (*StoreEvidenceResponse, error)
func (UnimplementedEvidenceStoreServer) StoreEvidences ¶
func (UnimplementedEvidenceStoreServer) StoreEvidences(EvidenceStore_StoreEvidencesServer) error
type UnsafeEvidenceStoreServer ¶
type UnsafeEvidenceStoreServer interface {
// contains filtered or unexported methods
}
UnsafeEvidenceStoreServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to EvidenceStoreServer will result in compilation errors.