SensitiveContent should support ways to hook custom handlers for lower Android versions or iOS subsystems
- Dominant language
- Dart
- Stars
- 179k
- Forks
- 31.1k
- PR merge metrics
- PR metrics pending
Description
> To reword/clarify feature request:
> Would be great to be able to use single/same API across app (SensitiveContent) to hook-up custom protections (for example iOS, old Android versions screen protections, screen recording detections, etc). Not requesting to implement or provide those protections, just to open up API to be able to provide custom "hooks".
### Use case
While `SensitiveContent` seems to be great and intuitive API, it does not allow to expand it to older Android versions and/or iOS. So multiple overlapping security features are required.
It would be great to have some way to bind/hook custom code to enable protections (like FLAG_SECURE, or tapjacking, etc) which are not specific to Android 35+.
Context: https://docs.flutter.dev/platform-integration/android/sensitive-content
### Proposal
Allowing to pass either global registration like`SensitiveContent.addHandler(<>)`, or local `SensitiveContent(handler: <>, child: ...)` or configure additional parent widget `SensitiveContentHandlers(handlers)`
Contributor guide
Assessment
This issue has not been assessed yet.