Skip to content
Gulam Ali H edited this page Feb 14, 2024 · 2 revisions

Setup

Add the following permissions for Android and iOS:

AndroidManifest.xml

<uses-permission android:name="android.permission.USE_BIOMETRIC" />

Info.plist

<key>NSFaceIDUsageDescription</key>
<string>Need your face to unlock! </string>

No runtime permission requests are needed

Implementation

You can find the default implementation of the IBiometric interface as follows:

using Plugin.Maui.Biometric

var defaultImpl = BiometricAuthenticationService.Default;

// Want to add it as a service instead? you can do so as shown below:
builder.Services.AddSingleton<IBiometric>(BiometricAuthenticationService.Default);
Clone this wiki locally