Since: API level 34
public static class

KnoxContract.Config.Wifi

extends Object
java.lang.Object
   ↳ com.samsung.android.knox.ex.KnoxContract.Config.Wifi

Deprecated in API level 36
NOTE: This Class is not available since Android 13.

Class Overview

This class provides to set wifi configuration


Specific Policy

Summary

Constants
String CONTENT_URI_STRING
String ID
String KEY_WIFI_SSIDS_BLOCK_LIST
String PARAM_WIFI_SSIDS_BLOCK_LIST Deprecated in API level 36
NOTE: This API is not available since Android 13.
Public Constructors
Wifi()
[Expand]
Inherited Methods
From class java.lang.Object

Constants

public static final String CONTENT_URI_STRING

Since: API level 34

Constant Value: "content://com.samsung.android.knox.sdk/config/wifi"

public static final String ID

Since: API level 34

Constant Value: "wifi"

public static final String KEY_WIFI_SSIDS_BLOCK_LIST

Since: API level 34

Constant Value: "wifi-ssid-block-list"

public static final String PARAM_WIFI_SSIDS_BLOCK_LIST

Since: API level 34

Deprecated in API level 36
NOTE: This API is not available since Android 13.

API to add Wi-Fi network service set identifiers (SSIDs) to the Wi-Fi network block list


    Param

Usage
 Uri uri = Uri.parse("content://com.samsung.android.knox.sdk/config/wifi");
 ContentValues contentValues = new ContentValues();
 contentValues.put("wifi-ssid-block-list", "your_ssid");
 String selection = "key=?";
 String[] selectionArgs = new String[] {"wifi-ssid-block-list"};
 mContext.getContentResolver().update(uri, contentValues, selection, selectionArgs);

 Uri uri = Uri.parse("content://com.samsung.android.knox.sdk/config/wifi");
 String selection = "key=?";
 String[] selectionArgs = new String[] {"wifi-ssid-block-list"};
 Cursor cursor = mContext.getContentResolver().query(uri, null, selection, selectionArgs, null);
 ArrayList<String> blockList = new ArrayList<>();
 if (cursor != null) {
     cursor.moveToFirst();
     do {
         blockList.add(cursor.getString(0));
     } while (cursor.moveToNext());
 }

 Uri uri = Uri.parse("content://com.samsung.android.knox.sdk/config/wifi");
 String selection = "key=?";
 String[] selectionArgs = new String[] {"wifi-ssid-block-list"};
 mContext.getContentResolver().delete(uri, selection, selectionArgs);
 
Since
API level 34
Knox 3.7.1
Permission
The use of this feature requires the caller to have the "com.samsung.android.knox.permission.KNOX_NDA_DEVICE_SETTINGS_RT" permission.
Constant Value: "wifi-ssid-block-list"

Public Constructors

public Wifi ()

Since: API level 34