Forgive me I posted the wrong web.xml, the web.xml I posted was for a test application which I had been working on. The correct web.xml is as follows:
/<?xml version="1.0" encoding="UTF-8"?> <web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_4.xsd"> <context-param> <param-name>contextConfigLocation</param-name> <param-value> /WEB-INF/spring/root-context.xml </param-value> </context-param> <filter> <filter-name>ShiroFilter</filter-name> <filter-class>org.apache.shiro.web.servlet.IniShiroFilter</filter-class> <init-param> <param-name>config</param-name> <param-value> # The IniShiroFilter configuration is very powerful and flexible, while still remaining succinct. # Please read the org.apache.shiro.web.servlet.IniShiroFilter JavaDoc for information. # Quick Tip: Instead of having this configuration here in web.xml, you can instead # move all of this to a 'shiro.ini' file at the root of the classpath and remove # the 'config' init-param. Or you can specify the 'configPath' init-param and specify the # path to a resource at any location (url, file or classpath). This may be desired if the # config gets long and you want to keep web.xml clean. [users] # format: username = password, role1, role2, ..., roleN root = secret,admin guest = guest,guest presidentskroob = 12345,president,admin darkhelmet = ludicrousspeed,darklord,schwartz lonestarr = vespa,goodguy,schwartz [roles] # format; roleName = permission1, permission2, ..., permissionN admin = * schwartz = lightsaber:* goodguy = winnebago:drive:eagle5 [urls] /ipf/** = authcBasic </param-value> </init-param> </filter> <filter-mapping> <filter-name>ShiroFilter</filter-name> <url-pattern>/*</url-pattern> </filter-mapping> <listener> <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> </listener> <servlet> <servlet-name>appServlet</servlet-name> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class> <init-param> <param-name>contextConfigLocation</param-name> <param-value>/WEB-INF/spring/appServlet/servlet-context.xml</param-value> </init-param> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <servlet-name>appServlet</servlet-name> <url-pattern>/*</url-pattern> </servlet-mapping> </web-app>/ -- View this message in context: http://shiro-user.582556.n2.nabble.com/Setting-up-Shiro-to-work-with-spring-and-Jersey-Jackson-tp6948893p6951002.html Sent from the Shiro User mailing list archive at Nabble.com.
