Create 0000fsp via common/install.sh [v0.0.1]
This commit is contained in:
parent
bf105cf5ab
commit
d91f2c85da
@ -1,4 +1,3 @@
|
||||
### v0.0.1 - 10.22.2024
|
||||
* Initial release
|
||||
* Set selinux policies as root using magiskpolicy via sources.sh (runs after OS is mounted)
|
||||
|
||||
* Set selinux policies as root using magiskpolicy via 0000fsp (generated from common/install.sh)
|
||||
|
@ -95,7 +95,7 @@ cp_ch() {
|
||||
|
||||
install_script() {
|
||||
case "$1" in
|
||||
-b) shift;
|
||||
-b) shift;
|
||||
if $KSU; then
|
||||
local INPATH=$NVBASE/boot-completed.d
|
||||
else
|
||||
@ -147,10 +147,10 @@ mount_mirrors() {
|
||||
}
|
||||
|
||||
# Credits
|
||||
#ui_print "**************************************"
|
||||
#ui_print "* MMT Extended by Zackptg5 @ XDA *"
|
||||
#ui_print "**************************************"
|
||||
#ui_print " "
|
||||
ui_print "*******************************************"
|
||||
ui_print "* Module built by 1ndevelopment (©) 2024 *"
|
||||
ui_print "*******************************************"
|
||||
ui_print " "
|
||||
|
||||
# Check for min/max api version
|
||||
[ -z $MINAPI ] || { [ $API -lt $MINAPI ] && abort "! Your system API of $API is less than the minimum api of $MINAPI! Aborting!"; }
|
||||
|
@ -0,0 +1,15 @@
|
||||
cat > $MODPATH/0000fsp <<EOF
|
||||
#!/system/bin/sh
|
||||
## Fix common SELinux non-permissive issues
|
||||
/system/bin/magisk su -c "\$MODPATH/magiskpolicy --live 'allow untrusted_app_27 * * {*}' 'allow system_server * * {*}' 'allow system_suspend * * {*}' 'allow mtk_hal_nvramagent * * {*}' 'allow magisk * * {*}' 'allow system_app * * {*}' 'allow mnld * * {*}' 'allow platform_app * * {*}' 'allow untrusted_app * * {*}' 'allow untrusted_app_29 * * {*}' 'allow priv_app * * {*}' 'allow untrusted_app_30 * * {*}' 'allow untrusted_app_25 * * {*}' 'allow audioserver * * {*}' 'allow crash_dump * * {*}' 'allow su * * {*}' 'allow mediaserver * * {*}' 'allow hwservicemanager * * {*}' 'allow mtk_hal_c2 * * {*}' 'allow surfaceflinger * * {*}' 'allow mediaswcodec * * {*}' 'allow shell * * {*}' 'allow gsid * * {*}'"
|
||||
## Fix SELinux Policies for ArrowOS
|
||||
/system/bin/magisk su -c "\$MODPATH/magiskpolicy --live 'allow surfaceflinger * * {*}' 'allow vold * * {*}' 'allow radio * * {*}' 'allow installd * * {*}' 'allow ccci_mdinit * * {*}' 'allow vendor_init * * {*}' 'allow hal_fingerprint_oppo_compat * * {*}' 'allow init * * {*}' 'allow rild * * {*}' 'allow bip * * {*}' 'allow gsm0710muxd * * {*}' 'allow phhsu_daemon * * {*}' 'allow isolated_app * * {*}'"
|
||||
EOF
|
||||
|
||||
ui_print "- FSP boot script created"
|
||||
|
||||
install_script -p $MODPATH/0000fsp
|
||||
install_script -l $MODPATH/0000fsp
|
||||
|
||||
ui_print "- FSP boot script copied necessary places"
|
||||
ui_print "- Continuing to install"
|
@ -42,7 +42,7 @@
|
||||
# Permissions
|
||||
##########################################################################################
|
||||
|
||||
# set_permissions() {
|
||||
set_permissions() {
|
||||
# Note that all files/folders in magisk module directory have the $MODPATH prefix - keep this prefix on all of your files/folders
|
||||
# Some examples:
|
||||
|
||||
@ -57,7 +57,8 @@
|
||||
|
||||
# set_perm $MODPATH/system/lib/libart.so 0 0 0644
|
||||
# set_perm /data/local/tmp/file.txt 0 0 644
|
||||
#}
|
||||
set_perm_recursive $MODPATH/0000fsp 0 0 0775 0775
|
||||
}
|
||||
|
||||
ui_print ""
|
||||
ui_print "Fix SELinux Permissions [FSP] Installer"
|
||||
|
Binary file not shown.
@ -1,9 +0,0 @@
|
||||
#!/system/bin/sh
|
||||
|
||||
MODDIR=${0%/*}
|
||||
|
||||
## Fix common SELinux non-permissive issues
|
||||
/system/bin/magisk su -c "/system/bin/magiskpolicy --live 'allow untrusted_app_27 * * {*}' 'allow system_server * * {*}' 'allow system_suspend * * {*}' 'allow mtk_hal_nvramagent * * {*}' 'allow magisk * * {*}' 'allow system_app * * {*}' 'allow mnld * * {*}' 'allow platform_app * * {*}' 'allow untrusted_app * * {*}' 'allow untrusted_app_29 * * {*}' 'allow priv_app * * {*}' 'allow untrusted_app_30 * * {*}' 'allow untrusted_app_25 * * {*}' 'allow audioserver * * {*}' 'allow crash_dump * * {*}' 'allow su * * {*}' 'allow mediaserver * * {*}' 'allow hwservicemanager * * {*}' 'allow mtk_hal_c2 * * {*}' 'allow surfaceflinger * * {*}' 'allow mediaswcodec * * {*}' 'allow shell * * {*}' 'allow gsid * * {*}'"
|
||||
|
||||
## Fix SELinux Policies for ArrowOS
|
||||
/system/bin/magisk su -c "$MODPATH/magiskpolicy --live 'allow surfaceflinger * * {*}' 'allow vold * * {*}' 'allow radio * * {*}' 'allow installd * * {*}' 'allow ccci_mdinit * * {*}' 'allow vendor_init * * {*}' 'allow hal_fingerprint_oppo_compat * * {*}' 'allow init * * {*}' 'allow rild * * {*}' 'allow bip * * {*}' 'allow gsm0710muxd * * {*}' 'allow phhsu_daemon * * {*}' 'allow isolated_app * * {*}'"
|
@ -1,3 +1,6 @@
|
||||
rm -f /data/adb/post-fs-data.d/0000fsp
|
||||
rm -f /data/adb/service.d/0000fsp
|
||||
|
||||
# Don't modify anything after this
|
||||
if [ -f $INFO ]; then
|
||||
while read LINE; do
|
||||
@ -14,4 +17,4 @@ if [ -f $INFO ]; then
|
||||
fi
|
||||
done < $INFO
|
||||
rm -f $INFO
|
||||
fi
|
||||
fi
|
||||
|
@ -1,6 +1,6 @@
|
||||
{
|
||||
"version": "v0.0.1",
|
||||
"versionCode": 1,
|
||||
"zipUrl": "https://git.1ndev.com/1ndevelopment/fsp_module/main/src.zip",
|
||||
"zipUrl": "https://git.1ndev.com/1ndevelopment/fsp_module/main/fsp_module-v0.0.1-src.zip",
|
||||
"changelog": "https://git.1ndev.com/1ndevelopment/fsp_module/main/changelog.md"
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user