Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added Tenant ID to WwwAuthenticateParameters #2922

Merged
merged 20 commits into from
Oct 7, 2021
Merged

Conversation

abatishchev
Copy link
Contributor

Changes proposed in this request

  • Added property TenantID to WwwAuthenticateParameters
  • Which underneath calls internal class Authority to parse authority uri

Testing

  • Updated unit and integration tests

Performance impact

  • There should be no impact as a new property has been added

@abatishchev abatishchev marked this pull request as ready for review October 4, 2021 17:17
@abatishchev
Copy link
Contributor Author

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Copy link
Contributor

@jmprieur jmprieur left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM
Thanks @abatishchev
One feedback/comment for @bgavrilMS

Copy link
Member

@bgavrilMS bgavrilMS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See the 2 comments related to Jean-Marc's ask

Copy link
Member

@bgavrilMS bgavrilMS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@abatishchev abatishchev merged commit f8f9852 into master Oct 7, 2021
@abatishchev abatishchev deleted the alexbat/www-auth-2 branch October 7, 2021 19:51
/// <summary>
/// Gets Azure AD tenant ID.
/// </summary>
public string GetTenantId() => Instance.Authority
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So we kept it?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. If we want to rip it up into a different package, we can either:

  • not take this method along and instead make it into an extension method to avoid any breaking changes in MSAL
    OR
  • move GetTenantId to the new package, but provide a different implementation for it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bgavrilMS @jmprieur Following up on this - are we taking this as-is or refactoring needed before release?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's fine as is for now. If we introduce support for other authorities, this will have to return null. If we need to extract a package from this logic, we can leave this method behind.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah .. never mind

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants