biometric_auth_flutter 0.0.1 copy "biometric_auth_flutter: ^0.0.1" to clipboard
biometric_auth_flutter: ^0.0.1 copied to clipboard

A Flutter plugin for Android biometric authentication using MethodChannels.

biometric_auth_flutter #

pub package

A simple Flutter plugin that enables biometric authentication on Android using method channels. Supports fingerprint, face unlock, and device credentials like PIN or pattern.


โœจ Features #

  • ๐Ÿ” Authenticate users using biometrics or device credentials.
  • ๐Ÿ’ก Native Android biometric prompt.
  • โš™๏ธ Simple and lightweight API.
  • ๐Ÿ“ฑ Android platform supported.

๐Ÿš€ Getting Started #

1. Add dependency #

In your pubspec.yaml:

dependencies:
  biometric_auth_flutter: ^0.0.1

2. Import it #

import 'package:biometric_auth_flutter/biometric_auth_flutter.dart';

3. Use it #

final isAuthenticated = await BiometricAuthFlutter().authenticate();

if (isAuthenticated) {
  // Navigate to secure area
} else {
  // Show fallback or error
}

๐Ÿ“ฆ Platform Support #

Platform Supported
Android โœ… YES
iOS โŒ Not yet

iOS support will be added in a future release. PRs are welcome!


๐Ÿงช Example #

Use the plugin in your authentication screen like this:

ElevatedButton(
  onPressed: () async {
    bool auth = await BiometricAuthFlutter().authenticate();
    if (auth) {
      // proceed
    } else {
      // handle failure
    }
  },
  child: Text("Login with Biometrics"),
);

๐Ÿง  How It Works #

This plugin uses AndroidX BiometricPrompt APIs under the hood and communicates with Flutter via MethodChannel.


๐Ÿ› ๏ธ Development #

Run tests #

flutter test

Folder Structure #

lib/
  biometric_auth_flutter.dart          # Public API
  biometric_auth_flutter_method_channel.dart
  biometric_auth_flutter_platform_interface.dart

android/
  ...                                  # Kotlin native code

๐Ÿ“„ License #

This project is licensed under the MIT License - see the LICENSE file for details.


๐Ÿ‘ค Author #

Muhaimin K P M ๐Ÿ“ Kondotty, Kerala, India ๐Ÿ”— GitHub ๐Ÿ“ง [email protected]


๐Ÿ’ก Contributions #

Feel free to open issues or submit PRs if you'd like to contribute. Thank you for helping improve the plugin! ๐Ÿ™Œ


---

## โœ… Summary

- This `README.md` includes:
  - Plugin description
  - Installation
  - Usage
  - Platform support
  - Author info (you)
  - Contribution instructions
  - License and badges

---

Let me know if you'd also like:
- A basic `example/` Flutter app to demo this
- Banner image or pub.dev thumbnail
- GitHub Actions CI for testing automatically

Would you like me to generate that too?

# biometric_auth_flutter

[![pub package](https://img.shields.io/pub/v/biometric_auth_flutter.svg)](https://pub.dev/packages/biometric_auth_flutter)

A simple Flutter plugin that enables biometric authentication on Android using method channels. Supports fingerprint, face unlock, and device credentials like PIN or pattern.

---

## โœจ Features

- ๐Ÿ” Authenticate users using biometrics or device credentials.
- ๐Ÿ’ก Native Android biometric prompt.
- โš™๏ธ Simple and lightweight API.
- ๐Ÿ“ฑ Android platform supported.

---

## ๐Ÿš€ Getting Started

### 1. Add dependency

In your `pubspec.yaml`:

```yaml
dependencies:
  biometric_auth_flutter: ^0.0.1

2. Import it #

import 'package:biometric_auth_flutter/biometric_auth_flutter.dart';

3. Use it #

final isAuthenticated = await BiometricAuthFlutter().authenticate();

if (isAuthenticated) {
  // Navigate to secure area
} else {
  // Show fallback or error
}

๐Ÿ“ฆ Platform Support #

Platform Supported
Android โœ… YES
iOS โŒ Not yet

iOS support will be added in a future release. PRs are welcome!


๐Ÿงช Example #

Use the plugin in your authentication screen like this:

ElevatedButton(
  onPressed: () async {
    bool auth = await BiometricAuthFlutter().authenticate();
    if (auth) {
      // proceed
    } else {
      // handle failure
    }
  },
  child: Text("Login with Biometrics"),
);

๐Ÿง  How It Works #

This plugin uses AndroidX BiometricPrompt APIs under the hood and communicates with Flutter via MethodChannel.


๐Ÿ› ๏ธ Development #

Run tests #

flutter test

Folder Structure #

lib/
  biometric_auth_flutter.dart          # Public API
  biometric_auth_flutter_method_channel.dart
  biometric_auth_flutter_platform_interface.dart

android/
  ...                                  # Kotlin native code

๐Ÿ“„ License #

This project is licensed under the MIT License - see the LICENSE file for details.


๐Ÿ‘ค Author #

Muhaimin K P M ๐Ÿ“ Kondotty, Kerala, India ๐Ÿ”— GitHub ๐Ÿ“ง [email protected]


๐Ÿ’ก Contributions #

Feel free to open issues or submit PRs if you'd like to contribute. Thank you for helping improve the plugin! ๐Ÿ™Œ

2
likes
0
points
20
downloads

Publisher

unverified uploader

Weekly Downloads

A Flutter plugin for Android biometric authentication using MethodChannels.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter, plugin_platform_interface

More

Packages that depend on biometric_auth_flutter

Packages that implement biometric_auth_flutter