Why does MSAL Android default to v2.0 when trying to login?

Pill Skates 1 Reputation point
2021-04-29T05:52:03.53+00:00

I'm trying to use the MSAL Android library to authenticate to ADFS. When my app lands on the login page the url is the following:

https://.../adfs/oAuth2/v2.0/authorize?...

Where does the /v2.0 come from? Can this be an issue with the app registration in ADFS or is this an issue in the android app config? When authenticating with my web app there is no /v2.0 in the url and everything works fine.

Here's the android config

{
  "client_id": "...",
  "authorization_user_agent": "DEFAULT",
  "redirect_uri": "msauth://.../...",
  "account_mode" : "SINGLE",
  "scopes": ["openid"],
  "authorities": [
    {
      "type": "ADFS",
      "authority_url": "https://.../adfs/"
    }
  ]
}

I'm using "com.microsoft.identity.client:msal:2.0.5".

And here's the web app config:

    msalConfig: {
      auth: {
        clientId: '...',
        authority: 'https://.../adfs/',
      },
    }
Active Directory Federation Services
Active Directory Federation Services
An Active Directory technology that provides single-sign-on functionality by securely sharing digital identity and entitlement rights across security and enterprise boundaries.
1,301 questions
Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
25,048 questions
0 comments No comments
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.