UltraDebug

 找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索
热搜: A C D R G Y M Z X S P
公益项目,接受捐赠
查看: 2264|回复: 0
收起左侧

[移动端口] AOSP Android 10定制su名字隐藏root

[复制链接]
IMG1257

主题

0

回帖

UD

新手上路

UID
49
积分
34
注册时间
2022-5-18
最后登录
1970-1-1
2023-2-21 21:21:33 | 显示全部楼层 |阅读模式

背景

AOSP Android 10定制su名字隐藏root - IMG1257_UltraDebug

哔站,退役debug选手:https://www.bilibili.com/video/BV1yb411X7zX

Android10自定义su文件名字,规避root检查。

环境:

  • vm Ubuntu 18.04
  • AOSP 10_r41分支
  • Pixel 3
  • 目标:修改su为xu,命名可以是其他。

su名字定制和需要修改的文件

需要修改的文件具体路径如下

android-10.0.0_r41\system\extras\su
android-10.0.0_r41\system\extras\xu\Android.mk
android-10.0.0_r41\system\core\libcutils\fs_cofnig.cpp
android-10.0.0_r41\system\sepolicy\private\file_contexts
android-10.0.0_r41\system\sepolicy\prebuilts\api\29.0\private\file_contexts
android-10.0.0_r41\system\sepolicy\prebuilts\api\28.0\private\file_contexts
android-10.0.0_r41\system\sepolicy\prebuilts\api\27.0\private\file_contexts
android-10.0.0_r41\system\sepolicy\prebuilts\api\26.0\private\file_contexts
android-10.0.0_r41\build\make\target\product\base_system.mk

su文件夹

android-10.0.0_r41\system\extras\su
修改
android-10.0.0_r41\system\extras\xu
AOSP Android 10定制su名字隐藏root - IMG1257_UltraDebug

su对应的mk文件

android-10.0.0_r41\system\extras\xu\Android.mk
su修改xu
AOSP Android 10定制su名字隐藏root - IMG1257_UltraDebug

fs_cofnig.cpp

android-10.0.0_r41\system\core\libcutils\fs_cofnig.cpp
su修改xu
AOSP Android 10定制su名字隐藏root - IMG1257_UltraDebug

file_contexts

android-10.0.0_r41\system\sepolicy\private\file_contexts
android-10.0.0_r41\system\sepolicy\prebuilts\api\29.0\private\file_contexts
android-10.0.0_r41\system\sepolicy\prebuilts\api\28.0\private\file_contexts
android-10.0.0_r41\system\sepolicy\prebuilts\api\27.0\private\file_contexts
android-10.0.0_r41\system\sepolicy\prebuilts\api\26.0\private\file_contexts

su修改xu
AOSP Android 10定制su名字隐藏root - IMG1257_UltraDebug

base_system.mk

android-10.0.0_r41\build\make\target\product\base_system.mk
su修改xu
AOSP Android 10定制su名字隐藏root - IMG1257_UltraDebug

编译刷机验证

编译系统

make -j4
adb reboot bootloader
fastboot flashall -w

AOSP Android 10定制su名字隐藏root - IMG1257_UltraDebug

在执行su和xu对比
AOSP Android 10定制su名字隐藏root - IMG1257_UltraDebug

环境检查工具,未修改前:
AOSP Android 10定制su名字隐藏root - IMG1257_UltraDebug

修改之后:
AOSP Android 10定制su名字隐藏root - IMG1257_UltraDebug

参考Android 8的su名字定制:[原创]源码编译(4)——root指纹定制和抹除-Android安全-看雪论坛-安全社区|安全招聘|bbs.pediy.com (kanxue.com)

Android 10的修改和8是有区别的,本文的修改方式可能适合其他高版本系统,如果你验证成功了,记得来告诉我。

UltraDebug免责声明
✅以上内容均来自网友转发或原创,如存在侵权请发送到站方邮件9003554@qq.com处理。
✅The above content is forwarded or original by netizens. If there is infringement, please send the email to the destination 9003554@qq.com handle.
回复 打印

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

小黑屋|Archiver|站点地图|UltraDebug ( 滇ICP备2022002049号-2 滇公网安备 53032102000034号)

GMT+8, 2025-6-21 00:02 , Processed in 0.033837 second(s), 12 queries , Redis On.

Powered by Discuz X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表