Skip to content

manager: Prevent module installation via external sources in safe mode#3079

Merged
aviraxp merged 4 commits into
tiann:mainfrom
sakana164:fix-safetymode
Dec 21, 2025
Merged

manager: Prevent module installation via external sources in safe mode#3079
aviraxp merged 4 commits into
tiann:mainfrom
sakana164:fix-safetymode

Conversation

@sakana164

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR aims to prevent module installation via external sources (e.g., file managers) when KernelSU is in safe mode, adding a safety mechanism to protect the system.

  • Added localized string resources for safe mode module installation warning (English and Chinese)
  • Modified ZIP file intent handler to check for safe mode and display appropriate warning dialog
  • Attempted to override dialog behavior to prevent installation in safe mode

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
manager/app/src/main/res/values/strings.xml Added English string resource for safe mode module installation disabled message
manager/app/src/main/res/values-zh-rCN/strings.xml Added Chinese translation for safe mode module installation disabled message
manager/app/src/main/java/me/weishu/kernelsu/ui/MainActivity.kt Added safe mode check in ZIP file intent handler to prevent module installation, but contains a critical implementation bug

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread manager/app/src/main/java/me/weishu/kernelsu/ui/MainActivity.kt Outdated
@sakana164 sakana164 marked this pull request as draft December 20, 2025 09:12
@sakana164 sakana164 marked this pull request as ready for review December 20, 2025 09:12

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread manager/app/src/main/java/me/weishu/kernelsu/ui/MainActivity.kt Outdated
Replaced safe mode dialog with a Toast message for warnings.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread manager/app/src/main/java/me/weishu/kernelsu/ui/MainActivity.kt Outdated
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@aviraxp aviraxp merged commit 1b7700c into tiann:main Dec 21, 2025
KOWX712 pushed a commit to KOWX712/KernelSU that referenced this pull request Dec 21, 2025
tiann#3079)

Signed-off-by: sakana164 <76257039+sakana164@users.noreply.github.com>

---------

Co-authored-by: Wang Han <416810799@qq.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@sakana164 sakana164 deleted the fix-safetymode branch December 21, 2025 16:15
rsuntk pushed a commit to rsuntk/KernelSU that referenced this pull request Dec 21, 2025
tiann#3079)

Signed-off-by: sakana164 <76257039+sakana164@users.noreply.github.com>

---------

Co-authored-by: Wang Han <416810799@qq.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
bklynali pushed a commit to bklynali/BK-KSU that referenced this pull request Dec 23, 2025
tiann#3079)

Signed-off-by: sakana164 <76257039+sakana164@users.noreply.github.com>

---------

Co-authored-by: Wang Han <416810799@qq.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
u9521 pushed a commit to u9521/KernelSU that referenced this pull request Jan 5, 2026
tiann#3079)

Signed-off-by: sakana164 <76257039+sakana164@users.noreply.github.com>

---------

Co-authored-by: Wang Han <416810799@qq.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
u9521 pushed a commit to u9521/KernelSU that referenced this pull request Jan 5, 2026
tiann#3079)

Signed-off-by: sakana164 <76257039+sakana164@users.noreply.github.com>

---------

Co-authored-by: Wang Han <416810799@qq.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
u9521 pushed a commit to u9521/KernelSU that referenced this pull request Jan 8, 2026
tiann#3079)

Signed-off-by: sakana164 <76257039+sakana164@users.noreply.github.com>

---------

Co-authored-by: Wang Han <416810799@qq.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
u9521 pushed a commit to u9521/KernelSU that referenced this pull request Jan 13, 2026
tiann#3079)

Signed-off-by: sakana164 <76257039+sakana164@users.noreply.github.com>

---------

Co-authored-by: Wang Han <416810799@qq.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants