goldwarden/agent/systemauth/biometrics/touchid.go
2023-09-12 01:23:33 +02:00

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
}
}