Merge changes Iccf50955,I17ab54dd
* changes: Stop checking StorageManager.inCryptKeeperBounce() in BootReceiver Stop checking StorageManager.inCryptKeeperBounce() in DPM
This commit is contained in:
@@ -31,7 +31,6 @@ import android.os.RecoverySystem;
|
||||
import android.os.RemoteException;
|
||||
import android.os.ServiceManager;
|
||||
import android.os.SystemProperties;
|
||||
import android.os.storage.StorageManager;
|
||||
import android.provider.Downloads;
|
||||
import android.system.ErrnoException;
|
||||
import android.system.Os;
|
||||
@@ -281,14 +280,8 @@ public class BootReceiver extends BroadcastReceiver {
|
||||
HashMap<String, Long> timestamps = readTimestamps();
|
||||
|
||||
if (SystemProperties.getLong("ro.runtime.firstboot", 0) == 0) {
|
||||
if (StorageManager.inCryptKeeperBounce()) {
|
||||
// Encrypted, first boot to get PIN/pattern/password so data is tmpfs
|
||||
// Don't set ro.runtime.firstboot so that we will do this again
|
||||
// when data is properly mounted
|
||||
} else {
|
||||
String now = Long.toString(System.currentTimeMillis());
|
||||
SystemProperties.set("ro.runtime.firstboot", now);
|
||||
}
|
||||
String now = Long.toString(System.currentTimeMillis());
|
||||
SystemProperties.set("ro.runtime.firstboot", now);
|
||||
if (db != null) db.addText("SYSTEM_BOOT", headers);
|
||||
|
||||
// Negative sizes mean to take the *tail* of the file (see FileUtils.readTextFile())
|
||||
|
||||
@@ -30,7 +30,6 @@ import android.content.res.Resources;
|
||||
import android.os.Handler;
|
||||
import android.os.RemoteException;
|
||||
import android.os.UserHandle;
|
||||
import android.os.storage.StorageManager;
|
||||
import android.provider.Settings;
|
||||
import android.security.Credentials;
|
||||
import android.security.KeyChain;
|
||||
@@ -129,9 +128,6 @@ public class CertificateMonitor {
|
||||
private final BroadcastReceiver mRootCaReceiver = new BroadcastReceiver() {
|
||||
@Override
|
||||
public void onReceive(Context context, Intent intent) {
|
||||
if (StorageManager.inCryptKeeperBounce()) {
|
||||
return;
|
||||
}
|
||||
final int userId = intent.getIntExtra(Intent.EXTRA_USER_HANDLE, getSendingUserId());
|
||||
updateInstalledCertificates(UserHandle.of(userId));
|
||||
}
|
||||
|
||||
@@ -2295,11 +2295,6 @@ public class DevicePolicyManagerService extends BaseIDevicePolicyManager {
|
||||
}
|
||||
|
||||
private void setDeviceOwnershipSystemPropertyLocked() {
|
||||
// Still at the first stage of CryptKeeper double bounce, nothing can be learnt about
|
||||
// the real system at this point.
|
||||
if (StorageManager.inCryptKeeperBounce()) {
|
||||
return;
|
||||
}
|
||||
final boolean deviceProvisioned =
|
||||
mInjector.settingsGlobalGetInt(Settings.Global.DEVICE_PROVISIONED, 0) != 0;
|
||||
final boolean hasDeviceOwner = mOwners.hasDeviceOwner();
|
||||
|
||||
Reference in New Issue
Block a user