Is re-prompting a user for credentials an effective measure to prove a user's identify
Yes, this is quite common and generally more effective than not.
Typically this is used to assert that the user sitting at the keyboard is the same person that logged into the app at some point in the past. This prevents scenarios where a user has left their computer unlocked, or left themselves logged in on a public terminal, or where the user is accessing the site through a weaker form of authentication like a "magic" login link in an email.
There are lots of other solutions but the only one you get for free (by virtue of having already collected the email and password) is to challenge the user to re-enter their password.
and have found a few pages which re-prompt the user for a password before a transaction is submitted ... AAD B2C doesn't support the Resource Owner Password Credentials Grant flow so I'm forced to look for alternatives.
You should definitely not use the Resource Owner Password Credentials Flow for this purpose, which allows an RP to collect a plaintext password and forwards it to he IDP for verification.
OIDC provides a purpose-built alternative: You should perform a new authorization flow using the prompt
parameter to instruct the IDP to force the user to re-enter their password.
Initiate a new Code Flow but include prompt=login
, and the IDP will (or at least SHOULD
according to the spec) reauthenticate the user.
prompt
and the values it supports is defined in the OIDC core spec under 3.1.2.1. Authentication Request.