dart_secure 0.3.3 copy "dart_secure: ^0.3.3" to clipboard
dart_secure: ^0.3.3 copied to clipboard

A new Flutter Framework that uses Dart Programming Language

example/example.dart

import 'package:dart_secure/dart_secure.dart';

void main() async {
  // Biometric User Authentication Example

  getBiometric();
  // In-App Encryption Example
  var encryptedAddress = inAppEncrypt(text: "User's Address", key: "MyUsersAddress");
  print("Encrypted Address: $encryptedAddress");

  // Hash Encryption Example
  var hashedAddress = hashEncrypt(text: "User's Address");
  print("Hashed Address: $hashedAddress");

  // In-App Decryption Example
  var decryptedAddress = inAppDecrypt(cipherText: encryptedAddress, key: "MyUsersAddress");
  print("Decrypted Address: $decryptedAddress");
}

void getBiometric() async {
  var authStatus = await biometricAuth();
  if (authStatus == AuthenticationStatus.successful) {
    print("Authentication successful, continue");
  } else {
    print("Authentication unsuccessful, try again");
  }
}
3
likes
0
points
101
downloads

Publisher

verified publishersaifalmajd.blogspot.com

Weekly Downloads

A new Flutter Framework that uses Dart Programming Language

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

encrypt, flutter, local_auth

More

Packages that depend on dart_secure