Skip to content

11416

Choose a tag to compare

@github-actions github-actions released this 19 Sep 14:24
· 9 commits to main since this release

A fix for a manager that has lost root and cannot get it back.

What was happening

The report came in as "the manager lost root". It had not. The privileged process the manager starts was aborting before it could run, and the device's own log held the reason:

SecurityException: Writable dex file
  '/data/user_de/0/me.yuki.aster/cache/main.jar' is not allowed
  at dalvik.system.DexFile.openDexFileNative
  at java.lang.ClassLoader.createSystemClassLoader

Three attempts, three aborts, and nothing on screen to say why. The same device had killed the root process of the other manager installed on it the day before, in the same place.

Why it does not go away on its own

The file only has to be written once with a mode the platform refuses. Writing it again truncates it and leaves the mode alone — so the state survives every restart, every update, and a reinstall of the manager on top of the old one.

What changed

  • The file the root process is made of is looked at before anything asks for a root service, in both caches, because which one it was put in is not something this app controls.
  • On the first launch of this version it is removed whatever it looks like — a bad one left by an older install cannot be told from a good one by inspection. After that, only a file that is writable by group or other, unreadable by its owner, or not this app's is replaced.
  • Its mode goes to the log every time it is looked at. That is the one fact a report of this needs, and nothing else in the app recorded it.

If you are affected

Installing this version is enough: the first launch replaces the file. Clearing the manager's app cache does the same thing by hand, if you would rather not wait for it.

Full changelog

11415...11416