Skip to content

fix: Add state param in Azure AD provider#89

Merged
yasudacloud merged 3 commits into
yasudacloud:mainfrom
ww24:fix/use-state-in-azuread
May 8, 2025
Merged

fix: Add state param in Azure AD provider#89
yasudacloud merged 3 commits into
yasudacloud:mainfrom
ww24:fix/use-state-in-azuread

Conversation

@ww24
Copy link
Copy Markdown
Contributor

@ww24 ww24 commented Apr 1, 2025

Implement #87 in Azure AD provider.

Comment on lines +92 to +98
if (!userResponse.data.email) {
throw new Error('Email address is not set. Please set email property to the Azure AD user.');
}
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I lost some time to realize that the email property was not set for the Azure AD User. I add an error message for clarity.

Copy link
Copy Markdown
Contributor Author

@ww24 ww24 Apr 1, 2025

Choose a reason for hiding this comment

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

It is possible that someone who forgot to specify an email address for Azure AD users has submitted a Pull Request like this. Usually, the userinfo endpoint is sufficient.

@ww24 ww24 marked this pull request as ready for review April 1, 2025 15:04
@ww24 ww24 force-pushed the fix/use-state-in-azuread branch from 0e523e5 to 1e05d62 Compare May 3, 2025 17:35
@yasudacloud yasudacloud merged commit 7312bcb into yasudacloud:main May 8, 2025
@ww24 ww24 deleted the fix/use-state-in-azuread branch May 8, 2025 15:50
yasudacloud pushed a commit that referenced this pull request May 13, 2025
* refactor: Refactor URL construction in Azure AD provider

* fix: Ensure email property is set for Azure AD user in sign-in callback

* fix: Add state param in Azure AD provider
yasudacloud added a commit that referenced this pull request May 13, 2025
* fix: Use PKCE in Cognito provider (#82)

* fix: Use PKCE in Google provider (#83)

* fix: Use PKCE in OIDC provider (#86)

* fix: Use PKCE in OIDC provider

* fix: ensure state parameter is always appended in OIDC provider

* fix: Add state param in Google provider (#90)

* refactor: Refactor URL construction in Google provider

* fix: Add state param in Google provider

* refactor: generating random bytes

* fix: Add state param in Cognito provider (#88)

* refactor: Refactor URL construction in Cognito provider

* fix: Add state param in Cognito provider

* fix: Add state param in Azure AD provider (#89)

* refactor: Refactor URL construction in Azure AD provider

* fix: Ensure email property is set for Azure AD user in sign-in callback

* fix: Add state param in Azure AD provider

* fix: Add state param in OIDC provider (#91)

* fix require

---------

Co-authored-by: Takenori Nakagawa <ww24@users.noreply.github.com>
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.

2 participants