From 3f2631367fd285fc4ab870568ab93e804103a200 Mon Sep 17 00:00:00 2001 From: nemonik Date: Thu, 22 Mar 2012 12:16:24 -0400 Subject: [PATCH] added comments on configuration of client --- .../OpenIdConnectAuthenticationFilter.java | 30 +++++++++++++++++-- openid-connect-common/.classpath | 9 +----- 2 files changed, 28 insertions(+), 11 deletions(-) diff --git a/openid-connect-client/src/main/java/org/mitre/openid/connect/client/OpenIdConnectAuthenticationFilter.java b/openid-connect-client/src/main/java/org/mitre/openid/connect/client/OpenIdConnectAuthenticationFilter.java index 0e1140a13..42584cf29 100644 --- a/openid-connect-client/src/main/java/org/mitre/openid/connect/client/OpenIdConnectAuthenticationFilter.java +++ b/openid-connect-client/src/main/java/org/mitre/openid/connect/client/OpenIdConnectAuthenticationFilter.java @@ -44,6 +44,29 @@ import com.google.gson.JsonParser; /** * The OpenID Connect Authentication Filter * + * See: + * + * http://static.springsource.org/spring-security/site/docs/3.0.x/reference/ns-config.html#ns-custom-filters + * + * + * + * + * + * + * + * + * + * + * + * + * + * * @author nemonik * */ @@ -57,6 +80,7 @@ public class OpenIdConnectAuthenticationFilter extends private final static int KEY_SIZE = 1024; private final static String SIGNING_ALGORITHM = "SHA256withRSA"; private final static String NONCE_SIGNATURE_COOKIE_NAME = "nonce"; + private final static String FILTER_PROCESSES_URL ="/j_spring_openid_connect_security_check"; /** * Return the URL w/ GET parameters @@ -163,7 +187,7 @@ public class OpenIdConnectAuthenticationFilter extends * */ protected OpenIdConnectAuthenticationFilter() { - super("/j_spring_openid_connect_security_check"); + super(FILTER_PROCESSES_URL); } /* @@ -204,7 +228,7 @@ public class OpenIdConnectAuthenticationFilter extends throw new IllegalArgumentException( "A Client Secret must be supplied"); } - + KeyPairGenerator keyPairGenerator; try { keyPairGenerator = KeyPairGenerator.getInstance("RSA"); @@ -536,7 +560,7 @@ public class OpenIdConnectAuthenticationFilter extends public void setErrorRedirectURI(String errorRedirectURI) { this.errorRedirectURI = errorRedirectURI; } - + public void setScope(String scope) { this.scope = scope; } diff --git a/openid-connect-common/.classpath b/openid-connect-common/.classpath index 74d8d97f5..1b28ee5d7 100644 --- a/openid-connect-common/.classpath +++ b/openid-connect-common/.classpath @@ -1,18 +1,11 @@ - - - + - - - - -