You've already forked PlayIntegrityFork
mirror of
https://github.com/osm0sis/PlayIntegrityFork.git
synced 2025-09-06 06:37:06 +00:00
Use custom function to hack props without increasing prop change counter
- some apps were detecting tampered props from the increased prop_info serial counter using resetprop - patching doesn't rely on magiskboot hexpatch so should work on KernelSU and APatch as well - hopefully temporary until all root solutions adopt a patched system_properties repo to fix counters via resetprop
This commit is contained in:
@@ -1,20 +1,8 @@
|
||||
MODDIR="${0%/*}"
|
||||
. "$MODDIR/common.sh"
|
||||
|
||||
# Conditional sensitive properties
|
||||
|
||||
resetprop_if_diff() {
|
||||
local NAME=$1
|
||||
local EXPECTED=$2
|
||||
local CURRENT=$(resetprop $NAME)
|
||||
|
||||
[ -z "$CURRENT" ] || [ "$CURRENT" == "$EXPECTED" ] || resetprop $NAME $EXPECTED
|
||||
}
|
||||
resetprop_if_match() {
|
||||
local NAME=$1
|
||||
local CONTAINS=$2
|
||||
local VALUE=$3
|
||||
|
||||
[[ "$(resetprop $NAME)" == *"$CONTAINS"* ]] && resetprop $NAME $VALUE
|
||||
}
|
||||
|
||||
# Magisk recovery mode
|
||||
resetprop_if_match ro.bootmode recovery unknown
|
||||
resetprop_if_match ro.boot.mode recovery unknown
|
||||
|
||||
Reference in New Issue
Block a user