mirror of
https://github.com/quexten/goldwarden.git
synced 2024-12-19 00:22:02 +03:00
19 lines
315 B
Go
19 lines
315 B
Go
//go:build windows || darwin
|
|
|
|
package biometrics
|
|
|
|
func CheckBiometrics(approvalType Approval) bool {
|
|
ok, err := touchid.Authenticate(approvalType.String()
|
|
if err != nil {
|
|
log.Fatal(err)
|
|
}
|
|
|
|
if ok {
|
|
log.Printf("Authenticated")
|
|
return true
|
|
} else {
|
|
log.Fatal("Failed to authenticate")
|
|
return false
|
|
}
|
|
}
|