Hai Shalom | fcc8fa0 | 2018-10-15 15:36:04 -0700 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 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 | |
| 17 | package android.hardware.wifi.supplicant@1.2; |
| 18 | |
| 19 | import @1.0::ISupplicantStaNetworkCallback; |
| 20 | import @1.0::ISupplicantStaNetwork; |
| 21 | import @1.0::SupplicantStatus; |
| 22 | import @1.1::ISupplicantStaNetwork; |
| 23 | |
| 24 | /** |
| 25 | * Interface exposed by the supplicant for each station mode network |
| 26 | * configuration it controls. |
| 27 | */ |
| 28 | interface ISupplicantStaNetwork extends @1.1::ISupplicantStaNetwork { |
| 29 | /** Possble mask of values for KeyMgmt param. */ |
| 30 | enum KeyMgmtMask : @1.0::ISupplicantStaNetwork.KeyMgmtMask { |
| 31 | /** WPA3-Personal SAE Key management */ |
| 32 | SAE = 1 << 10, |
| 33 | |
| 34 | /** WPA3-Enterprise Suite-B Key management */ |
| 35 | SUITE_B_192 = 1 << 17, |
| 36 | |
| 37 | /** Enhacned Open (OWE) Key management */ |
| 38 | OWE = 1 << 22, |
Hai Shalom | 92c3cc4 | 2018-12-27 15:43:17 -0800 | [diff] [blame^] | 39 | |
| 40 | /** Easy Connect (DPP) Key management */ |
| 41 | DPP = 1 << 23, |
Hai Shalom | fcc8fa0 | 2018-10-15 15:36:04 -0700 | [diff] [blame] | 42 | }; |
| 43 | |
| 44 | /** Possble mask of values for PairwiseCipher param. */ |
| 45 | enum PairwiseCipherMask : @1.0::ISupplicantStaNetwork.PairwiseCipherMask { |
| 46 | /** GCMP-256 Pairwise Cipher */ |
| 47 | GCMP_256 = 1 << 8, |
| 48 | }; |
| 49 | |
| 50 | /** Possble mask of values for GroupCipher param. */ |
| 51 | enum GroupCipherMask : @1.0::ISupplicantStaNetwork.GroupCipherMask { |
| 52 | /** GCMP-256 Group Cipher */ |
| 53 | GCMP_256 = 1 << 8, |
| 54 | }; |
| 55 | |
Hai Shalom | dbcb2c6 | 2018-10-30 15:23:01 -0700 | [diff] [blame] | 56 | /** Possble mask of values for GroupMgmtCipher param. */ |
| 57 | enum GroupMgmtCipherMask : uint32_t { |
| 58 | /** BIP_GMAC-128 Group Management Cipher */ |
| 59 | BIP_GMAC_128 = 1 << 11, |
| 60 | |
| 61 | /** BIP_GMAC-256 Group Management Cipher */ |
| 62 | BIP_GMAC_256 = 1 << 12, |
| 63 | |
| 64 | /** BIP_CMAC-256 Group Management Cipher */ |
| 65 | BIP_CMAC_256 = 1 << 13, |
| 66 | }; |
| 67 | |
Hai Shalom | fcc8fa0 | 2018-10-15 15:36:04 -0700 | [diff] [blame] | 68 | /** |
| 69 | * Set key management mask for the network. |
| 70 | * |
| 71 | * @param keyMgmtMask value to set. |
| 72 | * Combination of |KeyMgmtMask| values. |
| 73 | * @return status Status of the operation. |
| 74 | * Possible status codes: |
| 75 | * |SupplicantStatusCode.SUCCESS|, |
| 76 | * |SupplicantStatusCode.FAILURE_ARGS_INVALID|, |
| 77 | * |SupplicantStatusCode.FAILURE_UNKNOWN|, |
| 78 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 79 | */ |
| 80 | setKeyMgmt_1_2(bitfield<KeyMgmtMask> keyMgmtMask) generates (SupplicantStatus status); |
| 81 | |
| 82 | /** |
| 83 | * Get the key mgmt mask set for the network. |
| 84 | * |
| 85 | * @return status Status of the operation. |
| 86 | * Possible status codes: |
| 87 | * |SupplicantStatusCode.SUCCESS|, |
| 88 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 89 | * @return keyMgmtMask Combination of |KeyMgmtMask| values. |
| 90 | */ |
| 91 | getKeyMgmt_1_2() |
| 92 | generates (SupplicantStatus status, bitfield<KeyMgmtMask> keyMgmtMask); |
| 93 | |
| 94 | /** |
| 95 | * Set pairwise cipher mask for the network. |
| 96 | * |
| 97 | * @param pairwiseCipherMask value to set. |
| 98 | * Combination of |PairwiseCipherMask| values. |
| 99 | * @return status Status of the operation. |
| 100 | * Possible status codes: |
| 101 | * |SupplicantStatusCode.SUCCESS|, |
| 102 | * |SupplicantStatusCode.FAILURE_ARGS_INVALID|, |
| 103 | * |SupplicantStatusCode.FAILURE_UNKNOWN|, |
| 104 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 105 | */ |
| 106 | setPairwiseCipher_1_2(bitfield<PairwiseCipherMask> pairwiseCipherMask) |
| 107 | generates (SupplicantStatus status); |
| 108 | |
| 109 | /** |
| 110 | * Get the pairwise cipher mask set for the network. |
| 111 | * |
| 112 | * @return status Status of the operation. |
| 113 | * Possible status codes: |
| 114 | * |SupplicantStatusCode.SUCCESS|, |
| 115 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 116 | * @return pairwiseCipherMask Combination of |PairwiseCipherMask| values. |
| 117 | */ |
| 118 | getPairwiseCipher_1_2() |
| 119 | generates (SupplicantStatus status, |
| 120 | bitfield<PairwiseCipherMask> pairwiseCipherMask); |
| 121 | |
| 122 | /** |
| 123 | * Set group cipher mask for the network. |
| 124 | * |
| 125 | * @param groupCipherMask value to set. |
| 126 | * Combination of |GroupCipherMask| values. |
| 127 | * @return status Status of the operation. |
| 128 | * Possible status codes: |
| 129 | * |SupplicantStatusCode.SUCCESS|, |
| 130 | * |SupplicantStatusCode.FAILURE_ARGS_INVALID|, |
| 131 | * |SupplicantStatusCode.FAILURE_UNKNOWN|, |
| 132 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 133 | */ |
| 134 | setGroupCipher_1_2(bitfield<GroupCipherMask> groupCipherMask) |
| 135 | generates (SupplicantStatus status); |
| 136 | |
| 137 | /** |
| 138 | * Get the group cipher mask set for the network. |
| 139 | * |
| 140 | * @return status Status of the operation. |
| 141 | * Possible status codes: |
| 142 | * |SupplicantStatusCode.SUCCESS|, |
| 143 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 144 | * @return groupCipherMask Combination of |GroupCipherMask| values. |
| 145 | */ |
| 146 | getGroupCipher_1_2() |
| 147 | generates (SupplicantStatus status, |
| 148 | bitfield<GroupCipherMask> groupCipherMask); |
| 149 | |
| 150 | /** |
Hai Shalom | dbcb2c6 | 2018-10-30 15:23:01 -0700 | [diff] [blame] | 151 | * Set group management cipher mask for the network. |
| 152 | * |
| 153 | * @param groupMgmtCipherMask value to set. |
| 154 | * Combination of |GroupMgmtCipherMask| values. |
| 155 | * @return status Status of the operation. |
| 156 | * Possible status codes: |
| 157 | * |SupplicantStatusCode.SUCCESS|, |
| 158 | * |SupplicantStatusCode.FAILURE_ARGS_INVALID|, |
| 159 | * |SupplicantStatusCode.FAILURE_UNKNOWN|, |
| 160 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 161 | */ |
| 162 | setGroupMgmtCipher(bitfield<GroupMgmtCipherMask> groupMgmtCipherMask) |
| 163 | generates (SupplicantStatus status); |
| 164 | |
| 165 | /** |
| 166 | * Get the group management cipher mask set for the network. |
| 167 | * |
| 168 | * @return status Status of the operation. |
| 169 | * Possible status codes: |
| 170 | * |SupplicantStatusCode.SUCCESS|, |
| 171 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 172 | * @return groupMgmtCipherMask Combination of |GroupMgmtCipherMask| values. |
| 173 | */ |
| 174 | getGroupMgmtCipher() |
| 175 | generates (SupplicantStatus status, |
| 176 | bitfield<GroupMgmtCipherMask> groupMgmtCipherMask); |
| 177 | |
| 178 | /** |
Hai Shalom | fcc8fa0 | 2018-10-15 15:36:04 -0700 | [diff] [blame] | 179 | * Enable TLS Suite-B in EAP Phase1 |
| 180 | * |
| 181 | * @param enable Set to true to enable TLS Suite-B in EAP phase1 |
| 182 | * |
| 183 | * @return status Status of the operation. |
| 184 | * Possible status codes: |
| 185 | * |SupplicantStatusCode.SUCCESS|, |
| 186 | * |SupplicantStatusCode.FAILURE_ARGS_INVALID|, |
| 187 | * |SupplicantStatusCode.FAILURE_UNKNOWN|, |
| 188 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 189 | */ |
| 190 | enableTlsSuiteBEapPhase1Param(bool enable) |
| 191 | generates (SupplicantStatus status); |
| 192 | |
| 193 | /** |
| 194 | * Set EAP OpenSSL Suite-B-192 ciphers for WPA3-Enterprise |
| 195 | * Supported option: |
| 196 | * |
| 197 | * @return status Status of the operation. |
| 198 | * Possible status codes: |
| 199 | * |SupplicantStatusCode.SUCCESS|, |
| 200 | * |SupplicantStatusCode.FAILURE_ARGS_INVALID|, |
| 201 | * |SupplicantStatusCode.FAILURE_UNKNOWN|, |
| 202 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 203 | */ |
| 204 | enableSuiteBEapOpenSslCiphers() |
| 205 | generates (SupplicantStatus status); |
| 206 | |
| 207 | /** |
| 208 | * Get SAE password for WPA3-Personal |
| 209 | * |
| 210 | * @return status Status of the operation, and a string. |
| 211 | * Possible status codes: |
| 212 | * |SupplicantStatusCode.SUCCESS|, |
| 213 | * |SupplicantStatusCode.FAILURE_ARGS_INVALID|, |
| 214 | * |SupplicantStatusCode.FAILURE_UNKNOWN|, |
| 215 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 216 | */ |
| 217 | getSaePassword() |
| 218 | generates (SupplicantStatus status, string saePassword); |
| 219 | |
| 220 | /** |
| 221 | * Get SAE password ID for WPA3-Personal |
| 222 | * |
| 223 | * @return status Status of the operation, and a string. |
| 224 | * Possible status codes: |
| 225 | * |SupplicantStatusCode.SUCCESS|, |
| 226 | * |SupplicantStatusCode.FAILURE_ARGS_INVALID|, |
| 227 | * |SupplicantStatusCode.FAILURE_UNKNOWN|, |
| 228 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 229 | */ |
| 230 | getSaePasswordId() |
| 231 | generates (SupplicantStatus status, string saePasswordId); |
| 232 | |
| 233 | /** |
| 234 | * Set SAE password for WPA3-Personal |
| 235 | * |
| 236 | * @param saePassword string with the above option |
| 237 | * |
| 238 | * @return status Status of the operation. |
| 239 | * Possible status codes: |
| 240 | * |SupplicantStatusCode.SUCCESS|, |
| 241 | * |SupplicantStatusCode.FAILURE_ARGS_INVALID|, |
| 242 | * |SupplicantStatusCode.FAILURE_UNKNOWN|, |
| 243 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 244 | */ |
| 245 | setSaePassword(string saePassword) |
| 246 | generates (SupplicantStatus status); |
| 247 | |
| 248 | /** |
| 249 | * Set SAE password ID for WPA3-Personal |
| 250 | * |
| 251 | * @param sae_password_id string with the above option |
| 252 | * |
| 253 | * @return status Status of the operation. |
| 254 | * Possible status codes: |
| 255 | * |SupplicantStatusCode.SUCCESS|, |
| 256 | * |SupplicantStatusCode.FAILURE_ARGS_INVALID|, |
| 257 | * |SupplicantStatusCode.FAILURE_UNKNOWN|, |
| 258 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 259 | */ |
| 260 | setSaePasswordId(string saePasswordId) |
| 261 | generates (SupplicantStatus status); |
Hai Shalom | fcc8fa0 | 2018-10-15 15:36:04 -0700 | [diff] [blame] | 262 | }; |