-
Jun 18th, 2010, 08:02 AM
#1
Problem in migrating from spring 2.5 to 3.0 in security
I am migrating my application from spring 2.5 to 3.0.
I am getting follwing error while i try to deploy my application in spring dm server 2.0
Caused by: org.xml.sax.SAXParseException: cvc-complex-type.2.4.c: The matching wildcard is strict, but no declaration can be found for element 'sec:http'
My securityContext xml file looks like the below
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:tx="http://www.springframework.org/schema/tx"
xmlns:sec="http://www.springframework.org/schema/security"
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schem...-beans-3.0.xsd
http://www.springframework.org/schema/tx
http://www.springframework.org/schem...ing-tx-3.0.xsd
http://www.springframework.org/schema/security
http://www.springframework.org/schema/security/spring-security-3.0.xsd">
<!--<description>
This is the configuration file for the Spring Security
configuration used with the sample application.
</description>-->
<sec:http>
<sec:intercept-url pattern="/xxx/login.htm" access="IS_AUTHENTICATED_ANONYMOUSLY" filters="none" />
<sec:intercept-url pattern="/**/*.htm" access="ROLE_ADMIN, ROLE_CONFIGURATOR, ROLE_USER, ROLE_VIEWER" />
<sec:form-login login-page="/xxx/login.htm" default-target-url="/xxx/tabs.htm"
authentication-failure-url="/xxx/login.htm?login_error=1" />
<sec:logout logout-url="/xxx/logout.htm" logout-success-url="/xxx/login.htm"/>
</sec:http>
<bean id="springSecurityFilterChain" class="org.springframework.web.filter.DelegatingFi lterProxy"/>
<bean id="xxxUserAuthenticationProvider"
class="com.nm.apps.gui.user.util.XxxUserAuthentica teProvider">
<property name="host" value="localhost" />
</bean>
<!-- Authentication Manager -->
<bean id="_authenticationManager" class="org.springframework.security.providers.Prov iderManager">
<property name="providers">
<list>
<ref bean="xxxUserAuthenticationProvider" />
</list>
</property>
</bean>
</beans>
-
Jun 18th, 2010, 08:28 AM
#2
Use [ code][/code ] tags when posting code
!!!
Spring Security isn't part of the Spring Framework. You will need additional jars if you want to upgrade those as well.
-
Jun 19th, 2010, 11:39 PM
#3
Hi
I have already added all spring security related jars from spring repository.
-
Jun 21st, 2010, 12:34 AM
#4
I have tried with all the spring security related jars.still the problem exists.
Could you please specify the jars that need to be added.
-
Jun 21st, 2010, 09:52 AM
#5
As i am using spring dm server 2.0 Could you please let me know whether i need to add spring security jars to pickup folder or usr folder ?
-
Jun 21st, 2010, 10:02 AM
#6
In Spring Security 3.0 the namespace configuration was removed from spring-security-core. Try adding spring-security-config and see if that helps.
Regards,
Rob
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules