web.xml 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!--
  3. - Tutorial web application
  4. -
  5. - $Id$
  6. -->
  7. <web-app xmlns="http://java.sun.com/xml/ns/j2ee"
  8. xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  9. xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd" version="2.4">
  10. <display-name>Spring Security Tutorial Application</display-name>
  11. <!--
  12. - Location of the XML file that defines the root application context
  13. - Applied by ContextLoaderListener.
  14. -->
  15. <context-param>
  16. <param-name>contextConfigLocation</param-name>
  17. <param-value>
  18. classpath:applicationContext-business.xml
  19. /WEB-INF/applicationContext-security-ns.xml
  20. </param-value>
  21. </context-param>
  22. <context-param>
  23. <param-name>log4jConfigLocation</param-name>
  24. <param-value>/WEB-INF/classes/log4j.properties</param-value>
  25. </context-param>
  26. <filter>
  27. <filter-name>springSecurityFilterChain</filter-name>
  28. <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
  29. </filter>
  30. <filter-mapping>
  31. <filter-name>springSecurityFilterChain</filter-name>
  32. <url-pattern>/*</url-pattern>
  33. </filter-mapping>
  34. <!--
  35. - Loads the root application context of this web app at startup.
  36. - The application context is then available via
  37. - WebApplicationContextUtils.getWebApplicationContext(servletContext).
  38. -->
  39. <listener>
  40. <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
  41. </listener>
  42. <!--
  43. - Publishes events for session creation and destruction through the application
  44. - context. Optional unless concurrent session control is being used.
  45. -->
  46. <listener>
  47. <listener-class>org.springframework.security.ui.session.HttpSessionEventPublisher</listener-class>
  48. </listener>
  49. <listener>
  50. <listener-class>org.springframework.web.util.Log4jConfigListener</listener-class>
  51. </listener>
  52. <!--
  53. - Provides core MVC application controller. See contacts-servlet.xml.
  54. -->
  55. <servlet>
  56. <servlet-name>bank</servlet-name>
  57. <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
  58. <load-on-startup>1</load-on-startup>
  59. </servlet>
  60. <servlet-mapping>
  61. <servlet-name>bank</servlet-name>
  62. <url-pattern>*.html</url-pattern>
  63. </servlet-mapping>
  64. <welcome-file-list>
  65. <welcome-file>index.jsp</welcome-file>
  66. </welcome-file-list>
  67. </web-app>