HACK: granting full permission for apps data

This commit is contained in:
Rikka
2023-05-27 16:52:55 +08:00
committed by Rikka
parent 72e34c4a38
commit fa9e89e868
6 changed files with 56 additions and 8 deletions
-6
View File
@@ -103,12 +103,6 @@ class General:
def extra2(self):
pass
# def install(self):
# if DBusContainerService().GetSession():
# print("running")
# else:
# print("stopped")
# run("waydroid session start".split())
def install(self):
if container.use_overlayfs():
self.download()
+1
View File
@@ -5,6 +5,7 @@ import re
from stuffs.general import General
from tools.helper import download_file, host, run
from tools.logger import Logger
from tools import container
class Magisk(General):
partition = "system"
+20
View File
@@ -0,0 +1,20 @@
import os
import shutil
from stuffs.general import General
from tools.helper import run
from tools.logger import Logger
class Nodataperm(General):
dl_link = "https://github.com/ayasa520/hack_full_data_permission/archive/refs/heads/main.zip"
dl_file_name = "nodataperm.zip"
extract_to = "/tmp/nodataperm"
act_md5 = "eafd7b0986f3edaebaf1dd89f19d49bf"
partition = "system"
def copy(self):
extract_path = os.path.join(self.extract_to, "hack_full_data_permission-main")
os.chmod(os.path.join(extract_path, "framework", "services.jar"), 0o644)
os.chmod(os.path.join(extract_path, "etc", "nodataperm.sh"), 0o755)
os.chmod(os.path.join(extract_path, "etc", "init", "nodataperm.rc"), 0o755)
Logger.info("Copying widevine library files ...")
shutil.copytree(extract_path, os.path.join(self.copy_dir, self.partition), dirs_exist_ok=True)