1/*
2 * Copyright (C) 2018 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";
18package android.net.wifi;
19
20option java_outer_classname = "WifiProtoEnums";
21option java_multiple_files = true;
22
23/**
24 * Wifi Lock modes, primarily used in
25 * frameworks/opt/net/wifi/service/java/com/android/server/wifi/WifiLockManager.java.
26 */
27enum WifiModeEnum {
28    /**
29     * Deprecated.
30     * Wi-Fi will be kept active, and will behave normally.
31     */
32    WIFI_MODE_FULL = 1 [deprecated=true];
33
34    /**
35     * Deprecated.
36     * Wi-Fi will be kept active, but the only operation that will be supported is initiation of
37     * scans, and the subsequent reporting of scan results.
38     */
39    WIFI_MODE_SCAN_ONLY = 2 [deprecated=true];
40
41    /**
42     * Wi-Fi will not go to power save.
43     */
44    WIFI_MODE_FULL_HIGH_PERF = 3;
45
46    /**
47     * Wi-Fi will operate with a priority to achieve low latency.
48     */
49    WIFI_MODE_FULL_LOW_LATENCY = 4;
50}
51
52/**
53 * Wifi authentication type.
54 */
55enum WifiAuthType {
56    AUTH_TYPE_NONE = 0;
57
58    // WPA pre-shared key.
59    AUTH_TYPE_WPA_PSK = 1;
60    // WPA using EAP authentication. Generally used with an external authentication server.
61    AUTH_TYPE_WPA_EAP = 2;
62    // IEEE 802.1X using EAP authentication and (optionally) dynamically generated WEP keys.
63    AUTH_TYPE_IEEE8021X = 3;
64    // WPA2 pre-shared key for use with soft access point.
65    AUTH_TYPE_WPA2_PSK = 4;
66    // Hotspot 2.0 r2 OSEN.
67    AUTH_TYPE_OSEN = 5;
68    // IEEE 802.11r Fast BSS Transition with PSK authentication.
69    AUTH_TYPE_FT_PSK = 6;
70    // IEEE 802.11r Fast BSS Transition with EAP authentication.
71    AUTH_TYPE_FT_EAP = 7;
72    // Simultaneous Authentication of Equals.
73    AUTH_TYPE_SAE = 8;
74    // Opportunistic Wireless Encryption.
75    AUTH_TYPE_OWE = 9;
76    // SUITE_B_192 192 bit level
77    AUTH_TYPE_SUITE_B_192 = 10;
78    // WPA pre-shared key with stronger SHA256-based algorithms.
79    AUTH_TYPE_WPA_PSK_SHA256 = 11;
80    // WPA using EAP authentication with stronger SHA256-based algorithms.
81    AUTH_TYPE_WPA_EAP_SHA256 = 12;
82    // WAPI pre-shared key.
83    AUTH_TYPE_WAPI_PSK = 13;
84    // WAPI certificate to be specified.
85    AUTH_TYPE_WAPI_CERT = 14;
86    // IEEE 802.11ai FILS SK with SHA256.
87    AUTH_TYPE_FILS_SHA256 = 15;
88    // IEEE 802.11ai FILS SK with SHA384.
89    AUTH_TYPE_FILS_SHA384 = 16;
90}
91
92/**
93 * Bucketed wifi band.
94 */
95enum WifiBandBucket {
96    BAND_UNKNOWN = 0;
97
98    // All of 2.4GHz band
99    BAND_2G = 1;
100    // Frequencies in the range of [5150, 5250) GHz
101    BAND_5G_LOW = 2;
102    // Frequencies in the range of [5250, 5725) GHz
103    BAND_5G_MIDDLE = 3;
104    // Frequencies in the range of [5725, 5850) GHz
105    BAND_5G_HIGH = 4;
106    // Frequencies in the range of [5925, 6425) GHz
107    BAND_6G_LOW = 5;
108    // Frequencies in the range of [6425, 6875) GHz
109    BAND_6G_MIDDLE = 6;
110    // Frequencies in the range of [6875, 7125) GHz
111    BAND_6G_HIGH = 7;
112}