Disallowing bluetooth config for demo users

Bluetooth is currently not multi-user aware, so bluetooth pairings are
carrying across demo users. Have to disable bluetooth config to prevent
security risks in retail environments.

Bug: 30039481
Change-Id: I28ad0d9585a4e6e22af8772132d585c01b33abc9
This commit is contained in:
Suprabh Shukla
2016-07-12 15:35:37 -07:00
parent ce7ac9a0d2
commit db8c1dbc5e

View File

@@ -328,6 +328,7 @@ public class RetailDemoModeService extends SystemService {
um.setUserRestriction(UserManager.DISALLOW_CONFIG_MOBILE_NETWORKS, true, user);
um.setUserRestriction(UserManager.DISALLOW_USB_FILE_TRANSFER, true, user);
um.setUserRestriction(UserManager.DISALLOW_MODIFY_ACCOUNTS, true, user);
um.setUserRestriction(UserManager.DISALLOW_CONFIG_BLUETOOTH, true, user);
Settings.Secure.putIntForUser(getContext().getContentResolver(),
Settings.Secure.SKIP_FIRST_USE_HINTS, 1, userInfo.id);
Settings.Secure.putIntForUser(getContext().getContentResolver(),