Skip to content

Conversation

@jvsena42
Copy link
Member

@jvsena42 jvsena42 commented Jan 8, 2026

Description

This PR blocks screenshot and recording of sensitive data if the app is not in debug mode

Preview

Screen_recording_20260108_105035.mp4
Screen_recording_20260108_110750.webm

QA Notes

  • Use a physical device, emulators can bypass FLAG_SECURE
  • Build in release mode or comment if (Env.isDebug) return

@jvsena42 jvsena42 requested review from Copilot and ovitrif January 8, 2026 14:12
@jvsena42 jvsena42 self-assigned this Jan 8, 2026
Copy link
Contributor

Copilot AI left a comment

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 implements screenshot and screen recording blocking for sensitive screens containing wallet recovery information (mnemonics and passphrases). The feature only applies to release builds, allowing screenshots during development and testing.

Key Changes:

  • Created a reusable BlockScreenshots composable that leverages Android's FLAG_SECURE and setRecentsScreenshotEnabled APIs
  • Applied screenshot blocking to 8 screens handling sensitive wallet data
  • Added debug mode bypass to facilitate testing

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
BlockScreenshots.kt New composable effect that blocks screenshots and screen recording using Android security flags
ShowPassphraseScreen.kt Applied screenshot blocking to passphrase display screen
ShowMnemonicScreen.kt Applied screenshot blocking to mnemonic display screen
ConfirmPassphraseScreen.kt Applied screenshot blocking to passphrase confirmation screen
ConfirmMnemonicScreen.kt Applied screenshot blocking to mnemonic confirmation screen
RecoveryMnemonicScreen.kt Applied screenshot blocking to recovery mnemonic screen
RestoreWalletScreen.kt Applied screenshot blocking to wallet restoration screen
CreateWalletWithPassphraseScreen.kt Applied screenshot blocking to wallet creation with passphrase screen

ovitrif
ovitrif previously approved these changes Jan 8, 2026
Copy link
Collaborator

@ovitrif ovitrif left a comment

Choose a reason for hiding this comment

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

utAck.

LGTM, testing…

@jvsena42 jvsena42 changed the title feat: block screenshot ad recording of sensitive data feat: block screenshot and recording of sensitive data Jan 8, 2026
Copy link
Collaborator

@ovitrif ovitrif left a comment

Choose a reason for hiding this comment

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

tAck

Nice feature 👏🏻

@ovitrif ovitrif merged commit 2ff3938 into master Jan 8, 2026
21 of 23 checks passed
@ovitrif ovitrif deleted the feat/block-screenshot-for-sensitive-data branch January 8, 2026 17:54
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