/frameworks/base/tests/net/java/android/net/ |
D | MacAddressTest.java | 54 AddrTypeTestCase.of(MacAddress.TYPE_UNKNOWN), in testMacAddrTypes() 55 AddrTypeTestCase.of(MacAddress.TYPE_UNKNOWN, 0), in testMacAddrTypes() 56 AddrTypeTestCase.of(MacAddress.TYPE_UNKNOWN, 1, 2, 3, 4, 5), in testMacAddrTypes() 57 AddrTypeTestCase.of(MacAddress.TYPE_UNKNOWN, 1, 2, 3, 4, 5, 6, 7), in testMacAddrTypes() 58 AddrTypeTestCase.of(MacAddress.TYPE_UNICAST, 0xa0, 0xb0, 0xc0, 0xd0, 0xe0, 0xf0), in testMacAddrTypes() 59 AddrTypeTestCase.of(MacAddress.TYPE_BROADCAST, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff), in testMacAddrTypes() 60 AddrTypeTestCase.of(MacAddress.TYPE_MULTICAST, 1, 2, 3, 4, 5, 6), in testMacAddrTypes() 61 AddrTypeTestCase.of(MacAddress.TYPE_MULTICAST, 11, 22, 33, 44, 55, 66), in testMacAddrTypes() 62 AddrTypeTestCase.of(MacAddress.TYPE_MULTICAST, 33, 33, 0xaa, 0xbb, 0xcc, 0xdd) in testMacAddrTypes() 66 int got = MacAddress.macAddressType(t.addr); in testMacAddrTypes() [all …]
|
/frameworks/base/core/java/android/net/ |
D | MacAddress.java | 43 public final class MacAddress implements Parcelable { class 51 public static final MacAddress BROADCAST_ADDRESS = MacAddress.fromBytes(ETHER_ADDR_BROADCAST); 60 public static final MacAddress ALL_ZEROS_ADDRESS = new MacAddress(0); 82 private static final long LOCALLY_ASSIGNED_MASK = MacAddress.fromString("2:0:0:0:0:0").mAddr; 83 private static final long MULTICAST_MASK = MacAddress.fromString("1:0:0:0:0:0").mAddr; 84 private static final long OUI_MASK = MacAddress.fromString("ff:ff:ff:0:0:0").mAddr; 85 private static final long NIC_MASK = MacAddress.fromString("0:0:0:ff:ff:ff").mAddr; 86 private static final MacAddress BASE_GOOGLE_MAC = MacAddress.fromString("da:a1:19:0:0:0"); 95 private MacAddress(long addr) { in MacAddress() method in MacAddress 157 return (o instanceof MacAddress) && ((MacAddress) o).mAddr == mAddr; in equals() [all …]
|
/frameworks/base/wifi/tests/src/android/net/wifi/ |
D | WifiNetworkSpecifierTest.java | 27 import android.net.MacAddress; 68 assertEquals(MacAddress.ALL_ZEROS_ADDRESS, wifiNetworkSpecifier.bssidPatternMatcher.first); in testWifiNetworkSpecifierBuilderForOpenNetworkWithSsidPattern() 69 assertEquals(MacAddress.ALL_ZEROS_ADDRESS, wifiNetworkSpecifier.bssidPatternMatcher.second); in testWifiNetworkSpecifierBuilderForOpenNetworkWithSsidPattern() 82 .setBssidPattern(MacAddress.fromString(TEST_BSSID_OUI_BASE_ADDRESS), in testWifiNetworkSpecifierBuilderForWpa2PskNetworkWithBssidPattern() 83 MacAddress.fromString(TEST_BSSID_OUI_MASK)) in testWifiNetworkSpecifierBuilderForWpa2PskNetworkWithBssidPattern() 92 assertEquals(MacAddress.fromString(TEST_BSSID_OUI_BASE_ADDRESS), in testWifiNetworkSpecifierBuilderForWpa2PskNetworkWithBssidPattern() 94 assertEquals(MacAddress.fromString(TEST_BSSID_OUI_MASK), in testWifiNetworkSpecifierBuilderForWpa2PskNetworkWithBssidPattern() 115 .setBssid(MacAddress.fromString(TEST_BSSID)) in testWifiNetworkSpecifierBuilderForWpa2EapHiddenNetworkWithSsidAndBssid() 125 assertEquals(MacAddress.fromString(TEST_BSSID), in testWifiNetworkSpecifierBuilderForWpa2EapHiddenNetworkWithSsidAndBssid() 127 assertEquals(MacAddress.BROADCAST_ADDRESS, in testWifiNetworkSpecifierBuilderForWpa2EapHiddenNetworkWithSsidAndBssid() [all …]
|
D | WifiNetworkAgentSpecifierTest.java | 23 import android.net.MacAddress; 210 Pair<MacAddress, MacAddress> bssidPattern = in testWifiNetworkAgentSpecifierSatisfiesNetworkSpecifierWithSsidPattern() 211 Pair.create(MacAddress.ALL_ZEROS_ADDRESS, MacAddress.ALL_ZEROS_ADDRESS); in testWifiNetworkAgentSpecifierSatisfiesNetworkSpecifierWithSsidPattern() 238 Pair<MacAddress, MacAddress> bssidPattern = in testWifiNetworkAgentSpecifierSatisfiesNetworkSpecifierWithBssidPattern() 239 Pair.create(MacAddress.fromString(TEST_BSSID_OUI_BASE_ADDRESS), in testWifiNetworkAgentSpecifierSatisfiesNetworkSpecifierWithBssidPattern() 240 MacAddress.fromString(TEST_BSSID_OUI_MASK)); in testWifiNetworkAgentSpecifierSatisfiesNetworkSpecifierWithBssidPattern() 267 Pair<MacAddress, MacAddress> bssidPattern = in testWifiNetworkAgentSpecifierSatisfiesNetworkSpecifierWithSsidAndBssidPattern() 268 Pair.create(MacAddress.fromString(TEST_BSSID_OUI_BASE_ADDRESS), in testWifiNetworkAgentSpecifierSatisfiesNetworkSpecifierWithSsidAndBssidPattern() 269 MacAddress.fromString(TEST_BSSID_OUI_MASK)); in testWifiNetworkAgentSpecifierSatisfiesNetworkSpecifierWithSsidAndBssidPattern() 301 Pair<MacAddress, MacAddress> bssidPattern = in testWifiNetworkAgentSpecifierDoesNotSatisfyNetworkSpecifierWithSsidPattern() [all …]
|
D | WifiConfigurationTest.java | 25 import android.net.MacAddress; 65 MacAddress macBeforeParcel = config.getOrCreateRandomizedMacAddress(); in testWifiConfigurationParcel() 198 MacAddress defaultMac = MacAddress.fromString(WifiInfo.DEFAULT_MAC_ADDRESS); in testGetOrCreateRandomizedMacAddress_SavesAndReturnsSameAddress() 201 MacAddress firstMacAddress = config.getOrCreateRandomizedMacAddress(); in testGetOrCreateRandomizedMacAddress_SavesAndReturnsSameAddress() 202 MacAddress secondMacAddress = config.getOrCreateRandomizedMacAddress(); in testGetOrCreateRandomizedMacAddress_SavesAndReturnsSameAddress() 211 MacAddress defaultMac = MacAddress.fromString(WifiInfo.DEFAULT_MAC_ADDRESS); in testSetRandomizedMacAddress_ChangesSavedAddress() 214 MacAddress macToChangeInto = MacAddress.createRandomUnicastAddress(); in testSetRandomizedMacAddress_ChangesSavedAddress() 216 MacAddress macAfterChange = config.getRandomizedMacAddress(); in testSetRandomizedMacAddress_ChangesSavedAddress() 225 MacAddress defaultMac = MacAddress.fromString(WifiInfo.DEFAULT_MAC_ADDRESS); in testGetOrCreateRandomizedMacAddress_ReRandomizesInvalidAddress() 226 MacAddress macAddressZeroes = MacAddress.ALL_ZEROS_ADDRESS; in testGetOrCreateRandomizedMacAddress_ReRandomizesInvalidAddress() [all …]
|
/frameworks/base/wifi/java/android/net/wifi/ |
D | WifiNetworkSpecifier.java | 24 import android.net.MacAddress; 51 private static final Pair<MacAddress, MacAddress> MATCH_NO_BSSID_PATTERN1 = 52 new Pair(MacAddress.BROADCAST_ADDRESS, MacAddress.BROADCAST_ADDRESS); 53 private static final Pair<MacAddress, MacAddress> MATCH_NO_BSSID_PATTERN2 = 54 new Pair(MacAddress.ALL_ZEROS_ADDRESS, MacAddress.BROADCAST_ADDRESS); 55 private static final Pair<MacAddress, MacAddress> MATCH_ALL_BSSID_PATTERN = 56 new Pair(MacAddress.ALL_ZEROS_ADDRESS, MacAddress.ALL_ZEROS_ADDRESS); 57 private static final MacAddress MATCH_EXACT_BSSID_PATTERN_MASK = 58 MacAddress.BROADCAST_ADDRESS; 68 private @Nullable Pair<MacAddress, MacAddress> mBssidPatternMatcher; [all …]
|
D | WifiNetworkAgentSpecifier.java | 24 import android.net.MacAddress; 143 final MacAddress bssid = MacAddress.fromString(this.mWifiConfiguration.BSSID); in satisfiesNetworkSpecifier() 144 final MacAddress matchBaseAddress = ns.bssidPatternMatcher.first; in satisfiesNetworkSpecifier() 145 final MacAddress matchMask = ns.bssidPatternMatcher.second; in satisfiesNetworkSpecifier()
|
D | WifiNetworkSuggestion.java | 25 import android.net.MacAddress; 59 private MacAddress mBssid; 154 public @NonNull Builder setBssid(@NonNull MacAddress bssid) { in setBssid() 156 mBssid = MacAddress.fromBytes(bssid.toByteArray()); in setBssid() 429 && (mBssid.equals(MacAddress.BROADCAST_ADDRESS) in build() 430 || mBssid.equals(MacAddress.ALL_ZEROS_ADDRESS))) { in build()
|
/frameworks/base/services/net/java/android/net/util/ |
D | InterfaceParams.java | 21 import android.net.MacAddress; 41 public final MacAddress macAddr; 54 final MacAddress macAddr = getMacAddress(netif); in getByName() 63 public InterfaceParams(String name, int index, MacAddress macAddr) { in InterfaceParams() 67 public InterfaceParams(String name, int index, MacAddress macAddr, int defaultMtu) { in InterfaceParams() 72 this.macAddr = (macAddr != null) ? macAddr : MacAddress.fromBytes(new byte[] { in InterfaceParams() 90 private static MacAddress getMacAddress(NetworkInterface netif) { in getMacAddress() 92 return MacAddress.fromBytes(netif.getHardwareAddress()); in getMacAddress()
|
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/ |
D | WifiConfigurationUtil.java | 23 import android.net.MacAddress; 71 private static final Pair<MacAddress, MacAddress> MATCH_NONE_BSSID_PATTERN = 72 new Pair(MacAddress.BROADCAST_ADDRESS, MacAddress.BROADCAST_ADDRESS); 73 private static final Pair<MacAddress, MacAddress> MATCH_ALL_BSSID_PATTERN = 74 new Pair(MacAddress.ALL_ZEROS_ADDRESS, MacAddress.ALL_ZEROS_ADDRESS); 384 private static boolean validateBssid(MacAddress bssid) { in validateBssid() 386 if (bssid.getAddressType() != MacAddress.TYPE_UNICAST) { in validateBssid() 399 MacAddress bssidMacAddress; in validateBssid() 401 bssidMacAddress = MacAddress.fromString(bssid); in validateBssid() 631 Pair<MacAddress, MacAddress> bssidPatternMatcher) { in validateBssidPattern() argument [all …]
|
D | WifiCandidates.java | 21 import android.net.MacAddress; 297 public final MacAddress bssid; 301 MacAddress bssid, in Key() 326 @Nullable private MacAddress mCurrentBssid = null; 336 mCurrentBssid = MacAddress.fromString(currentBssid); in setCurrent() 356 MacAddress bssid; in add() 358 bssid = MacAddress.fromString(scanResult.BSSID); in add()
|
D | WifiScoreCard.java | 24 import android.net.MacAddress; 154 mDummyPerBssid = new PerBssid("", MacAddress.fromString(DEFAULT_MAC_ADDRESS)); in WifiScoreCard() 370 public final MacAddress bssid; 377 PerBssid(String ssid, MacAddress bssid) { in PerBssid() 515 private final Map<MacAddress, PerBssid> mApForBssid = new ArrayMap<>(); 519 MacAddress mac; in lookupBssid() 524 mac = MacAddress.fromString(bssid); in lookupBssid() 583 private long computeHashLong(String ssid, MacAddress mac) { in computeHashLong() 631 PerBssid fetchByBssid(MacAddress mac) { in fetchByBssid() 637 MacAddress bssid = MacAddress.fromBytes(ap.getBssid().toByteArray()); in perBssidFromAccessPoint()
|
/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/ |
D | NetworkRequestStoreDataTest.java | 22 import android.net.MacAddress; 116 MacAddress.createRandomUnicastAddress(), WifiConfiguration.SECURITY_TYPE_PSK); in serializeDeserializeSingleNetworkRequestFromSingleApp() 134 MacAddress.createRandomUnicastAddress(), WifiConfiguration.SECURITY_TYPE_PSK); in serializeDeserializeSingleNetworkRequestFromMultipleApps() 142 MacAddress.createRandomUnicastAddress(), WifiConfiguration.SECURITY_TYPE_PSK); in serializeDeserializeSingleNetworkRequestFromMultipleApps() 160 MacAddress.createRandomUnicastAddress(), WifiConfiguration.SECURITY_TYPE_PSK); in serializeDeserializeMultipleNetworkRequestFromMultipleApps() 163 MacAddress.createRandomUnicastAddress(), WifiConfiguration.SECURITY_TYPE_OPEN); in serializeDeserializeMultipleNetworkRequestFromMultipleApps() 172 MacAddress.createRandomUnicastAddress(), WifiConfiguration.SECURITY_TYPE_SAE); in serializeDeserializeMultipleNetworkRequestFromMultipleApps() 175 MacAddress.createRandomUnicastAddress(), WifiConfiguration.SECURITY_TYPE_OPEN); in serializeDeserializeMultipleNetworkRequestFromMultipleApps()
|
D | WifiNetworkFactoryTest.java | 40 import android.net.MacAddress; 702 Pair<MacAddress, MacAddress> bssidPatternMatch = in testNetworkSpecifierMatchSuccessUsingLiteralSsidMatch() 703 Pair.create(MacAddress.ALL_ZEROS_ADDRESS, MacAddress.ALL_ZEROS_ADDRESS); in testNetworkSpecifierMatchSuccessUsingLiteralSsidMatch() 745 Pair<MacAddress, MacAddress> bssidPatternMatch = in testNetworkSpecifierMatchSuccessUsingPrefixSsidMatch() 746 Pair.create(MacAddress.ALL_ZEROS_ADDRESS, MacAddress.ALL_ZEROS_ADDRESS); in testNetworkSpecifierMatchSuccessUsingPrefixSsidMatch() 789 Pair<MacAddress, MacAddress> bssidPatternMatch = in testNetworkSpecifierMatchSuccessUsingLiteralBssidMatch() 790 Pair.create(MacAddress.fromString(TEST_BSSID_1), MacAddress.BROADCAST_ADDRESS); in testNetworkSpecifierMatchSuccessUsingLiteralBssidMatch() 832 Pair<MacAddress, MacAddress> bssidPatternMatch = in testNetworkSpecifierMatchSuccessUsingOuiPrefixBssidMatch() 833 Pair.create(MacAddress.fromString(TEST_BSSID_1_2_OUI), in testNetworkSpecifierMatchSuccessUsingOuiPrefixBssidMatch() 834 MacAddress.fromString(TEST_BSSID_OUI_MASK)); in testNetworkSpecifierMatchSuccessUsingOuiPrefixBssidMatch() [all …]
|
D | WifiConfigurationUtilTest.java | 23 import android.net.MacAddress; 596 Pair.create(MacAddress.ALL_ZEROS_ADDRESS, MacAddress.ALL_ZEROS_ADDRESS), in testValidateNetworkSpecifierPositiveCases_SsidPattern() 610 Pair.create(MacAddress.fromString(TEST_BSSID), MacAddress.BROADCAST_ADDRESS), in testValidateNetworkSpecifierPositiveCases_BssidPattern() 624 Pair.create(MacAddress.fromString(TEST_BSSID), MacAddress.BROADCAST_ADDRESS), in testValidateNetworkSpecifierPositiveCases_BothSsidPatternAndBssidPattern() 638 Pair.create(MacAddress.ALL_ZEROS_ADDRESS, MacAddress.ALL_ZEROS_ADDRESS), in testValidateNetworkSpecifierNegativeCases_NoSsidBssid() 652 Pair.create(MacAddress.ALL_ZEROS_ADDRESS, MacAddress.ALL_ZEROS_ADDRESS), in testValidateNetworkSpecifierNegativeCases_MatchNoneSsidPattern() 666 Pair.create(MacAddress.BROADCAST_ADDRESS, MacAddress.BROADCAST_ADDRESS), in testValidateNetworkSpecifierNegativeCases_MatchNoneBssidPattern() 680 Pair.create(MacAddress.fromString(TEST_BSSID), MacAddress.ALL_ZEROS_ADDRESS), in testValidateNetworkSpecifierNegativeCases_InvalidBssidPattern() 694 Pair.create(MacAddress.ALL_ZEROS_ADDRESS, MacAddress.ALL_ZEROS_ADDRESS), in testValidateNetworkSpecifierNegativeCases_NoSsidPatternForHiddenNetwork()
|
D | WifiCandidatesTest.java | 24 import android.net.MacAddress; 137 MacAddress mac1 = MacAddress.createRandomUnicastAddress(); in testKeyEquivalence() 138 MacAddress mac2 = MacAddress.createRandomUnicastAddress(); in testKeyEquivalence()
|
/frameworks/base/wifi/tests/src/android/net/wifi/rtt/ |
D | WifiRttManagerTest.java | 28 import android.net.MacAddress; 83 new RangingResult(RangingResult.STATUS_SUCCESS, MacAddress.BROADCAST_ADDRESS, 15, 5, in testRangeSuccess() 140 MacAddress mac1 = MacAddress.fromString("00:01:02:03:04:05"); in testRangingRequestParcel() 174 MacAddress mac1 = MacAddress.fromString("00:01:02:03:04:05"); in testRangingRequestAtLimit() 199 MacAddress mac1 = MacAddress.fromString("00:01:02:03:04:05"); in testRangingRequestPastLimit() 233 final MacAddress mac = MacAddress.fromString("00:01:02:03:04:05"); in testRangingResultsParcel() 283 final MacAddress mac = MacAddress.fromString("00:01:02:03:04:05"); in testRangingResultsEqualityLciLcr() 308 ResponderConfig config = new ResponderConfig(MacAddress.fromString("00:01:02:03:04:05"), in testResponderConfigParcel()
|
D | ResponderLocationTest.java | 21 import android.net.MacAddress; 453 List<MacAddress> bssidList = responderLocation.getColocatedBssids(); in testLciBssidListSEAfterLci() 457 MacAddress macAddress1 = bssidList.get(0); in testLciBssidListSEAfterLci() 459 MacAddress macAddress2 = bssidList.get(1); in testLciBssidListSEAfterLci() 474 List<MacAddress> bssidList = responderLocation.getColocatedBssids(); in testLciBssidListSEBeforeLci() 478 MacAddress macAddress1 = bssidList.get(0); in testLciBssidListSEBeforeLci() 480 MacAddress macAddress2 = bssidList.get(1); in testLciBssidListSEBeforeLci()
|
/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/rtt/ |
D | RttTestUtils.java | 21 import android.net.MacAddress; 71 MacAddress mac1 = MacAddress.fromString("08:09:08:07:06:05"); in getDummyRangingRequest() 146 MacAddress.fromString("10:01:02:03:04:05"), rangeCmBase++, in getDummyRangingResults() 150 MacAddress.fromString("1A:0B:0C:0D:0E:0F"), rangeCmBase++, in getDummyRangingResults() 154 MacAddress.fromString("08:09:08:07:06:05"), rangeCmBase++, in getDummyRangingResults() 166 MacAddress overrideMac) { in getMatchingRttResult()
|
D | RttNativeTest.java | 43 import android.net.MacAddress; 142 equalTo(MacAddress.fromString("00:01:02:03:04:00").toByteArray())); in testRangeRequest() 150 equalTo(MacAddress.fromString("0A:0B:0C:0D:0E:00").toByteArray())); in testRangeRequest() 158 equalTo(MacAddress.fromString("08:09:08:07:06:05").toByteArray())); in testRangeRequest() 192 equalTo(MacAddress.fromString("00:01:02:03:04:00").toByteArray())); in testRangeRequestNotPrivilegedNo80211mcSupportMixed() 200 equalTo(MacAddress.fromString("08:09:08:07:06:05").toByteArray())); in testRangeRequestNotPrivilegedNo80211mcSupportMixed() 245 equalTo(MacAddress.fromString("00:01:02:03:04:00").toByteArray())); in testRangeRequestWithLimitedCapabilities() 257 equalTo(MacAddress.fromString("08:09:08:07:06:05").toByteArray())); in testRangeRequestWithLimitedCapabilities() 299 equalTo(MacAddress.fromString("08:09:08:07:06:05").toByteArray())); in testRangeRequestWithLimitedCapabilitiesNoOverlap() 423 equalTo(MacAddress.fromString("05:06:07:08:09:0A").toByteArray())); in testRangeResults()
|
/frameworks/base/wifi/java/android/net/wifi/rtt/ |
D | ResponderConfig.java | 25 import android.net.MacAddress; 133 public final MacAddress macAddress; 200 public ResponderConfig(@NonNull MacAddress macAddress, @ResponderType int responderType, in ResponderConfig() 277 public ResponderConfig(@NonNull MacAddress macAddress, @NonNull PeerHandle peerHandle, in ResponderConfig() 297 MacAddress macAddress = MacAddress.fromString(scanResult.BSSID); in fromScanResult() 340 public static ResponderConfig fromWifiAwarePeerMacAddressWithDefaults(MacAddress macAddress) { in fromWifiAwarePeerMacAddressWithDefaults() 418 MacAddress macAddress = null; 420 macAddress = MacAddress.CREATOR.createFromParcel(in);
|
D | RangingResult.java | 23 import android.net.MacAddress; 76 private final MacAddress mMac; 89 public RangingResult(@RangeResultStatus int status, @NonNull MacAddress mac, int distanceMm, in RangingResult() 143 public MacAddress getMacAddress() { in getMacAddress() 365 MacAddress mac = null; 367 mac = MacAddress.CREATOR.createFromParcel(in);
|
/frameworks/base/core/java/android/net/metrics/ |
D | WakeupStats.java | 19 import android.net.MacAddress; 84 case MacAddress.TYPE_UNICAST: in countEvent() 87 case MacAddress.TYPE_MULTICAST: in countEvent() 90 case MacAddress.TYPE_BROADCAST: in countEvent()
|
D | WakeupEvent.java | 19 import android.net.MacAddress; 32 public MacAddress dstHwAddr;
|
/frameworks/base/wifi/java/android/net/wifi/p2p/ |
D | WifiP2pConfig.java | 23 import android.net.MacAddress; 229 private static final MacAddress MAC_ANY_ADDRESS = 230 MacAddress.fromString("02:00:00:00:00:00"); 232 private MacAddress mDeviceAddress = MAC_ANY_ADDRESS; 251 public @NonNull Builder setDeviceAddress(@Nullable MacAddress deviceAddress) { in setDeviceAddress()
|