Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8972dc26 authored by LuK1337's avatar LuK1337
Browse files

adb: Add ro.adb.secure.recovery handling

Change-Id: I9c68b70381c10fbec17363f4b0392c032d22dbe8
parent b4c66647
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -208,6 +208,10 @@ int adbd_main(int server_port) {
#if defined(ALLOW_ADBD_NO_AUTH)
    // If ro.adb.secure is unset, default to no authentication required.
    auth_required = android::base::GetBoolProperty("ro.adb.secure", false);
#if defined(__ANDROID_RECOVERY__)
    auth_required = auth_required &&
                    android::base::GetBoolProperty("ro.adb.secure.recovery", true);
#endif
#elif defined(__ANDROID__)
    if (is_device_unlocked()) {  // allows no authentication when the device is unlocked.
        auth_required = android::base::GetBoolProperty("ro.adb.secure", false);