Loading core/java/com/android/internal/widget/LockPatternUtils.java +3 −3 Original line number Diff line number Diff line Loading @@ -680,7 +680,7 @@ public class LockPatternUtils { */ public boolean setLockCredential(@NonNull LockscreenCredential newCredential, @NonNull LockscreenCredential savedCredential, int userHandle) { if (!hasSecureLockScreen()) { if (!hasSecureLockScreen() && newCredential.getType() != CREDENTIAL_TYPE_NONE) { throw new UnsupportedOperationException( "This operation requires the lock screen feature."); } Loading Loading @@ -775,7 +775,7 @@ public class LockPatternUtils { /** Update the encryption password if it is enabled **/ private void updateEncryptionPassword(final int type, final byte[] password) { if (!hasSecureLockScreen()) { if (!hasSecureLockScreen() && password != null && password.length != 0) { throw new UnsupportedOperationException( "This operation requires the lock screen feature."); } Loading Loading @@ -1575,7 +1575,7 @@ public class LockPatternUtils { */ public boolean setLockCredentialWithToken(@NonNull LockscreenCredential credential, long tokenHandle, byte[] token, int userHandle) { if (!hasSecureLockScreen()) { if (!hasSecureLockScreen() && credential.getType() != CREDENTIAL_TYPE_NONE) { throw new UnsupportedOperationException( "This operation requires the lock screen feature."); } Loading services/core/java/com/android/server/locksettings/LockSettingsService.java +7 −3 Original line number Diff line number Diff line Loading @@ -1090,7 +1090,9 @@ public class LockSettingsService extends ILockSettings.Stub { public void setSeparateProfileChallengeEnabled(int userId, boolean enabled, LockscreenCredential managedUserPassword) { checkWritePermission(userId); if (!mHasSecureLockScreen) { if (!mHasSecureLockScreen && managedUserPassword != null && managedUserPassword.getType() != CREDENTIAL_TYPE_NONE) { throw new UnsupportedOperationException( "This operation requires secure lock screen feature."); } Loading Loading @@ -1560,7 +1562,8 @@ public class LockSettingsService extends ILockSettings.Stub { public boolean setLockCredential(LockscreenCredential credential, LockscreenCredential savedCredential, int userId) { if (!mHasSecureLockScreen) { if (!mHasSecureLockScreen && credential != null && credential.getType() != CREDENTIAL_TYPE_NONE) { throw new UnsupportedOperationException( "This operation requires secure lock screen feature"); } Loading Loading @@ -3423,7 +3426,8 @@ public class LockSettingsService extends ILockSettings.Stub { @Override public boolean setLockCredentialWithToken(LockscreenCredential credential, long tokenHandle, byte[] token, int userId) { if (!mHasSecureLockScreen) { if (!mHasSecureLockScreen && credential != null && credential.getType() != CREDENTIAL_TYPE_NONE) { throw new UnsupportedOperationException( "This operation requires secure lock screen feature."); } Loading Loading
core/java/com/android/internal/widget/LockPatternUtils.java +3 −3 Original line number Diff line number Diff line Loading @@ -680,7 +680,7 @@ public class LockPatternUtils { */ public boolean setLockCredential(@NonNull LockscreenCredential newCredential, @NonNull LockscreenCredential savedCredential, int userHandle) { if (!hasSecureLockScreen()) { if (!hasSecureLockScreen() && newCredential.getType() != CREDENTIAL_TYPE_NONE) { throw new UnsupportedOperationException( "This operation requires the lock screen feature."); } Loading Loading @@ -775,7 +775,7 @@ public class LockPatternUtils { /** Update the encryption password if it is enabled **/ private void updateEncryptionPassword(final int type, final byte[] password) { if (!hasSecureLockScreen()) { if (!hasSecureLockScreen() && password != null && password.length != 0) { throw new UnsupportedOperationException( "This operation requires the lock screen feature."); } Loading Loading @@ -1575,7 +1575,7 @@ public class LockPatternUtils { */ public boolean setLockCredentialWithToken(@NonNull LockscreenCredential credential, long tokenHandle, byte[] token, int userHandle) { if (!hasSecureLockScreen()) { if (!hasSecureLockScreen() && credential.getType() != CREDENTIAL_TYPE_NONE) { throw new UnsupportedOperationException( "This operation requires the lock screen feature."); } Loading
services/core/java/com/android/server/locksettings/LockSettingsService.java +7 −3 Original line number Diff line number Diff line Loading @@ -1090,7 +1090,9 @@ public class LockSettingsService extends ILockSettings.Stub { public void setSeparateProfileChallengeEnabled(int userId, boolean enabled, LockscreenCredential managedUserPassword) { checkWritePermission(userId); if (!mHasSecureLockScreen) { if (!mHasSecureLockScreen && managedUserPassword != null && managedUserPassword.getType() != CREDENTIAL_TYPE_NONE) { throw new UnsupportedOperationException( "This operation requires secure lock screen feature."); } Loading Loading @@ -1560,7 +1562,8 @@ public class LockSettingsService extends ILockSettings.Stub { public boolean setLockCredential(LockscreenCredential credential, LockscreenCredential savedCredential, int userId) { if (!mHasSecureLockScreen) { if (!mHasSecureLockScreen && credential != null && credential.getType() != CREDENTIAL_TYPE_NONE) { throw new UnsupportedOperationException( "This operation requires secure lock screen feature"); } Loading Loading @@ -3423,7 +3426,8 @@ public class LockSettingsService extends ILockSettings.Stub { @Override public boolean setLockCredentialWithToken(LockscreenCredential credential, long tokenHandle, byte[] token, int userId) { if (!mHasSecureLockScreen) { if (!mHasSecureLockScreen && credential != null && credential.getType() != CREDENTIAL_TYPE_NONE) { throw new UnsupportedOperationException( "This operation requires secure lock screen feature."); } Loading