Documentation
¶
Index ¶
- Constants
- Variables
- func RegisterKeyDashboardServiceServer(s grpc.ServiceRegistrar, srv KeyDashboardServiceServer)
- func RegisterKeyTrackingServiceServer(s grpc.ServiceRegistrar, srv KeyTrackingServiceServer)
- type FallbackScope
- func (FallbackScope) Descriptor() protoreflect.EnumDescriptor
- func (x FallbackScope) Enum() *FallbackScope
- func (FallbackScope) EnumDescriptor() ([]byte, []int)deprecated
- func (x FallbackScope) Number() protoreflect.EnumNumber
- func (x FallbackScope) String() string
- func (FallbackScope) Type() protoreflect.EnumType
- type GetProtectedResourcesSummaryRequest
- func (*GetProtectedResourcesSummaryRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetProtectedResourcesSummaryRequest) GetFallbackScope() FallbackScope
- func (x *GetProtectedResourcesSummaryRequest) GetName() string
- func (*GetProtectedResourcesSummaryRequest) ProtoMessage()
- func (x *GetProtectedResourcesSummaryRequest) ProtoReflect() protoreflect.Message
- func (x *GetProtectedResourcesSummaryRequest) Reset()
- func (x *GetProtectedResourcesSummaryRequest) String() string
- type KeyDashboardServiceClient
- type KeyDashboardServiceServer
- type KeyTrackingServiceClient
- type KeyTrackingServiceServer
- type ListCryptoKeysRequest
- func (*ListCryptoKeysRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ListCryptoKeysRequest) GetPageSize() int32
- func (x *ListCryptoKeysRequest) GetPageToken() string
- func (x *ListCryptoKeysRequest) GetParent() string
- func (*ListCryptoKeysRequest) ProtoMessage()
- func (x *ListCryptoKeysRequest) ProtoReflect() protoreflect.Message
- func (x *ListCryptoKeysRequest) Reset()
- func (x *ListCryptoKeysRequest) String() string
- type ListCryptoKeysResponse
- func (*ListCryptoKeysResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ListCryptoKeysResponse) GetCryptoKeys() []*kmspb.CryptoKey
- func (x *ListCryptoKeysResponse) GetNextPageToken() string
- func (*ListCryptoKeysResponse) ProtoMessage()
- func (x *ListCryptoKeysResponse) ProtoReflect() protoreflect.Message
- func (x *ListCryptoKeysResponse) Reset()
- func (x *ListCryptoKeysResponse) String() string
- type ProtectedResource
- func (*ProtectedResource) Descriptor() ([]byte, []int)deprecated
- func (x *ProtectedResource) GetCloudProduct() string
- func (x *ProtectedResource) GetCreateTime() *timestamppb.Timestamp
- func (x *ProtectedResource) GetCryptoKeyVersion() string
- func (x *ProtectedResource) GetCryptoKeyVersions() []string
- func (x *ProtectedResource) GetLabels() map[string]string
- func (x *ProtectedResource) GetLocation() string
- func (x *ProtectedResource) GetName() string
- func (x *ProtectedResource) GetProject() string
- func (x *ProtectedResource) GetProjectId() string
- func (x *ProtectedResource) GetResourceType() string
- func (*ProtectedResource) ProtoMessage()
- func (x *ProtectedResource) ProtoReflect() protoreflect.Message
- func (x *ProtectedResource) Reset()
- func (x *ProtectedResource) String() string
- type ProtectedResourcesSummary
- func (*ProtectedResourcesSummary) Descriptor() ([]byte, []int)deprecated
- func (x *ProtectedResourcesSummary) GetCloudProducts() map[string]int64
- func (x *ProtectedResourcesSummary) GetLocations() map[string]int64
- func (x *ProtectedResourcesSummary) GetName() string
- func (x *ProtectedResourcesSummary) GetProjectCount() int32
- func (x *ProtectedResourcesSummary) GetResourceCount() int64
- func (x *ProtectedResourcesSummary) GetResourceTypes() map[string]int64
- func (x *ProtectedResourcesSummary) GetWarnings() []*Warning
- func (*ProtectedResourcesSummary) ProtoMessage()
- func (x *ProtectedResourcesSummary) ProtoReflect() protoreflect.Message
- func (x *ProtectedResourcesSummary) Reset()
- func (x *ProtectedResourcesSummary) String() string
- type SearchProtectedResourcesRequest
- func (*SearchProtectedResourcesRequest) Descriptor() ([]byte, []int)deprecated
- func (x *SearchProtectedResourcesRequest) GetCryptoKey() string
- func (x *SearchProtectedResourcesRequest) GetPageSize() int32
- func (x *SearchProtectedResourcesRequest) GetPageToken() string
- func (x *SearchProtectedResourcesRequest) GetResourceTypes() []string
- func (x *SearchProtectedResourcesRequest) GetScope() string
- func (*SearchProtectedResourcesRequest) ProtoMessage()
- func (x *SearchProtectedResourcesRequest) ProtoReflect() protoreflect.Message
- func (x *SearchProtectedResourcesRequest) Reset()
- func (x *SearchProtectedResourcesRequest) String() string
- type SearchProtectedResourcesResponse
- func (*SearchProtectedResourcesResponse) Descriptor() ([]byte, []int)deprecated
- func (x *SearchProtectedResourcesResponse) GetNextPageToken() string
- func (x *SearchProtectedResourcesResponse) GetProtectedResources() []*ProtectedResource
- func (*SearchProtectedResourcesResponse) ProtoMessage()
- func (x *SearchProtectedResourcesResponse) ProtoReflect() protoreflect.Message
- func (x *SearchProtectedResourcesResponse) Reset()
- func (x *SearchProtectedResourcesResponse) String() string
- type UnimplementedKeyDashboardServiceServer
- type UnimplementedKeyTrackingServiceServer
- func (UnimplementedKeyTrackingServiceServer) GetProtectedResourcesSummary(context.Context, *GetProtectedResourcesSummaryRequest) (*ProtectedResourcesSummary, error)
- func (UnimplementedKeyTrackingServiceServer) SearchProtectedResources(context.Context, *SearchProtectedResourcesRequest) (*SearchProtectedResourcesResponse, error)
- type UnsafeKeyDashboardServiceServer
- type UnsafeKeyTrackingServiceServer
- type Warning
- type Warning_WarningCode
- func (Warning_WarningCode) Descriptor() protoreflect.EnumDescriptor
- func (x Warning_WarningCode) Enum() *Warning_WarningCode
- func (Warning_WarningCode) EnumDescriptor() ([]byte, []int)deprecated
- func (x Warning_WarningCode) Number() protoreflect.EnumNumber
- func (x Warning_WarningCode) String() string
- func (Warning_WarningCode) Type() protoreflect.EnumType
Constants ¶
const ( KeyTrackingService_GetProtectedResourcesSummary_FullMethodName = "/google.cloud.kms.inventory.v1.KeyTrackingService/GetProtectedResourcesSummary" KeyTrackingService_SearchProtectedResources_FullMethodName = "/google.cloud.kms.inventory.v1.KeyTrackingService/SearchProtectedResources" )
const (
KeyDashboardService_ListCryptoKeys_FullMethodName = "/google.cloud.kms.inventory.v1.KeyDashboardService/ListCryptoKeys"
)
Variables ¶
var ( FallbackScope_name = map[int32]string{ 0: "FALLBACK_SCOPE_UNSPECIFIED", 1: "FALLBACK_SCOPE_PROJECT", } FallbackScope_value = map[string]int32{ "FALLBACK_SCOPE_UNSPECIFIED": 0, "FALLBACK_SCOPE_PROJECT": 1, } )
Enum value maps for FallbackScope.
var ( Warning_WarningCode_name = map[int32]string{ 0: "WARNING_CODE_UNSPECIFIED", 1: "INSUFFICIENT_PERMISSIONS_PARTIAL_DATA", 2: "RESOURCE_LIMIT_EXCEEDED_PARTIAL_DATA", 3: "ORG_LESS_PROJECT_PARTIAL_DATA", } Warning_WarningCode_value = map[string]int32{ "WARNING_CODE_UNSPECIFIED": 0, "INSUFFICIENT_PERMISSIONS_PARTIAL_DATA": 1, "RESOURCE_LIMIT_EXCEEDED_PARTIAL_DATA": 2, "ORG_LESS_PROJECT_PARTIAL_DATA": 3, } )
Enum value maps for Warning_WarningCode.
var File_google_cloud_kms_inventory_v1_key_dashboard_service_proto protoreflect.FileDescriptor
var File_google_cloud_kms_inventory_v1_key_tracking_service_proto protoreflect.FileDescriptor
var KeyDashboardService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "google.cloud.kms.inventory.v1.KeyDashboardService", HandlerType: (*KeyDashboardServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "ListCryptoKeys", Handler: _KeyDashboardService_ListCryptoKeys_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "google/cloud/kms/inventory/v1/key_dashboard_service.proto", }
KeyDashboardService_ServiceDesc is the grpc.ServiceDesc for KeyDashboardService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var KeyTrackingService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "google.cloud.kms.inventory.v1.KeyTrackingService", HandlerType: (*KeyTrackingServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GetProtectedResourcesSummary", Handler: _KeyTrackingService_GetProtectedResourcesSummary_Handler, }, { MethodName: "SearchProtectedResources", Handler: _KeyTrackingService_SearchProtectedResources_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "google/cloud/kms/inventory/v1/key_tracking_service.proto", }
KeyTrackingService_ServiceDesc is the grpc.ServiceDesc for KeyTrackingService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterKeyDashboardServiceServer ¶
func RegisterKeyDashboardServiceServer(s grpc.ServiceRegistrar, srv KeyDashboardServiceServer)
func RegisterKeyTrackingServiceServer ¶
func RegisterKeyTrackingServiceServer(s grpc.ServiceRegistrar, srv KeyTrackingServiceServer)
Types ¶
type FallbackScope ¶ added in v1.26.0
type FallbackScope int32
Specifies the scope to use if the organization service agent is not configured.
const ( // Unspecified scope type. FallbackScope_FALLBACK_SCOPE_UNSPECIFIED FallbackScope = 0 // If set to `FALLBACK_SCOPE_PROJECT`, the API will fall back to using key's // project as request scope if the kms organization service account is not // configured. FallbackScope_FALLBACK_SCOPE_PROJECT FallbackScope = 1 )
func (FallbackScope) Descriptor ¶ added in v1.26.0
func (FallbackScope) Descriptor() protoreflect.EnumDescriptor
func (FallbackScope) Enum ¶ added in v1.26.0
func (x FallbackScope) Enum() *FallbackScope
func (FallbackScope) EnumDescriptor
deprecated
added in
v1.26.0
func (FallbackScope) EnumDescriptor() ([]byte, []int)
Deprecated: Use FallbackScope.Descriptor instead.
func (FallbackScope) Number ¶ added in v1.26.0
func (x FallbackScope) Number() protoreflect.EnumNumber
func (FallbackScope) String ¶ added in v1.26.0
func (x FallbackScope) String() string
func (FallbackScope) Type ¶ added in v1.26.0
func (FallbackScope) Type() protoreflect.EnumType
type GetProtectedResourcesSummaryRequest ¶
type GetProtectedResourcesSummaryRequest struct {
// Required. The resource name of the
// [CryptoKey][google.cloud.kms.v1.CryptoKey].
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// Optional. The scope to use if the kms organization service account is not
// configured.
FallbackScope FallbackScope `` /* 150-byte string literal not displayed */
// contains filtered or unexported fields
}
Request message for [KeyTrackingService.GetProtectedResourcesSummary][google.cloud.kms.inventory.v1.KeyTrackingService.GetProtectedResourcesSummary].
func (*GetProtectedResourcesSummaryRequest) Descriptor
deprecated
func (*GetProtectedResourcesSummaryRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetProtectedResourcesSummaryRequest.ProtoReflect.Descriptor instead.
func (*GetProtectedResourcesSummaryRequest) GetFallbackScope ¶ added in v1.26.0
func (x *GetProtectedResourcesSummaryRequest) GetFallbackScope() FallbackScope
func (*GetProtectedResourcesSummaryRequest) GetName ¶
func (x *GetProtectedResourcesSummaryRequest) GetName() string
func (*GetProtectedResourcesSummaryRequest) ProtoMessage ¶
func (*GetProtectedResourcesSummaryRequest) ProtoMessage()
func (*GetProtectedResourcesSummaryRequest) ProtoReflect ¶
func (x *GetProtectedResourcesSummaryRequest) ProtoReflect() protoreflect.Message
func (*GetProtectedResourcesSummaryRequest) Reset ¶
func (x *GetProtectedResourcesSummaryRequest) Reset()
func (*GetProtectedResourcesSummaryRequest) String ¶
func (x *GetProtectedResourcesSummaryRequest) String() string
type KeyDashboardServiceClient ¶
type KeyDashboardServiceClient interface {
// Returns cryptographic keys managed by Cloud KMS in a given Cloud project.
// Note that this data is sourced from snapshots, meaning it may not
// completely reflect the actual state of key metadata at call time.
ListCryptoKeys(ctx context.Context, in *ListCryptoKeysRequest, opts ...grpc.CallOption) (*ListCryptoKeysResponse, error)
}
KeyDashboardServiceClient is the client API for KeyDashboardService 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 NewKeyDashboardServiceClient ¶
func NewKeyDashboardServiceClient(cc grpc.ClientConnInterface) KeyDashboardServiceClient
type KeyDashboardServiceServer ¶
type KeyDashboardServiceServer interface {
// Returns cryptographic keys managed by Cloud KMS in a given Cloud project.
// Note that this data is sourced from snapshots, meaning it may not
// completely reflect the actual state of key metadata at call time.
ListCryptoKeys(context.Context, *ListCryptoKeysRequest) (*ListCryptoKeysResponse, error)
}
KeyDashboardServiceServer is the server API for KeyDashboardService service. All implementations should embed UnimplementedKeyDashboardServiceServer for forward compatibility
type KeyTrackingServiceClient ¶
type KeyTrackingServiceClient interface {
// Returns aggregate information about the resources protected by the given
// Cloud KMS [CryptoKey][google.cloud.kms.v1.CryptoKey]. By default,
// summary of resources within the same Cloud organization as the key will be
// returned, which requires the KMS organization service account to be
// configured(refer
// https://docs.cloud.google.com/kms/docs/view-key-usage#required-roles).
// If the KMS organization service account is not configured or key's project
// is not part of an organization, set
// [fallback_scope][google.cloud.kms.inventory.v1.GetProtectedResourcesSummaryRequest.fallback_scope]
// to `FALLBACK_SCOPE_PROJECT` to retrieve a summary of protected resources
// within the key's project.
GetProtectedResourcesSummary(ctx context.Context, in *GetProtectedResourcesSummaryRequest, opts ...grpc.CallOption) (*ProtectedResourcesSummary, error)
// Returns metadata about the resources protected by the given Cloud KMS
// [CryptoKey][google.cloud.kms.v1.CryptoKey] in the given Cloud
// organization/project.
SearchProtectedResources(ctx context.Context, in *SearchProtectedResourcesRequest, opts ...grpc.CallOption) (*SearchProtectedResourcesResponse, error)
}
KeyTrackingServiceClient is the client API for KeyTrackingService 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 NewKeyTrackingServiceClient ¶
func NewKeyTrackingServiceClient(cc grpc.ClientConnInterface) KeyTrackingServiceClient
type KeyTrackingServiceServer ¶
type KeyTrackingServiceServer interface {
// Returns aggregate information about the resources protected by the given
// Cloud KMS [CryptoKey][google.cloud.kms.v1.CryptoKey]. By default,
// summary of resources within the same Cloud organization as the key will be
// returned, which requires the KMS organization service account to be
// configured(refer
// https://docs.cloud.google.com/kms/docs/view-key-usage#required-roles).
// If the KMS organization service account is not configured or key's project
// is not part of an organization, set
// [fallback_scope][google.cloud.kms.inventory.v1.GetProtectedResourcesSummaryRequest.fallback_scope]
// to `FALLBACK_SCOPE_PROJECT` to retrieve a summary of protected resources
// within the key's project.
GetProtectedResourcesSummary(context.Context, *GetProtectedResourcesSummaryRequest) (*ProtectedResourcesSummary, error)
// Returns metadata about the resources protected by the given Cloud KMS
// [CryptoKey][google.cloud.kms.v1.CryptoKey] in the given Cloud
// organization/project.
SearchProtectedResources(context.Context, *SearchProtectedResourcesRequest) (*SearchProtectedResourcesResponse, error)
}
KeyTrackingServiceServer is the server API for KeyTrackingService service. All implementations should embed UnimplementedKeyTrackingServiceServer for forward compatibility
type ListCryptoKeysRequest ¶
type ListCryptoKeysRequest struct {
// Required. The Google Cloud project for which to retrieve key metadata, in
// the format `projects/*`
Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"`
// Optional. The maximum number of keys to return. The service may return
// fewer than this value. If unspecified, at most 1000 keys will be returned.
// The maximum value is 1000; values above 1000 will be coerced to 1000.
PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
// Optional. Pass this into a subsequent request in order to receive the next
// page of results.
PageToken string `protobuf:"bytes,3,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
// contains filtered or unexported fields
}
Request message for [KeyDashboardService.ListCryptoKeys][google.cloud.kms.inventory.v1.KeyDashboardService.ListCryptoKeys].
func (*ListCryptoKeysRequest) Descriptor
deprecated
func (*ListCryptoKeysRequest) Descriptor() ([]byte, []int)
Deprecated: Use ListCryptoKeysRequest.ProtoReflect.Descriptor instead.
func (*ListCryptoKeysRequest) GetPageSize ¶
func (x *ListCryptoKeysRequest) GetPageSize() int32
func (*ListCryptoKeysRequest) GetPageToken ¶
func (x *ListCryptoKeysRequest) GetPageToken() string
func (*ListCryptoKeysRequest) GetParent ¶
func (x *ListCryptoKeysRequest) GetParent() string
func (*ListCryptoKeysRequest) ProtoMessage ¶
func (*ListCryptoKeysRequest) ProtoMessage()
func (*ListCryptoKeysRequest) ProtoReflect ¶
func (x *ListCryptoKeysRequest) ProtoReflect() protoreflect.Message
func (*ListCryptoKeysRequest) Reset ¶
func (x *ListCryptoKeysRequest) Reset()
func (*ListCryptoKeysRequest) String ¶
func (x *ListCryptoKeysRequest) String() string
type ListCryptoKeysResponse ¶
type ListCryptoKeysResponse struct {
// The list of [CryptoKeys][google.cloud.kms.v1.CryptoKey].
CryptoKeys []*kmspb.CryptoKey `protobuf:"bytes,1,rep,name=crypto_keys,json=cryptoKeys,proto3" json:"crypto_keys,omitempty"`
// The page token returned from the previous response if the next page is
// desired.
NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
// contains filtered or unexported fields
}
Response message for [KeyDashboardService.ListCryptoKeys][google.cloud.kms.inventory.v1.KeyDashboardService.ListCryptoKeys].
func (*ListCryptoKeysResponse) Descriptor
deprecated
func (*ListCryptoKeysResponse) Descriptor() ([]byte, []int)
Deprecated: Use ListCryptoKeysResponse.ProtoReflect.Descriptor instead.
func (*ListCryptoKeysResponse) GetCryptoKeys ¶
func (x *ListCryptoKeysResponse) GetCryptoKeys() []*kmspb.CryptoKey
func (*ListCryptoKeysResponse) GetNextPageToken ¶
func (x *ListCryptoKeysResponse) GetNextPageToken() string
func (*ListCryptoKeysResponse) ProtoMessage ¶
func (*ListCryptoKeysResponse) ProtoMessage()
func (*ListCryptoKeysResponse) ProtoReflect ¶
func (x *ListCryptoKeysResponse) ProtoReflect() protoreflect.Message
func (*ListCryptoKeysResponse) Reset ¶
func (x *ListCryptoKeysResponse) Reset()
func (*ListCryptoKeysResponse) String ¶
func (x *ListCryptoKeysResponse) String() string
type ProtectedResource ¶
type ProtectedResource struct {
// The full resource name of the resource.
// Example:
// `//compute.googleapis.com/projects/my_project_123/zones/zone1/instances/instance1`.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// Format: `projects/{PROJECT_NUMBER}`.
Project string `protobuf:"bytes,2,opt,name=project,proto3" json:"project,omitempty"`
// The ID of the project that owns the resource.
ProjectId string `protobuf:"bytes,9,opt,name=project_id,json=projectId,proto3" json:"project_id,omitempty"`
// The Cloud product that owns the resource.
// Example: `compute`
CloudProduct string `protobuf:"bytes,8,opt,name=cloud_product,json=cloudProduct,proto3" json:"cloud_product,omitempty"`
// Example: `compute.googleapis.com/Disk`
ResourceType string `protobuf:"bytes,3,opt,name=resource_type,json=resourceType,proto3" json:"resource_type,omitempty"`
// Location can be `global`, regional like `us-east1`, or zonal like
// `us-west1-b`.
Location string `protobuf:"bytes,4,opt,name=location,proto3" json:"location,omitempty"`
// A key-value pair of the resource's labels (v1) to their values.
Labels map[string]string `` /* 139-byte string literal not displayed */
// The name of the Cloud KMS
// [CryptoKeyVersion](https://cloud.google.com/kms/docs/reference/rest/v1/projects.locations.keyRings.cryptoKeys.cryptoKeyVersions?hl=en)
// used to protect this resource via CMEK. This field is empty if the
// Google Cloud product owning the resource does not provide key version data
// to Asset Inventory. If there are multiple key versions protecting the
// resource, then this is same value as the first element of
// crypto_key_versions.
CryptoKeyVersion string `protobuf:"bytes,6,opt,name=crypto_key_version,json=cryptoKeyVersion,proto3" json:"crypto_key_version,omitempty"`
// The names of the Cloud KMS
// [CryptoKeyVersion](https://cloud.google.com/kms/docs/reference/rest/v1/projects.locations.keyRings.cryptoKeys.cryptoKeyVersions?hl=en)
// used to protect this resource via CMEK. This field is empty if the
// Google Cloud product owning the resource does not provide key versions data
// to Asset Inventory. The first element of this field is stored in
// crypto_key_version.
CryptoKeyVersions []string `protobuf:"bytes,10,rep,name=crypto_key_versions,json=cryptoKeyVersions,proto3" json:"crypto_key_versions,omitempty"`
// Output only. The time at which this resource was created. The granularity
// is in seconds. Timestamp.nanos will always be 0.
CreateTime *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"`
// contains filtered or unexported fields
}
Metadata about a resource protected by a Cloud KMS key.
func (*ProtectedResource) Descriptor
deprecated
func (*ProtectedResource) Descriptor() ([]byte, []int)
Deprecated: Use ProtectedResource.ProtoReflect.Descriptor instead.
func (*ProtectedResource) GetCloudProduct ¶
func (x *ProtectedResource) GetCloudProduct() string
func (*ProtectedResource) GetCreateTime ¶
func (x *ProtectedResource) GetCreateTime() *timestamppb.Timestamp
func (*ProtectedResource) GetCryptoKeyVersion ¶
func (x *ProtectedResource) GetCryptoKeyVersion() string
func (*ProtectedResource) GetCryptoKeyVersions ¶
func (x *ProtectedResource) GetCryptoKeyVersions() []string
func (*ProtectedResource) GetLabels ¶
func (x *ProtectedResource) GetLabels() map[string]string
func (*ProtectedResource) GetLocation ¶
func (x *ProtectedResource) GetLocation() string
func (*ProtectedResource) GetName ¶
func (x *ProtectedResource) GetName() string
func (*ProtectedResource) GetProject ¶
func (x *ProtectedResource) GetProject() string
func (*ProtectedResource) GetProjectId ¶
func (x *ProtectedResource) GetProjectId() string
func (*ProtectedResource) GetResourceType ¶
func (x *ProtectedResource) GetResourceType() string
func (*ProtectedResource) ProtoMessage ¶
func (*ProtectedResource) ProtoMessage()
func (*ProtectedResource) ProtoReflect ¶
func (x *ProtectedResource) ProtoReflect() protoreflect.Message
func (*ProtectedResource) Reset ¶
func (x *ProtectedResource) Reset()
func (*ProtectedResource) String ¶
func (x *ProtectedResource) String() string
type ProtectedResourcesSummary ¶
type ProtectedResourcesSummary struct {
// The full name of the ProtectedResourcesSummary resource.
// Example:
// projects/test-project/locations/us/keyRings/test-keyring/cryptoKeys/test-key/protectedResourcesSummary
Name string `protobuf:"bytes,5,opt,name=name,proto3" json:"name,omitempty"`
// The total number of protected resources in the same Cloud organization as
// the key.
ResourceCount int64 `protobuf:"varint,1,opt,name=resource_count,json=resourceCount,proto3" json:"resource_count,omitempty"`
// The number of distinct Cloud projects in the same Cloud organization as the
// key that have resources protected by the key.
ProjectCount int32 `protobuf:"varint,2,opt,name=project_count,json=projectCount,proto3" json:"project_count,omitempty"`
// The number of resources protected by the key grouped by resource type.
ResourceTypes map[string]int64 `` /* 175-byte string literal not displayed */
// The number of resources protected by the key grouped by Cloud product.
CloudProducts map[string]int64 `` /* 175-byte string literal not displayed */
// The number of resources protected by the key grouped by region.
Locations map[string]int64 `` /* 146-byte string literal not displayed */
// Warning messages for the state of response
// [ProtectedResourcesSummary][google.cloud.kms.inventory.v1.ProtectedResourcesSummary]
// For example, if the organization service account is not configured,
// INSUFFICIENT_PERMISSIONS_PARTIAL_DATA warning will be returned.
Warnings []*Warning `protobuf:"bytes,7,rep,name=warnings,proto3" json:"warnings,omitempty"`
// contains filtered or unexported fields
}
Aggregate information about the resources protected by a Cloud KMS key in the same Cloud organization/project as the key.
func (*ProtectedResourcesSummary) Descriptor
deprecated
func (*ProtectedResourcesSummary) Descriptor() ([]byte, []int)
Deprecated: Use ProtectedResourcesSummary.ProtoReflect.Descriptor instead.
func (*ProtectedResourcesSummary) GetCloudProducts ¶
func (x *ProtectedResourcesSummary) GetCloudProducts() map[string]int64
func (*ProtectedResourcesSummary) GetLocations ¶
func (x *ProtectedResourcesSummary) GetLocations() map[string]int64
func (*ProtectedResourcesSummary) GetName ¶
func (x *ProtectedResourcesSummary) GetName() string
func (*ProtectedResourcesSummary) GetProjectCount ¶
func (x *ProtectedResourcesSummary) GetProjectCount() int32
func (*ProtectedResourcesSummary) GetResourceCount ¶
func (x *ProtectedResourcesSummary) GetResourceCount() int64
func (*ProtectedResourcesSummary) GetResourceTypes ¶
func (x *ProtectedResourcesSummary) GetResourceTypes() map[string]int64
func (*ProtectedResourcesSummary) GetWarnings ¶ added in v1.26.0
func (x *ProtectedResourcesSummary) GetWarnings() []*Warning
func (*ProtectedResourcesSummary) ProtoMessage ¶
func (*ProtectedResourcesSummary) ProtoMessage()
func (*ProtectedResourcesSummary) ProtoReflect ¶
func (x *ProtectedResourcesSummary) ProtoReflect() protoreflect.Message
func (*ProtectedResourcesSummary) Reset ¶
func (x *ProtectedResourcesSummary) Reset()
func (*ProtectedResourcesSummary) String ¶
func (x *ProtectedResourcesSummary) String() string
type SearchProtectedResourcesRequest ¶
type SearchProtectedResourcesRequest struct {
// Required. A scope can be an organization or a project. Resources protected
// by the crypto key in provided scope will be returned.
//
// The following values are allowed:
//
// * organizations/{ORGANIZATION_NUMBER} (e.g., "organizations/12345678")
// * projects/{PROJECT_ID} (e.g., "projects/foo-bar")
// * projects/{PROJECT_NUMBER} (e.g., "projects/12345678")
Scope string `protobuf:"bytes,2,opt,name=scope,proto3" json:"scope,omitempty"`
// Required. The resource name of the
// [CryptoKey][google.cloud.kms.v1.CryptoKey].
CryptoKey string `protobuf:"bytes,1,opt,name=crypto_key,json=cryptoKey,proto3" json:"crypto_key,omitempty"`
// The maximum number of resources to return. The service may return fewer
// than this value.
// If unspecified, at most 500 resources will be returned.
// The maximum value is 500; values above 500 will be coerced to 500.
PageSize int32 `protobuf:"varint,3,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
// A page token, received from a previous
// [KeyTrackingService.SearchProtectedResources][google.cloud.kms.inventory.v1.KeyTrackingService.SearchProtectedResources]
// call. Provide this to retrieve the subsequent page.
//
// When paginating, all other parameters provided to
// [KeyTrackingService.SearchProtectedResources][google.cloud.kms.inventory.v1.KeyTrackingService.SearchProtectedResources]
// must match the call that provided the page token.
PageToken string `protobuf:"bytes,4,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
// Optional. A list of resource types that this request searches for. If
// empty, it will search all the [trackable resource
// types](https://cloud.google.com/kms/docs/view-key-usage#tracked-resource-types).
//
// Regular expressions are also supported. For example:
//
// * `compute.googleapis.com.*` snapshots resources whose type starts
// with `compute.googleapis.com`.
// * `.*Image` snapshots resources whose type ends with `Image`.
// * `.*Image.*` snapshots resources whose type contains `Image`.
//
// See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported
// regular expression syntax. If the regular expression does not match any
// supported resource type, an INVALID_ARGUMENT error will be returned.
ResourceTypes []string `protobuf:"bytes,5,rep,name=resource_types,json=resourceTypes,proto3" json:"resource_types,omitempty"`
// contains filtered or unexported fields
}
Request message for [KeyTrackingService.SearchProtectedResources][google.cloud.kms.inventory.v1.KeyTrackingService.SearchProtectedResources].
func (*SearchProtectedResourcesRequest) Descriptor
deprecated
func (*SearchProtectedResourcesRequest) Descriptor() ([]byte, []int)
Deprecated: Use SearchProtectedResourcesRequest.ProtoReflect.Descriptor instead.
func (*SearchProtectedResourcesRequest) GetCryptoKey ¶
func (x *SearchProtectedResourcesRequest) GetCryptoKey() string
func (*SearchProtectedResourcesRequest) GetPageSize ¶
func (x *SearchProtectedResourcesRequest) GetPageSize() int32
func (*SearchProtectedResourcesRequest) GetPageToken ¶
func (x *SearchProtectedResourcesRequest) GetPageToken() string
func (*SearchProtectedResourcesRequest) GetResourceTypes ¶ added in v1.14.0
func (x *SearchProtectedResourcesRequest) GetResourceTypes() []string
func (*SearchProtectedResourcesRequest) GetScope ¶
func (x *SearchProtectedResourcesRequest) GetScope() string
func (*SearchProtectedResourcesRequest) ProtoMessage ¶
func (*SearchProtectedResourcesRequest) ProtoMessage()
func (*SearchProtectedResourcesRequest) ProtoReflect ¶
func (x *SearchProtectedResourcesRequest) ProtoReflect() protoreflect.Message
func (*SearchProtectedResourcesRequest) Reset ¶
func (x *SearchProtectedResourcesRequest) Reset()
func (*SearchProtectedResourcesRequest) String ¶
func (x *SearchProtectedResourcesRequest) String() string
type SearchProtectedResourcesResponse ¶
type SearchProtectedResourcesResponse struct {
// Protected resources for this page.
ProtectedResources []*ProtectedResource `protobuf:"bytes,1,rep,name=protected_resources,json=protectedResources,proto3" json:"protected_resources,omitempty"`
// A token that can be sent as `page_token` to retrieve the next page.
// If this field is omitted, there are no subsequent pages.
NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
// contains filtered or unexported fields
}
Response message for [KeyTrackingService.SearchProtectedResources][google.cloud.kms.inventory.v1.KeyTrackingService.SearchProtectedResources].
func (*SearchProtectedResourcesResponse) Descriptor
deprecated
func (*SearchProtectedResourcesResponse) Descriptor() ([]byte, []int)
Deprecated: Use SearchProtectedResourcesResponse.ProtoReflect.Descriptor instead.
func (*SearchProtectedResourcesResponse) GetNextPageToken ¶
func (x *SearchProtectedResourcesResponse) GetNextPageToken() string
func (*SearchProtectedResourcesResponse) GetProtectedResources ¶
func (x *SearchProtectedResourcesResponse) GetProtectedResources() []*ProtectedResource
func (*SearchProtectedResourcesResponse) ProtoMessage ¶
func (*SearchProtectedResourcesResponse) ProtoMessage()
func (*SearchProtectedResourcesResponse) ProtoReflect ¶
func (x *SearchProtectedResourcesResponse) ProtoReflect() protoreflect.Message
func (*SearchProtectedResourcesResponse) Reset ¶
func (x *SearchProtectedResourcesResponse) Reset()
func (*SearchProtectedResourcesResponse) String ¶
func (x *SearchProtectedResourcesResponse) String() string
type UnimplementedKeyDashboardServiceServer ¶
type UnimplementedKeyDashboardServiceServer struct {
}
UnimplementedKeyDashboardServiceServer should be embedded to have forward compatible implementations.
func (UnimplementedKeyDashboardServiceServer) ListCryptoKeys ¶
func (UnimplementedKeyDashboardServiceServer) ListCryptoKeys(context.Context, *ListCryptoKeysRequest) (*ListCryptoKeysResponse, error)
type UnimplementedKeyTrackingServiceServer ¶
type UnimplementedKeyTrackingServiceServer struct {
}
UnimplementedKeyTrackingServiceServer should be embedded to have forward compatible implementations.
func (UnimplementedKeyTrackingServiceServer) GetProtectedResourcesSummary ¶
func (UnimplementedKeyTrackingServiceServer) GetProtectedResourcesSummary(context.Context, *GetProtectedResourcesSummaryRequest) (*ProtectedResourcesSummary, error)
func (UnimplementedKeyTrackingServiceServer) SearchProtectedResources ¶
func (UnimplementedKeyTrackingServiceServer) SearchProtectedResources(context.Context, *SearchProtectedResourcesRequest) (*SearchProtectedResourcesResponse, error)
type UnsafeKeyDashboardServiceServer ¶ added in v1.23.1
type UnsafeKeyDashboardServiceServer interface {
// contains filtered or unexported methods
}
UnsafeKeyDashboardServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to KeyDashboardServiceServer will result in compilation errors.
type UnsafeKeyTrackingServiceServer ¶ added in v1.23.1
type UnsafeKeyTrackingServiceServer interface {
// contains filtered or unexported methods
}
UnsafeKeyTrackingServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to KeyTrackingServiceServer will result in compilation errors.
type Warning ¶ added in v1.26.0
type Warning struct {
// The specific warning code for the displayed message.
WarningCode Warning_WarningCode `` /* 150-byte string literal not displayed */
// The literal message providing context and details about the warnings.
DisplayMessage string `protobuf:"bytes,2,opt,name=display_message,json=displayMessage,proto3" json:"display_message,omitempty"`
// contains filtered or unexported fields
}
A warning message that indicates potential problems with the response data.
func (*Warning) Descriptor
deprecated
added in
v1.26.0
func (*Warning) GetDisplayMessage ¶ added in v1.26.0
func (*Warning) GetWarningCode ¶ added in v1.26.0
func (x *Warning) GetWarningCode() Warning_WarningCode
func (*Warning) ProtoMessage ¶ added in v1.26.0
func (*Warning) ProtoMessage()
func (*Warning) ProtoReflect ¶ added in v1.26.0
func (x *Warning) ProtoReflect() protoreflect.Message
type Warning_WarningCode ¶ added in v1.26.0
type Warning_WarningCode int32
Different types of warnings that can be returned to the user. The display_message contains detailed information regarding the warning_code.
const ( // Default value. This value is unused. Warning_WARNING_CODE_UNSPECIFIED Warning_WarningCode = 0 // Indicates that the caller or service agent lacks necessary permissions // to view some of the requested data. The response may be partial. // Example: // - KMS organization service agent {service_agent_name} lacks the // `cloudasset.assets.searchAllResources` permission on the scope. Warning_INSUFFICIENT_PERMISSIONS_PARTIAL_DATA Warning_WarningCode = 1 // Indicates that a resource limit has been exceeded, resulting in partial // data. Example: // - The project has more than 10,000 assets (resources, // crypto keys, key handles, IAM policies, etc). Warning_RESOURCE_LIMIT_EXCEEDED_PARTIAL_DATA Warning_WarningCode = 2 // Indicates that the project exists outside of an organization resource. // Thus the analysis is only done for the project level data and results // might be partial. Warning_ORG_LESS_PROJECT_PARTIAL_DATA Warning_WarningCode = 3 )
func (Warning_WarningCode) Descriptor ¶ added in v1.26.0
func (Warning_WarningCode) Descriptor() protoreflect.EnumDescriptor
func (Warning_WarningCode) Enum ¶ added in v1.26.0
func (x Warning_WarningCode) Enum() *Warning_WarningCode
func (Warning_WarningCode) EnumDescriptor
deprecated
added in
v1.26.0
func (Warning_WarningCode) EnumDescriptor() ([]byte, []int)
Deprecated: Use Warning_WarningCode.Descriptor instead.
func (Warning_WarningCode) Number ¶ added in v1.26.0
func (x Warning_WarningCode) Number() protoreflect.EnumNumber
func (Warning_WarningCode) String ¶ added in v1.26.0
func (x Warning_WarningCode) String() string
func (Warning_WarningCode) Type ¶ added in v1.26.0
func (Warning_WarningCode) Type() protoreflect.EnumType