"Der übereinstimmende Platzhalter ist streng, aber für das Element 'http' kann keine Deklaration gefunden werden."

Ich versuche, die NTLM-Authentifizierung zu konfigurieren, erhalte jedoch folgende Fehlermeldung:

cvc-complex-type.2.4.c: Der passende Platzhalter ist streng, aber für das Element 'http' kann keine Deklaration gefunden werden.

Ich habe viele Themen mit einem ähnlichen Fehler gelesen, aber ich konnte keine Lösung für mein Problem finden.

Meine security.xml-Datei, die einen Fehler verursacht, lautet:

<code><beans:beans xmlns="http://www.springframework.org/schema/security"
    xmlns:beans="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://www.springframework.org/schema/beans
                            http://www.springframework.org/schema/beans/spring-beans.xsd
                            http://www.springframework.org/schema/security
                            http://www.springframework.org/schema/security/spring-security.xsd" >

    <http access-denied-page="forms/error403.jsp" entry-point-ref="ntlmEntryPoint" servlet-api-provision="false"> 
        <intercept-url pattern="forms/error403.jsp" filters="none"/>
        <intercept-url pattern="forms/**" access="ROLE_GUEST,ROLE_OPERATOR,ROLE_ADMIN" />
                <custom-filter position="PRE_AUTH_FILTER"/>
    </http>

    <authentication-manager alias="mainAuthenticationManager"/>  
    <authentication-provider user-service-ref='userDetailsService' />

    <beans:bean id="userDetailsService"
        class="service.UserInfoService">
        <beans:property name="dataSource" ref="dataSource" />
        <beans:property name="usersByUsernameQuery" value="select distinct name, ' ' as password, 1 as enabled from TMP_SPRING_USERS where name=?" />
        <beans:property name="authoritiesByUsernameQuery" value="select name, role from TMP_SPRING_USERS where name=?" />
    </beans:bean>

    <beans:bean id="ntlmEntryPoint"
        class="org.springframework.security.ui.ntlm.NtlmProcessingFilterEntryPoint">
        <beans:property name="authenticationFailureUrl" value="forms/error403.html" />
    </beans:bean>

    <beans:bean id="exceptionTranslationFilter"
        class="org.springframework.security.ui.ExceptionTranslationFilter">
        <beans:property name="authenticationEntryPoint" ref="ntlmEntryPoint" />
    </beans:bean>

    <beans:bean id="ntlmFilter"
        class="org.springframework.security.ui.ntlm.NtlmProcessingFilter">
        <custom-filter position="NTLM_FILTER" />
        <beans:property name="authenticationManager" ref="mainAuthenticationManager" />
        <beans:property name="retryOnAuthFailure" value="true" />
        <beans:property name="stripDomain" value="true"/>
        <beans:property name="domainController" value="company.com" />
        <beans:property name="jcifsProperties">
            <beans:props>
                <beans:prop key="jcifs.smb.lmCompatibility">0</beans:prop> 
                <beans:prop key="jcifs.smb.client.useExtendedSecurity">false</beans:prop> 
                <beans:prop key="jcifs.smb.client.domain">COMPANY</beans:prop>
                <beans:prop key="jcifs.smb.client.username">somenycuser</beans:prop>
                <beans:prop key="jcifs.smb.client.password">AReallyLoooongRandomPassword</beans:prop>
            </beans:props> 
        </beans:property> 
    </beans:bean>


</beans:beans>
</code>

Da Spring Security ab Version 3.X die NTLM-Erweiterung nicht mehr enthält, verwende ich sie abhttp://aloiscochard.blogspot.com/2010/03/spring-security-ntlm-3.html Artikel.

Bitte hilf mir.

Antworten auf die Frage(1)

Ihre Antwort auf die Frage