access.proto 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. // Copyright 2022 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.v1;
  16. option csharp_namespace = "Google.Cloud.SecurityCenter.V1";
  17. option go_package = "google.golang.org/genproto/googleapis/cloud/securitycenter/v1;securitycenter";
  18. option java_multiple_files = true;
  19. option java_outer_classname = "AccessProto";
  20. option java_package = "com.google.cloud.securitycenter.v1";
  21. option php_namespace = "Google\\Cloud\\SecurityCenter\\V1";
  22. option ruby_package = "Google::Cloud::SecurityCenter::V1";
  23. // Represents an access event.
  24. message Access {
  25. // Associated email, such as "foo@google.com".
  26. //
  27. // The email address of the authenticated user (or service account on behalf
  28. // of third party principal) making the request. For third party identity
  29. // callers, the `principal_subject` field is populated instead of this field.
  30. // For privacy reasons, the principal email address is sometimes redacted.
  31. // For more information, see [Caller identities in audit
  32. // logs](https://cloud.google.com/logging/docs/audit#user-id).
  33. string principal_email = 1;
  34. // Caller's IP address, such as "1.1.1.1".
  35. string caller_ip = 2;
  36. // The caller IP's geolocation, which identifies where the call came from.
  37. Geolocation caller_ip_geo = 3;
  38. // What kind of user agent is associated, e.g. operating system shells,
  39. // embedded or stand-alone applications, etc.
  40. string user_agent_family = 4;
  41. // This is the API service that the service account made a call to, e.g.
  42. // "iam.googleapis.com"
  43. string service_name = 5;
  44. // The method that the service account called, e.g. "SetIamPolicy".
  45. string method_name = 6;
  46. // A string representing the principal_subject associated with the identity.
  47. // As compared to `principal_email`, supports principals that aren't
  48. // associated with email addresses, such as third party principals. For most
  49. // identities, the format will be `principal://iam.googleapis.com/{identity
  50. // pool name}/subjects/{subject}` except for some GKE identities
  51. // (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy
  52. // format `serviceAccount:{identity pool name}[{subject}]`
  53. string principal_subject = 7;
  54. // The name of the service account key used to create or exchange
  55. // credentials for authenticating the service account making the request.
  56. // This is a scheme-less URI full resource name. For example:
  57. //
  58. // "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}"
  59. //
  60. string service_account_key_name = 8;
  61. // Identity delegation history of an authenticated service account that makes
  62. // the request. It contains information on the real authorities that try to
  63. // access GCP resources by delegating on a service account. When multiple
  64. // authorities are present, they are guaranteed to be sorted based on the
  65. // original ordering of the identity delegation events.
  66. repeated ServiceAccountDelegationInfo service_account_delegation_info = 9;
  67. }
  68. // Identity delegation history of an authenticated service account.
  69. message ServiceAccountDelegationInfo {
  70. // The email address of a Google account.
  71. string principal_email = 1;
  72. // A string representing the principal_subject associated with the identity.
  73. // As compared to `principal_email`, supports principals that aren't
  74. // associated with email addresses, such as third party principals. For most
  75. // identities, the format will be `principal://iam.googleapis.com/{identity
  76. // pool name}/subjects/{subject}` except for some GKE identities
  77. // (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy
  78. // format `serviceAccount:{identity pool name}[{subject}]`
  79. string principal_subject = 2;
  80. }
  81. // Represents a geographical location for a given access.
  82. message Geolocation {
  83. // A CLDR.
  84. string region_code = 1;
  85. }