1/* 2 * Copyright (C) 2020 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 telephonyPinStorage; 20 21option java_package = "com.android.internal.telephony"; 22option java_outer_classname = "StoredPinProto"; 23 24// Stores information about PIN of a SIM card. 25message StoredPin { 26 // Status of the PIN. 27 enum PinStatus { 28 // The PIN code is stored, but cannot be used for automatic verification. 29 AVAILABLE = 1; 30 31 // The PIN code is stored and will be usable for automatic verification after the 32 // unattended reboot is completed. 33 REBOOT_READY = 2; 34 35 // The PIN code is stored and can be used for automatic verification. 36 VERIFICATION_READY = 3; 37 } 38 39 // ICCID of the SIM card 40 optional string iccid = 1; 41 42 // PIN code 43 optional string pin = 2; 44 45 // Slot number 46 optional int32 slot_id = 3; 47 48 // Status of the PIN code 49 optional PinStatus status = 4; 50 51 // Boot count when the proto was generated. 52 optional int32 boot_count = 5; 53} 54 55// Stores the encrypted version of StoredPin. 56message EncryptedPin { 57 // Encrypted StoredPin 58 optional bytes encrypted_stored_pin = 1; 59 60 // Initialization vector 61 optional bytes iv = 2; 62}