-
Notifications
You must be signed in to change notification settings - Fork 31
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
Self-contained Magic Link Authenticator #25
Conversation
...ava/org/wso2/carbon/identity/application/authenticator/magiclink/MagicLinkAuthenticator.java
Outdated
Show resolved
Hide resolved
...ava/org/wso2/carbon/identity/application/authenticator/magiclink/MagicLinkAuthenticator.java
Outdated
Show resolved
Hide resolved
...ava/org/wso2/carbon/identity/application/authenticator/magiclink/MagicLinkAuthenticator.java
Outdated
Show resolved
Hide resolved
...ava/org/wso2/carbon/identity/application/authenticator/magiclink/MagicLinkAuthenticator.java
Outdated
Show resolved
Hide resolved
...ava/org/wso2/carbon/identity/application/authenticator/magiclink/MagicLinkAuthenticator.java
Outdated
Show resolved
Hide resolved
...ava/org/wso2/carbon/identity/application/authenticator/magiclink/MagicLinkAuthenticator.java
Outdated
Show resolved
Hide resolved
...ava/org/wso2/carbon/identity/application/authenticator/magiclink/MagicLinkAuthenticator.java
Outdated
Show resolved
Hide resolved
...ava/org/wso2/carbon/identity/application/authenticator/magiclink/MagicLinkAuthenticator.java
Outdated
Show resolved
Hide resolved
...ava/org/wso2/carbon/identity/application/authenticator/magiclink/MagicLinkAuthenticator.java
Outdated
Show resolved
Hide resolved
...ava/org/wso2/carbon/identity/application/authenticator/magiclink/MagicLinkAuthenticator.java
Outdated
Show resolved
Hide resolved
...o2/carbon/identity/application/authenticator/magiclink/util/MagicLinkAuthErrorConstants.java
Outdated
Show resolved
Hide resolved
PR builder started |
PR builder completed |
PR builder started |
PR builder completed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approving the pull request based on the successful pr build https://github.com/wso2/product-is/actions/runs/3521421897
...ava/org/wso2/carbon/identity/application/authenticator/magiclink/MagicLinkAuthenticator.java
Outdated
Show resolved
Hide resolved
Manual TestingManual test round performed and verified. |
...org/wso2/carbon/identity/application/authenticator/magiclink/MagicLinkAuthenticatorTest.java
Outdated
Show resolved
Hide resolved
@@ -1,18 +1,20 @@ | |||
<?xml version="1.0" encoding="utf-8"?> | |||
<!-- | |||
~ Copyright (c) 2022, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. | |||
~ Copyright (c) 2022, WSO2 LLC. (http://www.wso2.org) All Rights Reserved. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix the licence header
@@ -1,18 +1,20 @@ | |||
<?xml version="1.0" encoding="utf-8"?> | |||
<!-- | |||
~ Copyright (c) 2021, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. | |||
~ Copyright (c) 2021, WSO2 LLC. (http://www.wso2.org) All Rights Reserved. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix the licence header
@@ -0,0 +1,79 @@ | |||
/* | |||
* Copyright (c) 2022, WSO2 LLC. (http://www.wso2.org) All Rights Reserved. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix licence header
@@ -1,7 +1,7 @@ | |||
/* | |||
* Copyright (c) 2021, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. | |||
* Copyright (c) 2021, WSO2 LLC. (http://www.wso2.org) All Rights Reserved. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix header
@@ -1,7 +1,7 @@ | |||
/* | |||
* Copyright (c) 2021, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. | |||
* Copyright (c) 2021, WSO2 LLC. (http://www.wso2.org) All Rights Reserved. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix header
* This method is used to resolve the user from authentication response from identifier handler. | ||
* | ||
* @param request The httpServletRequest. | ||
* @param context The authentication context. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add @return
@@ -1,9 +1,9 @@ | |||
/* | |||
* Copyright (c) 2022, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. | |||
* Copyright (c) 2022, WSO2 LLC. (http://www.wso2.org) All Rights Reserved. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix header
private AuthenticationContext authenticationContext; | ||
|
||
@Override | ||
public AuthenticatorFlowStatus process(HttpServletRequest request, HttpServletResponse response, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add method comments for public methods
if (context.isLogoutRequest()) { | ||
return AuthenticatorFlowStatus.SUCCESS_COMPLETED; | ||
} | ||
if (getName().equals(context.getProperty(FrameworkConstants.LAST_FAILED_AUTHENTICATOR))) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use StringUtils. equals()
to avoid NPE
Comments fixed by #33 |
Purpose
In the current implementation, the MagicLink authenticator is dependent on the identifier first to authenticate and resolve the user. But ideally, we should improve the MagicLink authenticator to embed the functionality of the identifier first authenticator to resolve the user using a given identifier.
This PR introduces identifier first capabilities into the Magic Link Authenticator.
Related Issues
Related PRs