經典組合版 - 針對 Android 10 優化
brew install android-platform-tools
curl -s https://api.github.com/repos/topjohnwu/Magisk/releases/latest | grep browser_download_url | grep "\.apk" | cut -d '"' -f 4 | xargs curl -L -o Magisk.apk
Magisk APK: https://github.com/topjohnwu/Magisk/releases/latest
boot.img
boot.img
(選擇 安裝 → 修補 Boot 映像檔)# 重啟到 bootloader 模式
adb reboot bootloader
# 刷入修補後的 boot.img
fastboot flash boot magisk_patched.img
# 重啟設備
fastboot reboot
重開機後打開 Magisk 查看顯示已安裝
⚠️ 安裝順序很重要! 請按照以下順序安裝,每個模組安裝後都要重啟。
#!/bin/bash
# 提示使用者輸入下載路徑
read -p "請輸入下載路徑 (例如 /Users/你的名稱/Desktop/magisk_modules): " DOWNLOAD_DIR
# 檢查使用者是否有輸入
if [ -z "$DOWNLOAD_DIR" ]; then
echo "未輸入下載路徑,腳本已退出。"
exit 1
fi
# 創建下載目錄
mkdir -p "$DOWNLOAD_DIR"
cd "$DOWNLOAD_DIR" || exit 1
# 統一下載函數
download_latest() {
local repo="$1"
local pattern="$2"
local output="$3"
echo "下載 $output..."
url=$(curl -s "https://api.github.com/repos/$repo/releases/latest" \
| grep browser_download_url \
| grep -i "$pattern" \
| cut -d '"' -f 4)
if [ -n "$url" ]; then
curl -L -o "$output" "$url"
else
echo "⚠️ 無法找到 $output 的下載連結"
fi
}
# 下載各模組
download_latest "Dr-TSNG/ZygiskNext" "\.zip" "ZygiskNext.zip"
download_latest "osm0sis/PlayIntegrityFork" "\.zip" "PlayIntegrityFork.zip"
download_latest "5ec1cff/TrickyStore" "\.zip" "TrickyStore.zip"
download_latest "KOWX712/Tricky-Addon-Update-Target-List" "\.zip" "TrickyAddon.zip"
download_latest "LSPosed/LSPosed.github.io" "shamiko.*\.zip" "Shamiko.zip"
download_latest "LSPosed/LSPosed" "zygisk-release\.zip" "LSPosed.zip"
download_latest "Dr-TSNG/Hide-My-Applist" "\.apk" "HideMyApplist.apk"
download_latest "auag0/HideMockLocation" "\.apk" "HideMockLocation_auag0_v1.2.1.apk"
echo "所有模組下載完成!"
ls -la
# 創建手機下載目錄
adb shell mkdir -p /sdcard/Download/magisk_modules
# 推送所有 zip 模組
adb push ZygiskNext.zip /sdcard/Download/magisk_modules/
adb push PlayIntegrityFork.zip /sdcard/Download/magisk_modules/
adb push TrickyStore.zip /sdcard/Download/magisk_modules/
adb push TrickyAddon.zip /sdcard/Download/magisk_modules/
adb push Shamiko.zip /sdcard/Download/magisk_modules/
adb push LSPosed.zip /sdcard/Download/magisk_modules/
# 推送 APK 檔案
adb push HideMyApplist.apk /sdcard/Download/
adb push HideMockLocation_auag0_v1.2.1.apk /sdcard/Download/
# 電腦協助清除(推薦)
adb shell pm clear com.google.android.gms
adb shell pm clear com.android.vending
adb shell pm clear com.google.android.gsf
安裝GPS模擬應用:
# 安裝推薦的 GPS 應用
adb install /sdcard/Download/FakeGPS_Location_GPS_JoyStick.apk
安裝與配置:
# 安裝Shamiko模組
Magisk → 模組 → 從儲存空間安裝 Shamiko.zip → 重啟
配置設定:
# 安裝LSPosed模組
Magisk → 模組 → 從儲存空間安裝 LSPosed.zip → 重啟
# 安裝HMA
adb install /sdcard/Download/HideMyApplist.apk
設定:
# 安裝HML auag0 版本
adb install /sdcard/Download/HideMockLocation_auag0_v1.2.1.apk
設定:
# Magisk自我隱藏
Magisk → 設定 → 隱藏Magisk應用程式
期望結果:
MEETS_BASIC_INTEGRITY = PASS
MEETS_DEVICE_INTEGRITY = PASS
(Android 10 目標)MEETS_STRONG_INTEGRITY = FAIL
(預期,需要硬體 keybox)# 重新生成 fingerprint
adb shell su -c "cd /data/adb/modules/playintegrityfix && rm -f custom.pif.json"
adb shell su -c "cd /data/adb/modules/playintegrityfix && ./autopif2.sh --device"
# 檢查已安裝模組
adb shell su -c "ls -la /data/adb/modules/"
# 檢查 DenyList 狀態
adb shell su -c "magisk --denylist ls"
# 檢查 Play Integrity 日誌
adb shell su -c "logcat | grep -E '(PIF|TrickyStore)'"
本方案針對 Android 10 優化,理論成功率 85%+ 達到 Device Integrity