1/* 2 * Copyright (C) 2023 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17syntax = "proto2"; 18 19package android.os.statsd.ike; 20 21import "frameworks/proto_logging/stats/atoms.proto"; 22import "frameworks/proto_logging/stats/atom_field_options.proto"; 23import "frameworks/proto_logging/stats/enums/stats/ike/ike.proto"; 24 25option java_package = "com.android.os.ike"; 26option java_multiple_files = true; 27 28extend Atom { 29 optional IkeSessionTerminated ike_session_terminated = 678 [(module) = "ike"]; 30 optional IkeLivenessCheckSessionValidated ike_liveness_check_session_validated = 31 760 [(module) = "ike"]; 32 optional NegotiatedSecurityAssociation negotiated_security_association = 33 821 [(module) = "ike"]; 34} 35 36/** 37 * Log that the session is terminated 38 */ 39message IkeSessionTerminated { 40 // Indicates the client of the IKE library 41 optional android.stats.ike.IkeCaller ike_caller = 1; 42 43 // Indicates whether the termination is on an IKE Session or a Child Session. 44 // If the Child Session is terminated due to IKE Session closure, no atom 45 // will be generated 46 optional android.stats.ike.SessionType session_type = 2; 47 48 // Represents the state when the session is terminated 49 optional android.stats.ike.IkeState ike_state = 3; 50 51 // Indicates the error that causes the session termination or ERROR_NONE if 52 // no error has occurred 53 optional android.stats.ike.IkeError ike_error = 4; 54} 55 56message IkeLivenessCheckSessionValidated { 57 58 // Identity of system callers. 59 optional android.stats.ike.IkeCaller ike_caller = 1; 60 61 // To determine task at which liveness check was initiated. 62 // Deprecated: use IkeState instead to use more precise IKE state 63 optional android.stats.ike.IkeTask ike_task = 2 [deprecated = true]; 64 65 // Underlying network type that checked the Liveness. 66 optional android.stats.ike.IkeUnderlyingNetworkType ike_underlying_network_type = 3; 67 68 // Elapsed time in milliseconds from Started to end of liveness check 69 // (From Started to Success or Failure) 70 optional int32 elapsed_time_in_millis = 4; 71 72 // Number of times client invoked liveness check api during ongoing task. 73 optional int32 number_of_on_going_status = 5; 74 75 // True if the Liveness check is successful. False if the Liveness check is failed. 76 optional bool result_success = 6; 77 78 // To determine the state at which liveness check was initiated. 79 optional android.stats.ike.IkeState ike_state = 7; 80} 81 82/** 83 * Log that the IKE or Child session SA negotiated or failed 84 */ 85message NegotiatedSecurityAssociation { 86 /** Calling module IWLAN or VPN or VCN */ 87 optional android.stats.ike.IkeCaller ike_caller = 1; 88 89 /** IKE session or Child session */ 90 optional android.stats.ike.SessionType session_type = 2; 91 92 /** Initial session setup or Rekey session */ 93 optional android.stats.ike.IkeState ike_state = 3; 94 95 /** negotiated DH-Groups */ 96 optional android.stats.ike.DhGroups dh_group = 4; 97 98 /** negotiated encryption algorithms */ 99 optional android.stats.ike.EncryptionAlgorithms encryption_algorithm = 5; 100 101 /** negotiated encryption algorithms key length */ 102 optional android.stats.ike.KeyLengths key_length = 6; 103 104 /** negotiated integrity algorithms */ 105 optional android.stats.ike.IntegrityAlgorithms integrity_algorithm = 7; 106 107 /** negotiated Prf algorithms */ 108 optional android.stats.ike.PrfAlgorithms prf_algorithms = 8; 109 110 /** negotiation failures */ 111 optional android.stats.ike.IkeError ike_error = 9; 112} 113 114