[java-idp-plugin-duo] branch master updated: Javadoc fixes and import cleanup
Phil Smart
philip.smart at jisc.ac.uk
Wed Aug 5 09:10:39 UTC 2020
This is an automated email from the git hooks/post-receive script.
philsmart pushed a commit to branch master
in repository java-idp-plugin-duo.
View the commit online:
http://git.shibboleth.net/view/?p=java-idp-plugin-duo.git;a=commit;h=b59fda0e9289bb4e3f8f8cf462e558b03ec9ab88
The following commit(s) were added to refs/heads/master by this push:
new b59fda0 Javadoc fixes and import cleanup
b59fda0 is described below
commit b59fda0e9289bb4e3f8f8cf462e558b03ec9ab88
Author: Phil Smart <philip.smart at jisc.ac.uk>
AuthorDate: Wed Aug 5 10:10:22 2020 +0100
Javadoc fixes and import cleanup
---
.../plugin/authn/duo/impl/DuoOIDCAuthnController.java | 18 +++++-------------
1 file changed, 5 insertions(+), 13 deletions(-)
diff --git a/idp-duo-impl/src/main/java/net/shibboleth/idp/plugin/authn/duo/impl/DuoOIDCAuthnController.java b/idp-duo-impl/src/main/java/net/shibboleth/idp/plugin/authn/duo/impl/DuoOIDCAuthnController.java
index 1fd9bc0..a4a20b6 100644
--- a/idp-duo-impl/src/main/java/net/shibboleth/idp/plugin/authn/duo/impl/DuoOIDCAuthnController.java
+++ b/idp-duo-impl/src/main/java/net/shibboleth/idp/plugin/authn/duo/impl/DuoOIDCAuthnController.java
@@ -23,9 +23,7 @@ import java.util.function.Function;
import javax.annotation.Nonnull;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
-import javax.servlet.http.HttpSession;
-import org.apache.commons.lang3.StringUtils;
import org.opensaml.messaging.context.navigate.ChildContextLookup;
import org.opensaml.profile.action.EventIds;
import org.opensaml.profile.context.ProfileRequestContext;
@@ -37,27 +35,21 @@ import org.springframework.web.bind.annotation.RequestMapping;
import net.shbboleth.idp.plugin.authn.duo.DuoClientException;
import net.shbboleth.idp.plugin.authn.duo.DuoException;
import net.shbboleth.idp.plugin.authn.duo.DuoOIDCClient;
-import net.shbboleth.idp.plugin.authn.duo.DuoOIDCClientRegistry;
import net.shbboleth.idp.plugin.authn.duo.DuoOIDCIntegration;
-import net.shbboleth.idp.plugin.authn.duo.DuoRegistryException;
import net.shbboleth.idp.plugin.authn.duo.context.DuoOIDCAuthenticationContext;
import net.shibboleth.idp.authn.ExternalAuthentication;
import net.shibboleth.idp.authn.ExternalAuthenticationException;
import net.shibboleth.idp.authn.context.AuthenticationContext;
-import net.shibboleth.utilities.java.support.annotation.constraint.NonnullAfterInit;
import net.shibboleth.utilities.java.support.annotation.constraint.NotEmpty;
import net.shibboleth.utilities.java.support.component.AbstractInitializableComponent;
-import net.shibboleth.utilities.java.support.component.ComponentInitializationException;
import net.shibboleth.utilities.java.support.logic.Constraint;
-//FIXME: This class needs work e.g. around SWF key storage etc.
/**
*
- * <p>MVC controller for managing the Duo 2FA exchanges implemented as an {@link ExternalAuthentication} mechanism</p>
- *
- * <p>The controller initiates the Duo OIDC flow and collects the authorisation response.</p>
- * TODO: FINISH
+ * <p>MVC controller for managing Duo 2FA exchanges implemented as an {@link ExternalAuthentication} mechanism.</p>
*
+ * <p>The controller initiates the Duo OIDC authorization code grant flow and accepts the authorization code response.</p>
+ *
*/
@Controller
@RequestMapping("%{idp.authn.duo.OIDC.externalAuthnPath:/Authn/Duo/2FA}")
@@ -162,8 +154,8 @@ public class DuoOIDCAuthnController extends AbstractInitializableComponent{
throw new ExternalAuthenticationException("Duo response must contain a 'code' and 'state' parameter");
}
- String key;
- String nonce;
+ final String key;
+ final String nonce;
try {
key = DuoSupport.extractKeyFromState(state);
nonce = DuoSupport.extractNonceFromState(state);
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the commits
mailing list