Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8b055fa3 authored by mukesh agrawal's avatar mukesh agrawal
Browse files

WifiConfiguration: deprecate WEP-related fields

WEP provides poor access control, poor
confidentiality, and reduces throughput. (On the
throughput front, WEP connections are limited
to 54 Mbps, even on access points that support
transmitting at speeds 10x as fast.)

Mark WEP-related fields as deprecated, to
communicate our intent to deprecate WEP connections.

Bug: 72332080
Test: m -j8 update-api
Change-Id: I0366341a62711c5f4a2e7d1bbf049a5e058d0ec2
parent 2bdb9af0
Loading
Loading
Loading
Loading
+14 −14
Original line number Diff line number Diff line
@@ -11539,15 +11539,15 @@ package android.content.res {
  public final class AssetManager implements java.lang.AutoCloseable {
    method public void close();
    method public java.lang.String[] getLocales();
    method public java.lang.String[] list(java.lang.String) throws java.io.IOException;
    method public java.io.InputStream open(java.lang.String) throws java.io.IOException;
    method public java.io.InputStream open(java.lang.String, int) throws java.io.IOException;
    method public android.content.res.AssetFileDescriptor openFd(java.lang.String) throws java.io.IOException;
    method public android.content.res.AssetFileDescriptor openNonAssetFd(java.lang.String) throws java.io.IOException;
    method public android.content.res.AssetFileDescriptor openNonAssetFd(int, java.lang.String) throws java.io.IOException;
    method public android.content.res.XmlResourceParser openXmlResourceParser(java.lang.String) throws java.io.IOException;
    method public android.content.res.XmlResourceParser openXmlResourceParser(int, java.lang.String) throws java.io.IOException;
    method public final java.lang.String[] getLocales();
    method public final java.lang.String[] list(java.lang.String) throws java.io.IOException;
    method public final java.io.InputStream open(java.lang.String) throws java.io.IOException;
    method public final java.io.InputStream open(java.lang.String, int) throws java.io.IOException;
    method public final android.content.res.AssetFileDescriptor openFd(java.lang.String) throws java.io.IOException;
    method public final android.content.res.AssetFileDescriptor openNonAssetFd(java.lang.String) throws java.io.IOException;
    method public final android.content.res.AssetFileDescriptor openNonAssetFd(int, java.lang.String) throws java.io.IOException;
    method public final android.content.res.XmlResourceParser openXmlResourceParser(java.lang.String) throws java.io.IOException;
    method public final android.content.res.XmlResourceParser openXmlResourceParser(int, java.lang.String) throws java.io.IOException;
    field public static final int ACCESS_BUFFER = 3; // 0x3
    field public static final int ACCESS_RANDOM = 1; // 0x1
    field public static final int ACCESS_STREAMING = 2; // 0x2
@@ -27369,14 +27369,14 @@ package android.net.wifi {
    field public java.lang.String providerFriendlyName;
    field public long[] roamingConsortiumIds;
    field public int status;
    field public java.lang.String[] wepKeys;
    field public int wepTxKeyIndex;
    field public deprecated java.lang.String[] wepKeys;
    field public deprecated int wepTxKeyIndex;
  }
  public static class WifiConfiguration.AuthAlgorithm {
    field public static final int LEAP = 2; // 0x2
    field public static final int OPEN = 0; // 0x0
    field public static final int SHARED = 1; // 0x1
    field public static final deprecated int SHARED = 1; // 0x1
    field public static final java.lang.String[] strings;
    field public static final java.lang.String varName = "auth_alg";
  }
@@ -27384,8 +27384,8 @@ package android.net.wifi {
  public static class WifiConfiguration.GroupCipher {
    field public static final int CCMP = 3; // 0x3
    field public static final int TKIP = 2; // 0x2
    field public static final int WEP104 = 1; // 0x1
    field public static final int WEP40 = 0; // 0x0
    field public static final deprecated int WEP104 = 1; // 0x1
    field public static final deprecated int WEP40 = 0; // 0x0
    field public static final java.lang.String[] strings;
    field public static final java.lang.String varName = "group";
  }
+23 −5
Original line number Diff line number Diff line
@@ -54,8 +54,10 @@ public class WifiConfiguration implements Parcelable {
    /** {@hide} */
    public static final String pskVarName = "psk";
    /** {@hide} */
    @Deprecated
    public static final String[] wepKeyVarNames = { "wep_key0", "wep_key1", "wep_key2", "wep_key3" };
    /** {@hide} */
    @Deprecated
    public static final String wepTxKeyIdxVarName = "wep_tx_keyidx";
    /** {@hide} */
    public static final String priorityVarName = "priority";
@@ -147,7 +149,10 @@ public class WifiConfiguration implements Parcelable {

        /** Open System authentication (required for WPA/WPA2) */
        public static final int OPEN = 0;
        /** Shared Key authentication (requires static WEP keys) */
        /** Shared Key authentication (requires static WEP keys)
         * @deprecated Due to security and performance limitations, use of WEP networks
         * is discouraged. */
        @Deprecated
        public static final int SHARED = 1;
        /** LEAP/Network EAP (only used with LEAP) */
        public static final int LEAP = 2;
@@ -187,9 +192,15 @@ public class WifiConfiguration implements Parcelable {
    public static class GroupCipher {
        private GroupCipher() { }

        /** WEP40 = WEP (Wired Equivalent Privacy) with 40-bit key (original 802.11) */
        /** WEP40 = WEP (Wired Equivalent Privacy) with 40-bit key (original 802.11)
         * @deprecated Due to security and performance limitations, use of WEP networks
         * is discouraged. */
        @Deprecated
        public static final int WEP40 = 0;
        /** WEP104 = WEP (Wired Equivalent Privacy) with 104-bit key */
        /** WEP104 = WEP (Wired Equivalent Privacy) with 104-bit key
         * @deprecated Due to security and performance limitations, use of WEP networks
         * is discouraged. */
        @Deprecated
        public static final int WEP104 = 1;
        /** Temporal Key Integrity Protocol [IEEE 802.11i/D7.0] */
        public static final int TKIP = 2;
@@ -203,7 +214,8 @@ public class WifiConfiguration implements Parcelable {
        public static final String varName = "group";

        public static final String[] strings =
                { "WEP40", "WEP104", "TKIP", "CCMP", "GTK_NOT_USED" };
                { /* deprecated */ "WEP40", /* deprecated */ "WEP104",
                        "TKIP", "CCMP", "GTK_NOT_USED" };
    }

    /** Possible status of a network configuration. */
@@ -309,10 +321,16 @@ public class WifiConfiguration implements Parcelable {
     * When the value of one of these keys is read, the actual key is
     * not returned, just a "*" if the key has a value, or the null
     * string otherwise.
     * @deprecated Due to security and performance limitations, use of WEP networks
     * is discouraged.
     */
    @Deprecated
    public String[] wepKeys;

    /** Default WEP key index, ranging from 0 to 3. */
    /** Default WEP key index, ranging from 0 to 3.
     * @deprecated Due to security and performance limitations, use of WEP networks
     * is discouraged. */
    @Deprecated
    public int wepTxKeyIndex;

    /**