openid / openid/AppAuth-iOS

Impossible to login with microsoft business account

Open
#720 2 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Objective-C
Stars
2k
Forks
867
Avg merge
4d 48m
Merged PRs (30d)
1

Description

Describe the bug
Impossible to login with microsoft business account

To Reproduce
When we use the following function OIDAuthorizationService.discoverConfiguration(forIssuer: url) using as url "https://login.live.com", everything goes right. Since the url "https://login.live.com" is not working with business account, we wish to use the following url "https://login.microsoftonline.com" or "https://login.microsoftonline.com/common/v2.0/", but the function OIDAuthorizationService.discoverConfiguration reply with the following error

Error Domain=org.openid.appauth.general Code=-5 "JSON error parsing document at 'https://login.microsoftonline.com/common/v2.0/.well-known/openid-configuration': Invalid URL: issuer" UserInfo={NSLocalizedDescription=JSON error parsing document at 'https://login.microsoftonline.com/common/v2.0/.well-known/openid-configuration': Invalid URL: issuer, NSUnderlyingError=0x600000a0f360 {Error Domain=org.openid.appauth.general Code=-2 "Invalid URL: issuer" UserInfo={NSLocalizedDescription=Invalid URL: issuer}}}

so for us it's impossible to login with microsoft business account. The url provided is correct, since the same url works well on android.

Expected behavior
The function OIDAuthorizationService.discoverConfiguration should complete without error.

Environment

  • Device: All iOS devices
  • OS: All iOS version, starting from iOS 10.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing OIDAuthorizationService.discoverConfiguration(forIssuer:) and the response from the Microsoft common v2.0 .well-known/openid-configuration endpoint. Compare its issuer value with the URL passed to discovery and review the existing discovery-related tests, if present. Done means business-account discovery completes without the reported invalid-issuer error and existing providers continue to work.

Written by the indexing model from the issue text.

Assessment

Tech stack
ios, objective-c
Domain
authentication, mobile-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.