使用Spring Security NTLM(2.0.4)时,我的异常低于Exception。
我们正在使用域控制器。
此域控制器旨在解析多个IP地址,以便提供负载平衡。
有没有办法使用Spring NTLM处理这个问题。
jcifs.smb.SmbException: A duplicate name exists on the network.
at jcifs.smb.SmbTransport.checkStatus(SmbTransport.java:522)
at jcifs.smb.SmbTransport.send(SmbTransport.java:622)
at jcifs.smb.SmbSession.sessionSetup(SmbSession.java:280)
at jcifs.smb.SmbSession.send(SmbSession.java:233)
at jcifs.smb.SmbTree.treeConnect(SmbTree.java:154)
at jcifs.smb.SmbSession.logon(SmbSession.java:169)
at jcifs.smb.SmbSession.logon(SmbSession.java:162)
at org.springframework.security.ui.ntlm.NtlmProcessingFilter.logon(NtlmProcessingFilter.java:410)
at org.springframework.security.ui.ntlm.NtlmProcessingFilter.doFilterHttp(NtlmProcessingFilter.java:339)
at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)
at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)
at org.springframework.security.ui.ExceptionTranslationFilter.doFilterHttp(ExceptionTranslationFilter.java:101)
at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)
at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)
at org.springframework.security.wrapper.SecurityContextHolderAwareRequestFilter.doFilterHttp(SecurityContextHolderAwareRequestFilter.java:91)
at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)
at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)
at org.springframework.security.context.HttpSessionContextIntegrationFilter.doFilterHttp(HttpSessionContextIntegrationFilter.java:235)
at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)
在搜索解决方案时,我们遇到了一些需要修改NTLMProcessingFilter类的建议。
JAR:spring-security-ntlm-2.0.4.jar。 类:NtlmProcessingFilter.java 方法:getDCAddress() 代码更改: 现有:dc = UniAddress。 getByName(domainController,true);
修改:UniAddress dc = UniAddress.getByName(domainController,true); dc = UniAddress.getByName(dc.getHostAddress(),true);
但我们没有选择修改JAR代码。 任何人都可以建议解决方案。
先谢谢。
作者Srini