diff --git a/ntlm/src/main/java/org/springframework/security/ui/ntlm/NtlmProcessingFilterEntryPoint.java b/ntlm/src/main/java/org/springframework/security/ui/ntlm/NtlmProcessingFilterEntryPoint.java
index 1fda0ff8ed..9298efc3fd 100755
--- a/ntlm/src/main/java/org/springframework/security/ui/ntlm/NtlmProcessingFilterEntryPoint.java
+++ b/ntlm/src/main/java/org/springframework/security/ui/ntlm/NtlmProcessingFilterEntryPoint.java
@@ -15,19 +15,16 @@
package org.springframework.security.ui.ntlm;
-import org.springframework.security.AuthenticationException;
-import org.springframework.security.ui.AuthenticationEntryPoint;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.springframework.beans.factory.InitializingBean;
-import org.springframework.util.Assert;
-
import java.io.IOException;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
+import org.springframework.security.AuthenticationException;
+import org.springframework.security.ui.AuthenticationEntryPoint;
+import org.springframework.util.Assert;
+
/**
* Used by ExceptionTranslationFilter
to assist with the NTLM
* negotiation. Also handles redirecting the user to the authentication
@@ -39,76 +36,73 @@ import javax.servlet.http.HttpServletResponse;
* @version $Id$
*/
public class NtlmProcessingFilterEntryPoint implements AuthenticationEntryPoint {
- //~ Static fields/initializers =====================================================================================
- private static final Log logger = LogFactory.getLog(NtlmProcessingFilterEntryPoint.class);
+ //~ Instance fields ================================================================================================
- //~ Instance fields ================================================================================================
+ /** Where to redirect the browser to if authentication fails */
+ private String authenticationFailureUrl;
- /** Where to redirect the browser to if authentication fails */
- private String authenticationFailureUrl;
+ //~ Methods ========================================================================================================
- //~ Methods ========================================================================================================
+ /**
+ * Sets the authentication failure URL.
+ *
+ * @param authenticationFailureUrl the authentication failure URL.
+ */
+ public void setAuthenticationFailureUrl(String authenticationFailureUrl) {
+ Assert.hasLength(authenticationFailureUrl, "authenticationFailureUrl must be specified");
+ this.authenticationFailureUrl = authenticationFailureUrl;
+ }
- /**
- * Sets the authentication failure URL.
- *
- * @param authenticationFailureUrl the authentication failure URL.
- */
- public void setAuthenticationFailureUrl(String authenticationFailureUrl) {
- Assert.hasLength(authenticationFailureUrl, "authenticationFailureUrl must be specified");
- this.authenticationFailureUrl = authenticationFailureUrl;
- }
+ /**
+ * Sends an NTLM challenge to the browser requiring authentication. The
+ * WWW-Authenticate header is populated with the appropriate information
+ * during the negotiation lifecycle by calling the getMessage() method
+ * from an NTLM-specific subclass of {@link NtlmBaseException}:
+ *
+ *
- *