2
0
mirror of https://gitlab.com/Nanolx/NanoDroid synced 2024-10-31 09:20:23 +00:00

add org.spoofing

This commit is contained in:
Christopher Roy Bratusek 2019-04-12 19:39:06 +02:00
parent e5f5a0f9a7
commit fbe5674388
4 changed files with 19 additions and 18 deletions

View File

@ -20,6 +20,8 @@
* Patcher * Patcher
* support installing patched services.jar into Magisk 19.0+ modules * support installing patched services.jar into Magisk 19.0+ modules
* install org.spoofing system pseudo-app after patching @Vavun
* this is adds ROM wide *cosmetic* information about Signature Spoofing (so it shows up in the App Permissions)
* Uninstaller * Uninstaller
* support uninstalling Magisk 19.0+ modules * support uninstalling Magisk 19.0+ modules

View File

@ -250,8 +250,6 @@ detect_arch () {
detect_sdk () { detect_sdk () {
SDK_VERSION=$(grep_prop ro.build.version.sdk) SDK_VERSION=$(grep_prop ro.build.version.sdk)
[ "${SDK_VERSION}" -gt 28 ] && \ [ "${SDK_VERSION}" -gt 28 ] && \
error "Android versions beyond Pie are not yet supported" error "Android versions beyond Pie are not yet supported"
@ -408,20 +406,20 @@ call_dalvikvm () {
deodex_vdex () { deodex_vdex () {
ui_print " >> deodexing services.jar [VDEX]" ui_print " >> deodexing services.jar [VDEX]"
cp /system/framework/oat/${ARCH}/services.vdex \ cp /system/framework/oat/${ARCH}/services.vdex \
${BASEDIR}/services.vdex || \ ${BASEDIR}/services.vdex || \
error "failed to copy services.vdex" error "failed to copy services.vdex"
${V_EX} -i ${BASEDIR}/services.vdex \
--ignore-crc-error --debug=4 || \
error "failed to deodex services.vdex"
mv ${BASEDIR}/services.apk_classes.dex ${BASEDIR}/classes.dex || \
error "failed to deodex services.vdex"
${ZIPB} -j "${BASEDIR}/services.jar" \ ${V_EX} -i ${BASEDIR}/services.vdex \
"${BASEDIR}/classes.dex" || \ --ignore-crc-error --debug=4 || \
error "zip failed" error "failed to deodex services.vdex"
mv ${BASEDIR}/services.apk_classes.dex ${BASEDIR}/classes.dex || \
error "failed to deodex services.vdex"
${ZIPB} -j "${BASEDIR}/services.jar" \
"${BASEDIR}/classes.dex" || \
error "zip failed"
} }
deodex_odex () { deodex_odex () {
@ -540,9 +538,11 @@ install_services () {
ui_print " << installing patched files to: ${install_path}" ui_print " << installing patched files to: ${install_path}"
mkdir -p "${install_path}/system/framework" mkdir -p "${install_path}/system/framework"
cp ${BASEDIR}/services.jar "${install_path}/system/framework" \ cp ${BASEDIR}/services.jar "${install_path}/system/framework/" \
|| error "failed to install services.jar" || error "failed to install services.jar"
cp "${BASEDIR}/org.spoofing.apk" "${install_path}/system/framework/"
touch /data/adb/NanoDroid_Patched touch /data/adb/NanoDroid_Patched
} }
@ -567,7 +567,7 @@ install_addond () {
hook_4.1-6.0_services.jar.dex hook_7.0-9.0_services.jar.dex \ hook_4.1-6.0_services.jar.dex hook_7.0-9.0_services.jar.dex \
baksmali_23.dex baksmali_25.dex baksmali_26.dex \ baksmali_23.dex baksmali_25.dex baksmali_26.dex \
smali_23.dex smali_25.dex smali_26.dex \ smali_23.dex smali_25.dex smali_26.dex \
magic.mgc; do magic.mgc org.spoofing.apk; do
cp "${BASEDIR}/${file}" ${PATCHER_ADDOND_DATA}/ cp "${BASEDIR}/${file}" ${PATCHER_ADDOND_DATA}/
done done

View File

@ -118,4 +118,3 @@ case "${1}" in
NanoDroidPatcher NanoDroidPatcher
;; ;;
esac esac

Binary file not shown.