https://github.com/codenameakshay/secure_content
Protect your app from screenshots, screen recording & on recent apps screen. Necessary for bank/payment/security apps. Works for both Android & iOS, and is in development.
https://github.com/codenameakshay/secure_content
android dart flutter flutter-plugin ios
Last synced: 3 months ago
JSON representation
Protect your app from screenshots, screen recording & on recent apps screen. Necessary for bank/payment/security apps. Works for both Android & iOS, and is in development.
- Host: GitHub
- URL: https://github.com/codenameakshay/secure_content
- Owner: codenameakshay
- License: mit
- Created: 2022-10-04T16:58:37.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-08-23T12:54:18.000Z (9 months ago)
- Last Synced: 2025-01-31T21:11:29.207Z (4 months ago)
- Topics: android, dart, flutter, flutter-plugin, ios
- Language: Dart
- Homepage: https://pub.dev/packages/secure_content
- Size: 11.1 MB
- Stars: 6
- Watchers: 2
- Forks: 4
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
Secure Content
A flutter package which allows Flutter apps to wrap up some widgets with a SecureWidget which can stop user from screen recording or screenshot the widget. Works on both Android & iOS, and is in development.
## Screenshots
| Android (screen recording) | iOS (screenshot) | iOS (screen recording) | iOS (app switcher) |
| :---------------------------------------------------------------------------------------------------: | :---------------------------------------------------: | :---------------------------------------------------------: | :-------------------------------------------------: |
| https://user-images.githubusercontent.com/60510869/154502746-830d9198-8f11-46ba-9246-784def00f610.mp4 || https://github.com/user-attachments/assets/0b4e10ac-d592-4b5b-92bf-72f51b2cf570 | https://github.com/user-attachments/assets/b6ef5914-eb3a-4e17-be0c-2f00538cffec |
## Features
The package allows your app to protect content shown on screen and on recent apps screen. It shows a black color on iOS, and on Android it blocks screenshot, and shows black in screen recording. This package is in development, and more features will be added soon.
## Installing
### 1. Depend on it
Add this to your package's `pubspec.yaml` file:
```yaml
dependencies:
secure_content: ^1.0.0
```### 2. Install it
You can install packages from the command line:
with `pub`:
```bash
pub get
```with `Flutter`:
```bash
flutter pub get
```### 3. Import it
Now in your `Dart` code, you can use:
```dart
import 'package:secure_content/secure_content.dart';
```## Example
```dart
import 'package:flutter/material.dart';
import 'package:secure_content/secure_content.dart';void main() {
runApp(MyApp());
}class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
appBar: AppBar(
title: const Text('Secure Content Example'),
),
body: SecureWidget(
isSecure: true,
builder: (context, onInit, onDispose) => Center(
child: Text('This is a secure widget'),
),
),
),
);
}
}
```> **Note**: The SecureWidget should be the root widget of your app, or the widget which you want to protect.
> See the [example](https://pub.dev/packages/secure_content/example) for more details.# Bugs or Requests
If you encounter any problems feel free to open an [issue](https://github.com/codenameakshay/secure_content/issues/new?template=bug_report.md). If you feel the library is missing a feature, please raise a [ticket](https://github.com/codenameakshay/secure_content/issues/new?template=feature_request.md) on GitHub and I'll look into it. Pull request are also welcome.
See [Contributing.md](https://github.com/codenameakshay/secure_content/blob/master/CONTRIBUTING.md).