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

Commit 29423918 authored by Kenny Root's avatar Kenny Root
Browse files

Fix regression in OBB key handling

Change-Id: If583cbdb8be68ffed094a5fde7ee00e1914c5841
parent 0a69f597
Loading
Loading
Loading
Loading
+14 −15
Original line number Diff line number Diff line
@@ -1599,6 +1599,8 @@ class MountService extends IMountService.Stub
            addObbState(obbState);
        }

        String hashedKey = null;
        if (key != null) {
            final MessageDigest md;
            try {
                md = MessageDigest.getInstance("MD5");
@@ -1612,7 +1614,8 @@ class MountService extends IMountService.Stub
                return;
            }

        String hashedKey = HexDump.toHexString(md.digest(key.getBytes()));
            hashedKey = HexDump.toHexString(md.digest(key.getBytes()));
        }

        ObbAction action = new MountObbAction(obbState, hashedKey);
        mObbActionHandler.sendMessage(mObbActionHandler.obtainMessage(OBB_RUN_ACTION, action));
@@ -1956,10 +1959,6 @@ class MountService extends IMountService.Stub
                throw new IllegalArgumentException("Caller package does not match OBB file");
            }

            if (mKey == null) {
                mKey = "none";
            }

            boolean mounted = false;
            int rc;
            synchronized (mObbState) {