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