I'm building a serverless app with Firebase: Firestore and cloud functions. One thing I've been struggling with is how to validate that a user has 2FA enabled to allow access to certain functions. Already enrolled into Google Identity Platform to allow 2FA, unfortunately I wasn't able to find an option to force 2FA.
My security rules requirements are: logged in, email verified, did authenticate with 2FA.
Current security rules in cloud firestore :
request.auth != null && request.auth.token.email_verified
As far as I've searched request.auth.token.phone_number can be checked, but that only checks if the user has registered a phone number, not if they have 2FA login?