Android绕过设置屏幕技术解析 - 三星/LG设备FRP与激活锁解除指南

本文详细介绍了通过ADB命令绕过三星/LG安卓设备初始设置屏幕的技术方案,包含FRP锁与重新激活锁的清除方法,提供完整的Bash脚本实现与原理说明。

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
#! /bin/bash

# ---------------------------------------------------------------------------------
#   Android - 绕过设置屏幕 - 三星/LG设备FRP与重新激活锁清除方案
# ---------------------------------------------------------------------------------

source $HOME/The_Drive/bash_profile/dev/scripts/sleeping.sh

RED='\033[0;31m'
PURPLE='\033[0;35m'
YELLOW='\033[1;33m'
CYAN='\033[1;36m'
NC='\033[0m' # 无颜色

ios_rd_software_version=$(echo "RC-1c")

# 间隔函数定义
space(){ echo "" }
double_space(){ echo ""; echo "" }

# 工具标题展示
printf "\n${PURPLE}#################################################################################################################${NC}"
printf "\n${PURPLE}--------------------------------------AOS解锁工具--------------------------------------------------------${NC}"
printf "\n${PURPLE}-----------------------------------------------------------------------------------------------------------------${NC}"
printf "\n${PURPLE}--------------------------------------版本: ${ios_rd_software_version}----------------------------------------${NC}"
printf "\n${PURPLE}--------------------------------------本工具将绕过Android设备的------------------------------------${NC}"
printf "\n${PURPLE}--------------------------------------三星或LG初始设置界面-----------------------------------------------${NC}"
printf "\n${PURPLE}--------------------------------------同时可移除FRP锁或重新激活锁设备----------------------${NC}"
printf "\n${PURPLE}#################################################################################################################${NC}"

# 核心ADB命令执行
printf "\n${PURPLE}[INFO] 如出现RSA提示请接受${NC}\n"
adb wait-for-device shell getprop | grep -o 'ro.adb.secure' | sed 's/ro.adb.secure/ADB已授权/'

double_space

printf "\n${PURPLE}[INFO][+]${NC} 发送命令: adb shell svc power stayon true"
printf "\n${PURPLE}[INFO][+]${NC} 此命令用于保持屏幕常亮"
adb shell svc power stayon true

printf "\n${PURPLE}[INFO][+]${NC} 发送命令: adb shell settings put secure user_setup_complete 1"
adb shell settings put secure user_setup_complete 1

printf "\n${PURPLE}[INFO][+]${NC} 发送命令: adb shell settings put system setup_wizard_has_run 1"
adb shell settings put global setup_wizard_has_run 1

# 三星特定清除
printf "\n${PURPLE}[INFO][+]${NC} 发送命令: adb shell pm clear com.samsung.klmsagent"
printf "\n${PURPLE}[INFO][+]${NC} 此操作针对三星设备"
adb shell pm clear com.samsung.klmsagent

printf "\n${PURPLE}[INFO][+]${NC} 发送命令: adb shell pm clear com.sec.android.app.SecSetupWizard"
adb shell pm clear com.sec.android.app.SecSetupWizard
adb shell pm clear com.google.android.setupwizard

# LG特定清除
printf "\n${PURPLE}[INFO][+]${NC} 发送命令: adb shell pm clear com.android.LGSetupWizard"
adb shell pm clear com.android.LGSetupWizard

# 返回主界面
printf "\n${PURPLE}[INFO][+]${NC} 发送命令: adb shell monkey -c android.intent.category.HOME 1"
adb shell monkey -c android.intent.category.HOME 1 &>/dev/null

printf "\n${PURPLE}[INFO][+]${NC} 请等待设备设置绕过过程完成"
space

# 技术原理注释
# 参考Android开发者文档:
# https://developer.android.com/reference/android/provider/Settings.Secure.html
# https://developer.android.com/reference/android/provider/Settings.System.html
# https://developer.android.com/reference/android/provider/Settings.Global.html
comments powered by Disqus
使用 Hugo 构建
主题 StackJimmy 设计