Wadii Slatnia
Wadii Slatnia

Reputation: 183

You must use a 3.0 schema with Spring Security 3.0

I am using spring_security with primefaces I create my login file and the loginBean and I add all the required librairies but I get this error:

     Configuration problem: You must use a 3.0 schema with Spring Security 3.0.(2.0 or 3.1       versions are not valid) Please update your schema declarations to the 3.0.3 schema     (spring-security-3.0.3.xsd).
Offending resource: ServletContext resource [/WEB-INF/applicationContext-security.xml] 

I look to the faces-config.xml I found that this line

xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee      /web-facesconfig_2_0.xsd"
    version="2.0"

I wonder if is this the main cause of error ?? and how can I correct it ?

Upvotes: 0

Views: 1662

Answers (1)

LaurentG
LaurentG

Reputation: 11717

You should first read the whole error message. Sorry if my remark looks rude, but I am myself surprised how often I want to go too fast and don't read the error message until the end.

Here the error told you:

Offending resource: ServletContext resource [/WEB-INF/applicationContext-security.xml] 

Your problem has nothing to do with JSF and the problem is located in applicationContext-security.xml. You probably reference in that file the wrong schema (e.g. 2.0 or 3.1 according to the error message).

If this doesn't help you, please edit your message and provide us the applicationContext-security.xml.

Upvotes: 3

Related Questions