asset.proto 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  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. syntax = "proto3";
  15. package google.cloud.securitycenter.v1beta1;
  16. import "google/api/field_behavior.proto";
  17. import "google/api/resource.proto";
  18. import "google/cloud/securitycenter/v1beta1/security_marks.proto";
  19. import "google/protobuf/struct.proto";
  20. import "google/protobuf/timestamp.proto";
  21. import "google/api/annotations.proto";
  22. option go_package = "google.golang.org/genproto/googleapis/cloud/securitycenter/v1beta1;securitycenter";
  23. option java_multiple_files = true;
  24. option java_package = "com.google.cloud.securitycenter.v1beta1";
  25. // Security Command Center representation of a Google Cloud
  26. // resource.
  27. //
  28. // The Asset is a Security Command Center resource that captures information
  29. // about a single Google Cloud resource. All modifications to an Asset are only
  30. // within the context of Security Command Center and don't affect the referenced
  31. // Google Cloud resource.
  32. message Asset {
  33. option (google.api.resource) = {
  34. type: "securitycenter.googleapis.com/Asset"
  35. pattern: "organizations/{organization}/assets/{asset}"
  36. };
  37. // Security Command Center managed properties. These properties are managed by
  38. // Security Command Center and cannot be modified by the user.
  39. message SecurityCenterProperties {
  40. // Immutable. The full resource name of the Google Cloud resource this asset
  41. // represents. This field is immutable after create time. See:
  42. // https://cloud.google.com/apis/design/resource_names#full_resource_name
  43. string resource_name = 1 [(google.api.field_behavior) = IMMUTABLE];
  44. // The type of the Google Cloud resource. Examples include: APPLICATION,
  45. // PROJECT, and ORGANIZATION. This is a case insensitive field defined by
  46. // Security Command Center and/or the producer of the resource and is
  47. // immutable after create time.
  48. string resource_type = 2;
  49. // The full resource name of the immediate parent of the resource. See:
  50. // https://cloud.google.com/apis/design/resource_names#full_resource_name
  51. string resource_parent = 3;
  52. // The full resource name of the project the resource belongs to. See:
  53. // https://cloud.google.com/apis/design/resource_names#full_resource_name
  54. string resource_project = 4;
  55. // Owners of the Google Cloud resource.
  56. repeated string resource_owners = 5;
  57. }
  58. // The relative resource name of this asset. See:
  59. // https://cloud.google.com/apis/design/resource_names#relative_resource_name
  60. // Example:
  61. // "organizations/{organization_id}/assets/{asset_id}".
  62. string name = 1;
  63. // Security Command Center managed properties. These properties are managed by
  64. // Security Command Center and cannot be modified by the user.
  65. SecurityCenterProperties security_center_properties = 2;
  66. // Resource managed properties. These properties are managed and defined by
  67. // the Google Cloud resource and cannot be modified by the user.
  68. map<string, google.protobuf.Value> resource_properties = 7;
  69. // User specified security marks. These marks are entirely managed by the user
  70. // and come from the SecurityMarks resource that belongs to the asset.
  71. SecurityMarks security_marks = 8;
  72. // The time at which the asset was created in Security Command Center.
  73. google.protobuf.Timestamp create_time = 9;
  74. // The time at which the asset was last updated, added, or deleted in Security
  75. // Command Center.
  76. google.protobuf.Timestamp update_time = 10;
  77. }