diff --git a/README.md b/README.md index d6ceec3..edafa41 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,12 @@ # Universal SafetyNet Fix -This is a universal fix for SafetyNet on devices with hardware attestation and unlocked bootloaders. +This is a universal fix for SafetyNet on devices with hardware attestation and unlocked bootloaders. It defeats both hardware attestation and the new SafetyNet ctsProfile updates released on January 12, 2021. The only requirement is that you can pass basic attestation, which requires a valid combination of device and model names, build fingerprints, and security patch levels. Passing basic attestation is out-of-scope for this module. + +No device-specific features (such as the new Pixel-exclusive Google Assistant design or screen-off voice match) will be lost with this fix. MagiskHide is required if the device is rooted. -Only Android 11 is supported. +Only Android 10 and 11 are supported. Heavy OEM skins are not officially supported, but it may work on them depending on your luck and the particular ROM in question. ## How does it work? diff --git a/customize.sh b/customize.sh index 70cce06..74ad3b1 100755 --- a/customize.sh +++ b/customize.sh @@ -1,4 +1,17 @@ #!/sbin/sh +sdk="$(getprop ro.build.version.sdk)" + +if [ "$sdk" -eq 30 ]; then + ui_print "Installing for Android 11" + mv $MODPATH/system_sdk30 $MODPATH/system +elif [ "$sdk" -eq 29 ]; then + ui_print "Installing for Android 10" + mv $MODPATH/system_sdk29 $MODPATH/system +else + ui_print "Android $(getprop ro.vendor.build.version.release) (SDK $sdk) is not supported!" + exit 1 +fi + # Set executable permissions set_perm_recursive $MODPATH/system/bin 0 0 0755 0755 diff --git a/module.prop b/module.prop index 220027b..2490c32 100644 --- a/module.prop +++ b/module.prop @@ -3,5 +3,5 @@ name=Universal SafetyNet Fix version=v1.0.2 versionCode=10002 author=kdrag0n -description=A universal fix for SafetyNet on devices with hardware attestation and unlocked bootloaders. Requires MagiskHide if rooted. For Android 11 only. +description=A universal fix for SafetyNet on devices with hardware attestation and unlocked bootloaders. Requires MagiskHide if rooted. For Android 10 and 11 only. support=https://github.com/kdrag0n/safetynet-fix diff --git a/system_sdk29/bin/keystore b/system_sdk29/bin/keystore new file mode 100755 index 0000000..6622850 Binary files /dev/null and b/system_sdk29/bin/keystore differ diff --git a/system/bin/keystore b/system_sdk30/bin/keystore similarity index 100% rename from system/bin/keystore rename to system_sdk30/bin/keystore diff --git a/system/lib64/libkeystore-attestation-application-id.so b/system_sdk30/lib64/libkeystore-attestation-application-id.so similarity index 100% rename from system/lib64/libkeystore-attestation-application-id.so rename to system_sdk30/lib64/libkeystore-attestation-application-id.so