Why it matters

A biometric prompt whose callback only sets a Boolean can be skipped by anyone who hooks the app. Local authentication protects something only when it unlocks a key the operation needs.

How to meet it

  • Bind local authentication to a key that requires it for every use: a Secure Enclave key with biometry access control on iOS, or a Keystore key used through BiometricPrompt with a CryptoObject on Android.
  • Do not rely on an LAContext result or an authentication callback alone.
  • Decide what happens when biometrics change, and require a full sign-in to re-enroll.

MASTG tests in the local projects

Neither local project runs a MASTG test for MASVS-AUTH-2. The guides below explain the platform mechanisms, and the control’s page on mas.owasp.org links the MASTG tests and weaknesses OWASP maps to it.

Guides on this site

Practice

References

  1. MASVS-AUTH-2 (OWASP MASVS v2.1.0)
  2. MASVS-AUTH: Authentication and Authorization (OWASP MASVS v2.1.0)

List data from the publisher. A guide is listed as the main subject when the weakness or risk is what the guide is about, and as covering it when a dedicated section or worked example addresses it.

Control statements are quoted from OWASP MASVS v2.1.0, licensed CC BY-SA 4.0; the rest is this site's summary. MASTG tests are those the iOS and Android projects here run, with their titles from mas.owasp.org. License.