zeba_academy_local_security 0.0.1
zeba_academy_local_security: ^0.0.1 copied to clipboard
Offline app protection (screenshot, recording detection, app lock, background security)
π zeba_academy_local_security #
A production-ready Flutter package for offline app protection, providing essential security features like screenshot detection, screen recording protection, app lock, and background privacy handling.
β¨ Features #
- πΈ Screenshot Detection (Android)
- π₯ Screen Recording Protection (via FLAG_SECURE)
- π App Lock (Biometric / Device Authentication)
- π Background Protection (Hide sensitive UI when app is minimized)
- β‘ Lightweight & Easy Integration
π¦ Installation #
Add this to your pubspec.yaml:
dependencies:
zeba_academy_local_security: ^0.0.1
Then run:
flutter pub get
π Usage #
1. Import Package #
import 'package:zeba_academy_local_security/zeba_academy_local_security.dart';
2. Enable Security Manager #
final security = SecurityManager();
@override
void initState() {
super.initState();
security.enableSecure();
security.startScreenshotListener();
security.onScreenshot.listen((event) {
debugPrint("Screenshot detected!");
});
}
3. App Lock (Biometric / PIN fallback) #
bool unlocked = await AppLock.authenticate();
if (unlocked) {
print("Access granted");
}
4. Background Protection #
Wrap your app:
BackgroundProtection(
child: MaterialApp(
home: HomePage(),
),
);
βοΈ Platform Support #
| Feature | Android | iOS |
|---|---|---|
| Screenshot Detection | β | β |
| Screen Recording Protection | β | β οΈ Limited |
| App Lock | β | β |
| Background Protection | β | β |
β οΈ Important Notes #
- iOS has strict limitations on detecting screenshots and screen recordings.
- Use
FLAG_SECUREfor maximum protection on Android. - This package focuses on offline-first security.
π§ͺ Testing #
Run tests using:
flutter test
π Project Structure #
lib/
βββ zeba_academy_local_security.dart
βββ src/
βββ security_manager.dart
βββ app_lock.dart
βββ background_protection.dart
π€ Contributing #
Contributions are welcome! Feel free to open issues and submit pull requests.
About Me #
β¨ Iβm Sufyan bin Uzayr, an open-source developer passionate about building and sharing meaningful projects. You can learn more about me and my work at sufyanism.com or connect with me on Linkedin
Your all-in-one no-bloat hub! #
π Explore cutting-edge resources in coding, tech, and development at zeba.academy and code.zeba.academy. Empower yourself with practical skills through curated directives, real-world projects, and hands-on experience. Level up your tech game today! π»β¨
Zeba Academy is a learning platform dedicated to coding, technology, and development.
β‘ Visit our main site: zeba.academy
β‘ Explore hands-on courses and resources at: code.zeba.academy
β‘ Check out our YouTube for more tutorials: zeba.academy
β‘ Follow us on Instagram: zeba.academy
Thank you for visiting!