secret_event.proto 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. // Copyright 2021 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.secretmanager.logging.v1;
  16. option go_package = "google.golang.org/genproto/googleapis/cloud/secretmanager/logging/v1;logging";
  17. option java_multiple_files = true;
  18. option java_outer_classname = "SecretEventProto";
  19. option java_package = "com.google.cloud.secretmanager.logging.v1";
  20. option csharp_namespace = "Google.Cloud.SecretManager.Logging.V1";
  21. option php_namespace = "Google\\Cloud\\SecretManager\\Logging\\V1";
  22. option ruby_package = "Google::Cloud::SecretManager::Logging::V1";
  23. // Logged event relating to a specific secret
  24. message SecretEvent {
  25. // Describes the type of event that is being logged. All logs have exactly one
  26. // EventType.
  27. enum EventType {
  28. // An unrecognized event type. Should never be used.
  29. EVENT_TYPE_UNSPECIFIED = 0;
  30. // The secret is scheduled to expire in 30 days.
  31. EXPIRES_IN_30_DAYS = 1;
  32. // The secret is scheduled to expire in 7 days.
  33. EXPIRES_IN_7_DAYS = 2;
  34. // The secret is scheduled to expire in 1 day.
  35. EXPIRES_IN_1_DAY = 3;
  36. // The secret is scheduled to expire in 6 hours.
  37. EXPIRES_IN_6_HOURS = 4;
  38. // The secret is scheduled to expire in 1 hour.
  39. EXPIRES_IN_1_HOUR = 5;
  40. // The secret's expire-time has passed and it has expired.
  41. EXPIRED = 6;
  42. // A Pub/Sub topic configured on the secret could not be found.
  43. TOPIC_NOT_FOUND = 7;
  44. // A Pub/Sub topic configured on the secret does not have the needed
  45. // permissions. The Secret Manager P4SA must be granted
  46. // 'pubsub.topic.publish' permission (or 'roles/pubsub.publisher') on the
  47. // topic.
  48. TOPIC_PERMISSION_DENIED = 8;
  49. }
  50. // Resource name of the secret in the format `projects/*/secrets/*`
  51. string name = 1;
  52. // Type of event that is being logged for the secret
  53. EventType type = 2;
  54. // Human readable message describing the event
  55. string log_message = 3;
  56. }