1// Copyright 2020 Google LLC 2// 3// Licensed under the Apache License, Version 2.0 (the "License"); 4// you may not use this file except in compliance with the License. 5// You may obtain a copy of the License at 6// 7// http://www.apache.org/licenses/LICENSE-2.0 8// 9// Unless required by applicable law or agreed to in writing, software 10// distributed under the License is distributed on an "AS IS" BASIS, 11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12// See the License for the specific language governing permissions and 13// limitations under the License. 14 15syntax = "proto3"; 16 17package google.cloud.securitycenter.v1beta1; 18 19import "google/api/field_behavior.proto"; 20import "google/api/resource.proto"; 21import "google/cloud/securitycenter/v1beta1/security_marks.proto"; 22import "google/protobuf/struct.proto"; 23import "google/protobuf/timestamp.proto"; 24 25option go_package = "cloud.google.com/go/securitycenter/apiv1beta1/securitycenterpb;securitycenterpb"; 26option java_multiple_files = true; 27option java_package = "com.google.cloud.securitycenter.v1beta1"; 28 29// Security Command Center representation of a Google Cloud 30// resource. 31// 32// The Asset is a Security Command Center resource that captures information 33// about a single Google Cloud resource. All modifications to an Asset are only 34// within the context of Security Command Center and don't affect the referenced 35// Google Cloud resource. 36message Asset { 37 option (google.api.resource) = { 38 type: "securitycenter.googleapis.com/Asset" 39 pattern: "organizations/{organization}/assets/{asset}" 40 }; 41 42 // Security Command Center managed properties. These properties are managed by 43 // Security Command Center and cannot be modified by the user. 44 message SecurityCenterProperties { 45 // Immutable. The full resource name of the Google Cloud resource this asset 46 // represents. This field is immutable after create time. See: 47 // https://cloud.google.com/apis/design/resource_names#full_resource_name 48 string resource_name = 1 [(google.api.field_behavior) = IMMUTABLE]; 49 50 // The type of the Google Cloud resource. Examples include: APPLICATION, 51 // PROJECT, and ORGANIZATION. This is a case insensitive field defined by 52 // Security Command Center and/or the producer of the resource and is 53 // immutable after create time. 54 string resource_type = 2; 55 56 // The full resource name of the immediate parent of the resource. See: 57 // https://cloud.google.com/apis/design/resource_names#full_resource_name 58 string resource_parent = 3; 59 60 // The full resource name of the project the resource belongs to. See: 61 // https://cloud.google.com/apis/design/resource_names#full_resource_name 62 string resource_project = 4; 63 64 // Owners of the Google Cloud resource. 65 repeated string resource_owners = 5; 66 } 67 68 // The relative resource name of this asset. See: 69 // https://cloud.google.com/apis/design/resource_names#relative_resource_name 70 // Example: 71 // "organizations/{organization_id}/assets/{asset_id}". 72 string name = 1; 73 74 // Security Command Center managed properties. These properties are managed by 75 // Security Command Center and cannot be modified by the user. 76 SecurityCenterProperties security_center_properties = 2; 77 78 // Resource managed properties. These properties are managed and defined by 79 // the Google Cloud resource and cannot be modified by the user. 80 map<string, google.protobuf.Value> resource_properties = 7; 81 82 // User specified security marks. These marks are entirely managed by the user 83 // and come from the SecurityMarks resource that belongs to the asset. 84 SecurityMarks security_marks = 8; 85 86 // The time at which the asset was created in Security Command Center. 87 google.protobuf.Timestamp create_time = 9; 88 89 // The time at which the asset was last updated, added, or deleted in Security 90 // Command Center. 91 google.protobuf.Timestamp update_time = 10; 92} 93