java.lang.Object | |
↳ | com.samsung.android.knox.net.wifi.WifiAdminProfile |
This class contains information required to set up a Wi-Fi profile on the device. When creating a
Wi-Fi profile of a particular type, leave fields associated with other types blank. The security
type must be valid (see security
description), otherwise
setWifiProfile(WifiAdminProfile)
operation will fail.
API level 2 |
MDM 2.0 |
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
int | ENGINE_ANDROID_KEYSTORE | Engine id to use android keystore for client and CA certificates. | |||||||||
int | ENGINE_SECPKCS11 |
Deprecated
in API level 35 NOTE: This engine id is not supported on Android S and newer. Networks already configured with it will not be affected. |
|||||||||
String | PHASE1_ALLOW_AUTHENTICATED |
Deprecated
in API level 33 NOTE: This setting is not supported on Android R and newer. |
|||||||||
String | PHASE1_ALLOW_BOTH |
Deprecated
in API level 33 NOTE: This setting is not supported on Android R and newer. |
|||||||||
String | PHASE1_ALLOW_UNAUTHENTICATED |
Deprecated
in API level 33 NOTE: This setting is not supported on Android R and newer. |
|||||||||
String | PHASE1_DISABLE |
Deprecated
in API level 33 NOTE: This setting is not supported on Android R and newer. |
|||||||||
String | PHASE1_NONE |
Deprecated
in API level 33 NOTE: This setting is not supported on Android R and newer. |
|||||||||
String | PHASE2_GTC | Indicates GTC(Generic Token Card Authentication Protocol) inner authentication method will be used by EAP protocol. | |||||||||
String | PHASE2_MSCHAP | Indicates MSCHAP(Microsoft Challenge Handshake Authentication Protocol) inner authentication method will be used by EAP protocol. | |||||||||
String | PHASE2_MSCHAPV2 | Indicates MSCHAP-V2(Microsoft Challenge Handshake Authentication Protocol Version 2) inner authentication method will be used by EAP protocol. | |||||||||
String | PHASE2_NONE | Indicates no inner authentication method will be used by EAP protocol. | |||||||||
String | PHASE2_PAP | Indicates PAP(Password Authentication Protocol) inner authentication method will be used by EAP protocol. | |||||||||
int | PROXY_STATE_AUTO_CONFIGURE | Flag to indicate that a PAC based proxy is to be used for this Wi-Fi profile. | |||||||||
int | PROXY_STATE_MANUAL | Flag to indicate that a statically configured proxy is to be used for this Wi-Fi profile. | |||||||||
int | PROXY_STATE_NONE | Flag to indicate that no proxy is to be used for this Wi-Fi profile. |
[Expand]
Inherited Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From interface
android.os.Parcelable
|
Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
anonymousIdentity | Defines the anonymous identity for 802.1x EAP network type. | ||||||||||
caCertificate | Defines the Certificate Authority (CA) certificate alias for an enterprise EAP WLAN network. | ||||||||||
clientCertification | Defines the client certificate alias for an enterprise EAP WLAN network type. | ||||||||||
password | Defines the user password for enterprise WLAN EAP network type. | ||||||||||
phase1 |
Deprecated
in API level 33 NOTE: This setting is not supported on Android R and newer. |
||||||||||
phase2 | Defines the Phase 2 authentication method. | ||||||||||
proxyAuthConfigList | Defines the authentication configuration that shall be used to authenticate in the related proxy. | ||||||||||
proxyBypassList | Defines a list of URLs that should be bypassed in the proxy configured for this Wi-Fi profile. | ||||||||||
proxyHostname | Defines the hostname to be used in a statically configured proxy. | ||||||||||
proxyPacUrl | Defines the URL that is to be used in a PAC based proxy configuration. | ||||||||||
proxyPort | Defines the port to be used in a statically configured proxy. | ||||||||||
proxyState | Defines which kind of proxy configuration is to be used for this Wi-Fi profile. | ||||||||||
psk | Defines the pre-shared key for an enterprise WLAN network that uses WPA/WPA2-PSK security level. | ||||||||||
security | Defines the security type that is to be used in this Wi-Fi profile. | ||||||||||
ssid | Defines the Wi-Fi network SSID to be created. | ||||||||||
staticGateway | Defines the gateway that is to be used in a statically configured IP settings. | ||||||||||
staticIp | Defines the IP address that is to be used in a statically configured IP settings. | ||||||||||
staticIpEnabled | Defines whether this Wi-Fi profile should use a statically configured IP settings or if it should be dynamically resolved via DHCP protocol. | ||||||||||
staticPrimaryDns | Defines the primary DNS that is to be used in a statically configured IP settings. | ||||||||||
staticSecondaryDns | Defines the secondary DNS that is to be used in a statically configured IP settings. | ||||||||||
staticSubnetMask | Defines the subnet mask that is to be used in a statically configured IP settings. | ||||||||||
userIdentity | Defines the user identity for 802.1x EAP network type. | ||||||||||
wepKey1 | Defines the WEP key 1. | ||||||||||
wepKey2 | Defines the WEP key 2. | ||||||||||
wepKey3 | Defines the WEP key 3. | ||||||||||
wepKey4 | Defines the WEP key 4. | ||||||||||
wepKeyId | Defines the default WEP key index, ranging from 1 to 4. |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
New constructor added to support different keystore engines.
| |||||||||||
New constructor added to support different credential storages.
| |||||||||||
Create a new empty instance.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
API to retrieve the keystore engine set in the profile.
| |||||||||||
API to retrieve the credential storage name set in the profile.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
| |||||||||||
From interface
android.os.Parcelable
|
Engine id to use android keystore for client and CA certificates.
API level 12 |
MDM 5.1 |
Deprecated
in API level 35
NOTE: This engine id is not supported on Android S and newer. Networks already configured
with it will not be affected.
Engine id to use CCM(ClientCertificateManager
) keystore for client certificates.
NOTE: This is only available if
CCM(ClientCertificateManager
) keystore is enforced for the calling administrator.
API level 12 |
MDM 5.1 |
Deprecated
in API level 33
NOTE: This setting is not supported on Android R and newer.
Indicates Phase 1 tunnel establishment method allows authenticated provisioning in an EAP-FAST profile.
API level 19 |
MDM 5.6 |
Deprecated
in API level 33
NOTE: This setting is not supported on Android R and newer.
Indicates Phase 1 tunnel establishment method allows both authenticated and unauthenticated provisioning in an EAP-FAST profile.
API level 19 |
MDM 5.6 |
Deprecated
in API level 33
NOTE: This setting is not supported on Android R and newer.
Indicates Phase 1 tunnel establishment method allows unauthenticated provisioning in an EAP-FAST profile.
API level 19 |
MDM 5.6 |
Deprecated
in API level 33
NOTE: This setting is not supported on Android R and newer.
Indicates Phase 1 tunnel establishment method is disabled in an EAP-FAST profile.
API level 19 |
MDM 5.6 |
Deprecated
in API level 33
NOTE: This setting is not supported on Android R and newer.
Indicates no Phase 1 tunnel establishment method is used in an EAP-FAST profile.
API level 19 |
MDM 5.6 |
Indicates GTC(Generic Token Card Authentication Protocol) inner authentication method will be used by EAP protocol.
API level 19 |
MDM 5.6 |
Indicates MSCHAP(Microsoft Challenge Handshake Authentication Protocol) inner authentication method will be used by EAP protocol.
API level 19 |
MDM 5.6 |
Indicates MSCHAP-V2(Microsoft Challenge Handshake Authentication Protocol Version 2) inner authentication method will be used by EAP protocol.
API level 19 |
MDM 5.6 |
Indicates no inner authentication method will be used by EAP protocol.
API level 19 |
MDM 5.6 |
Indicates PAP(Password Authentication Protocol) inner authentication method will be used by EAP protocol.
API level 19 |
MDM 5.6 |
Flag to indicate that a PAC based proxy is to be used for this Wi-Fi profile.
API level 17 |
MDM 5.5 |
Flag to indicate that a statically configured proxy is to be used for this Wi-Fi profile.
API level 17 |
MDM 5.5 |
Flag to indicate that no proxy is to be used for this Wi-Fi profile.
API level 17 |
MDM 5.5 |
Defines the anonymous identity for 802.1x EAP network type.
An anonymous identity allows the user to hide its true
identity. The user's
actual name appears only inside the encrypted tunnel. Examples of an anonymous identity
include "anonymous", "anon", or "anon@mycompany.net".
API level 2 |
MDM 2.0 |
Defines the Certificate Authority (CA) certificate alias for an enterprise EAP WLAN network.
This certificate is used on authentication process with the server. Applicable only to EAP
security level.
API level 2 |
MDM 2.0 |
Defines the client certificate alias for an enterprise EAP WLAN network type.
This certificate is used on authentication process with the server. Applicable only to EAP
security level.
API level 2 |
MDM 2.0 |
Defines the user password for enterprise WLAN EAP network type.
The password cannot exceed the maximum of 200 characters.
API level 2 |
MDM 2.0 |
Deprecated
in API level 33
NOTE: This setting is not supported on Android R and newer.
Defines the Phase 1 tunnel establishment method in an EAP-FAST profile.
The default value is PHASE1_NONE
representing that no option has been set. Other
supported options are PHASE1_DISABLE
to disable phase 1,
PHASE1_ALLOW_UNAUTHENTICATED
to allow unauthenticated provisioning,
PHASE1_ALLOW_AUTHENTICATED
to allow authenticated provisioning or
PHASE1_ALLOW_BOTH
to allow both unauthenticated and authenticated provisioning. Any
other value different from these will fail the profile creation. This field will be ignored
if used with a network security that does not support the provided Phase 1 method.
API level 17 |
MDM 5.5 |
Defines the Phase 2 authentication method.
Sets the inner authentication used by the EAP protocol. The default value is
PHASE2_NONE
. Other supported methods are PHASE2_PAP
, PHASE2_MSCHAP
, PHASE2_MSCHAPV2
, and PHASE2_GTC
. This field will be ignored if used with
a network security that does not support the provided Phase 2 method.
API level 2 |
MDM 2.0 |
Defines the authentication configuration that shall be used to authenticate in the related
proxy.
This value will be used if either PROXY_STATE_MANUAL
or
PROXY_STATE_AUTO_CONFIGURE
values are set in proxyState
field. However,
this field is not mandatory when setting up a proxy and it will only be used if the
configured proxy supports authentication.
API level 20 |
MDM 5.7 |
Defines a list of URLs that should be bypassed in the proxy configured for this Wi-Fi
profile.
This value will only be used if PROXY_STATE_MANUAL
is set in proxyState
field.
API level 17 |
MDM 5.5 |
Defines the hostname to be used in a statically configured proxy.
This value will only be used if PROXY_STATE_MANUAL
is set in proxyState
field. Such value could be either a regular hostname or an IP address. The hostname must be
in a valid format supported by Android platform, otherwise the profile creation/edition will
fail.
API level 17 |
MDM 5.5 |
Defines the URL that is to be used in a PAC based proxy configuration.
This value will only be used if PROXY_STATE_AUTO_CONFIGURE
is set in
proxyState
field.
API level 17 |
MDM 5.5 |
Defines the port to be used in a statically configured proxy.
This value will only be used if PROXY_STATE_MANUAL
is set in proxyState
field.
API level 17 |
MDM 5.5 |
Defines which kind of proxy configuration is to be used for this Wi-Fi profile.
Possible values are PROXY_STATE_NONE
, PROXY_STATE_MANUAL
or
PROXY_STATE_AUTO_CONFIGURE
.
NOTE: This proxy may not be considered by some applications (e.g. applications that
directly open a socket with the final server), although it is used by most of them.
Applications might retry connections without using the global proxy whenever the proxy is
unreachable or the authentication fails.
API level 17 |
MDM 5.5 |
Defines the pre-shared key for an enterprise WLAN network that uses WPA/WPA2-PSK security
level.
The pre-shared key (PSK) can be a 256-bit hex value or a string value with a minimum of 8 and
a maximum of 64 characters. It is a secret that was previously shared between the two parties
using some secure channel.
API level 2 |
MDM 2.0 |
Defines the security type that is to be used in this Wi-Fi profile.
This field must be a non null
value and the accepted values are "NONE", "WEP",
"PSK", "EAP-x", where x can be any of the following EAP methods: PEAP, TLS, TTLS, PWD, SIM,
AKA, AKA', FAST, LEAP. In order to enable key management options (FT or CCKM), the desired
value should be concatenated with the security level (e.g. EAP-TTLS-FT, EAP-FAST-CCKM). If a
malformed security type is passed or if the device does not support a provided security type,
the Wi-Fi profile creation will fail.
NOTE: From Android P onwards, key management options (FT or CCKM) must no longer be used
in the security level. They are enabled by default if device supports it.
API level 2 |
MDM 2.0 |
Defines the Wi-Fi network SSID to be created.
An SSID is a name that identifies a particular 802.11 wireless LAN. The SSID is
case-sensitive and cannot exceed 32 characters.
API level 2 |
MDM 2.0 |
Defines the gateway that is to be used in a statically configured IP settings.
This value is mandatory if staticIpEnabled
is set to true
. In this
case, if no value is provided, a default gateway (192.168.1.1) will be set.
API level 17 |
MDM 5.5 |
Defines the IP address that is to be used in a statically configured IP settings.
This value is mandatory if staticIpEnabled
is set to true
. In this
case, if no value is provided, a default IP address (192.168.1.100) will be set.
API level 17 |
MDM 5.5 |
Defines whether this Wi-Fi profile should use a statically configured IP settings or if it should be dynamically resolved via DHCP protocol.
API level 17 |
MDM 5.5 |
Defines the primary DNS that is to be used in a statically configured IP settings.
This value is mandatory if staticIpEnabled
is set to true
. In this
case, if no value is provided, a default primary DNS (8.8.8.8) will be set.
API level 17 |
MDM 5.5 |
Defines the secondary DNS that is to be used in a statically configured IP settings.
API level 17 |
MDM 5.5 |
Defines the subnet mask that is to be used in a statically configured IP settings.
This value is mandatory if staticIpEnabled
is set to true
. In this
case, if no value is provided, a default subnet mask (255.255.255.0) will be set.
API level 17 |
MDM 5.5 |
Defines the user identity for 802.1x EAP network type. The identity provided cannot exceed the maximum of 200 characters.
API level 2 |
MDM 2.0 |
Defines the WEP key 1.
This value will only be used when wepKeyId
is 1. The values accepted are either an
ASCII string enclosed in double quotation marks (e.g., "abcdef"
) or a string of hex
digits (e.g., 0102030405
). This field is only applicable to WEP security level.
API level 2 |
MDM 2.0 |
Defines the WEP key 2.
This value will only be used when wepKeyId
is 2. The values accepted are either an
ASCII string enclosed in double quotation marks (e.g., "abcdef"
) or a string of hex
digits (e.g., 0102030405
). This field is only applicable to WEP security level.
API level 2 |
MDM 2.0 |
Defines the WEP key 3.
This value will only be used when wepKeyId
is 3. The values accepted are either an
ASCII string enclosed in double quotation marks (e.g., "abcdef"
) or a string of hex
digits (e.g., 0102030405
). This field is only applicable to WEP security level.
API level 2 |
MDM 2.0 |
Defines the WEP key 4.
This value will only be used when wepKeyId
is 4. The values accepted are either an
ASCII string enclosed in double quotation marks (e.g., "abcdef"
) or a string of hex
digits (e.g., 0102030405
). This field is only applicable to WEP security level.
API level 2 |
MDM 2.0 |
Defines the default WEP key index, ranging from 1 to 4.
When connecting to a WEP security-level network, the default WEP key Id must match the WEP
access point Id and the corresponding WEP key. A WEP key is a security code used on some
Wi-Fi networks. WEP keys allow a group of devices on a local network to exchange encoded
messages with each other while hiding the contents of the messages from easy viewing by
outsiders. Applicable only to the WEP security level.
API level 2 |
MDM 2.0 |
New constructor added to support different keystore engines. Administrator can use this when
the profile must use a different keystore for the specified client certificate.
NOTE: The ENGINE_SECPKCS11
is only available if CCM(ClientCertificateManager
)
keystore
is enforced for the calling administrator.
NOTE: In devices supporting Android UKS (Unified Keystore) the engine ID will default
to ENGINE_ANDROID_KEYSTORE
when ENGINE_SECPKCS11
is selected.
API level 12 |
MDM 5.1 |
New constructor added to support different credential storages. Administrator can use this
when the profile must use a credential storage for client certificates. Passing
null
or empty to storageName
will behave the same as calling
WifiAdminProfile(int)
with ENGINE_ANDROID_KEYSTORE
engine.
Please refer to UCM DEV guide to see how to retrieve storageName
parameter.
NOTE: This constructor is not available since Android 13. Calls to
setWifiProfile(WifiAdminProfile)
will fail when this constructor is used.
Networks already created with it will not connect anymore.
storageName | Credential storage name. |
---|
API level 19 |
MDM 5.6 |
Create a new empty instance.
API level 2 |
MDM 2.0 |
API to retrieve the keystore engine set in the profile.
NOTE: The ENGINE_SECPKCS11
is only available if CCM(ClientCertificateManager
) keystore
is enforced for the calling administrator.
ENGINE_ANDROID_KEYSTORE
or
ENGINE_SECPKCS11
.API level 12 |
MDM 5.1 |
API to retrieve the credential storage name set in the profile.
API level 19 |
MDM 5.6 |