upgrading to spring security 3.2, other maven upgrades, cleanup work

This commit is contained in:
eugenp 2013-12-18 13:25:45 +02:00
parent dac56fd805
commit f40c9d3a96
15 changed files with 663 additions and 645 deletions

View File

@ -140,7 +140,7 @@
<properties> <properties>
<!-- Spring --> <!-- Spring -->
<org.springframework.version>3.2.6.RELEASE</org.springframework.version> <org.springframework.version>3.2.6.RELEASE</org.springframework.version>
<org.springframework.security.version>3.1.4.RELEASE</org.springframework.security.version> <org.springframework.security.version>3.2.0.RELEASE</org.springframework.security.version>
<!-- persistence --> <!-- persistence -->
<hibernate.version>4.3.0.Final</hibernate.version> <hibernate.version>4.3.0.Final</hibernate.version>
@ -166,14 +166,13 @@
<httpclient.version>4.3.1</httpclient.version> <httpclient.version>4.3.1</httpclient.version>
<rest-assured.version>2.0.1</rest-assured.version> <rest-assured.version>2.0.1</rest-assured.version>
<groovy.version>1.8.9</groovy.version>
<!-- maven plugins --> <!-- maven plugins -->
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version>
<maven-compiler-plugin.version>3.1</maven-compiler-plugin.version> <maven-compiler-plugin.version>3.1</maven-compiler-plugin.version>
<maven-resources-plugin.version>2.6</maven-resources-plugin.version>
<maven-surefire-plugin.version>2.16</maven-surefire-plugin.version>
<maven-war-plugin.version>2.4</maven-war-plugin.version> <maven-war-plugin.version>2.4</maven-war-plugin.version>
<maven-surefire-plugin.version>2.16</maven-surefire-plugin.version>
<maven-resources-plugin.version>2.6</maven-resources-plugin.version>
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version>
</properties> </properties>

View File

@ -125,12 +125,14 @@
<httpclient.version>4.3.1</httpclient.version> <httpclient.version>4.3.1</httpclient.version>
<rest-assured.version>2.1.0</rest-assured.version> <rest-assured.version>2.1.0</rest-assured.version>
<groovy.version>1.8.9</groovy.version>
<!-- Maven plugins --> <!-- Maven plugins -->
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version> <maven-compiler-plugin.version>3.1</maven-compiler-plugin.version>
<maven-surefire-plugin.version>2.16</maven-surefire-plugin.version>
<maven-war-plugin.version>2.4</maven-war-plugin.version> <maven-war-plugin.version>2.4</maven-war-plugin.version>
<maven-surefire-plugin.version>2.16</maven-surefire-plugin.version>
<maven-resources-plugin.version>2.6</maven-resources-plugin.version>
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version>
</properties> </properties>
</project> </project>

View File

@ -2,7 +2,7 @@
<beans:beans xmlns="http://www.springframework.org/schema/security" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" <beans:beans xmlns="http://www.springframework.org/schema/security" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:beans="http://www.springframework.org/schema/beans" xmlns:beans="http://www.springframework.org/schema/beans"
xsi:schemaLocation=" xsi:schemaLocation="
http://www.springframework.org/schema/security http://www.springframework.org/schema/security/spring-security-3.1.xsd http://www.springframework.org/schema/security http://www.springframework.org/schema/security/spring-security-3.2.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd"> http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd">
<http access-denied-page="/access-denied.html" use-expressions="true"> <http access-denied-page="/access-denied.html" use-expressions="true">

View File

@ -116,11 +116,14 @@
<httpclient.version>4.3.1</httpclient.version> <httpclient.version>4.3.1</httpclient.version>
<rest-assured.version>2.1.0</rest-assured.version> <rest-assured.version>2.1.0</rest-assured.version>
<groovy.version>1.8.9</groovy.version>
<!-- Maven plugins --> <!-- Maven plugins -->
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version> <maven-compiler-plugin.version>3.1</maven-compiler-plugin.version>
<maven-war-plugin.version>2.4</maven-war-plugin.version>
<maven-surefire-plugin.version>2.16</maven-surefire-plugin.version> <maven-surefire-plugin.version>2.16</maven-surefire-plugin.version>
<maven-resources-plugin.version>2.6</maven-resources-plugin.version>
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version>
</properties> </properties>
</project> </project>

View File

@ -2,7 +2,7 @@
<beans:beans xmlns="http://www.springframework.org/schema/security" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" <beans:beans xmlns="http://www.springframework.org/schema/security" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:beans="http://www.springframework.org/schema/beans" xmlns:beans="http://www.springframework.org/schema/beans"
xsi:schemaLocation=" xsi:schemaLocation="
http://www.springframework.org/schema/security http://www.springframework.org/schema/security/spring-security-3.1.xsd http://www.springframework.org/schema/security http://www.springframework.org/schema/security/spring-security-3.2.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd"> http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd">
<http access-denied-page="/access-denied.html" use-expressions="true"> <http access-denied-page="/access-denied.html" use-expressions="true">

View File

@ -180,7 +180,7 @@
<properties> <properties>
<!-- Spring --> <!-- Spring -->
<org.springframework.version>3.2.6.RELEASE</org.springframework.version> <org.springframework.version>3.2.6.RELEASE</org.springframework.version>
<org.springframework.security.version>3.1.4.RELEASE</org.springframework.security.version> <org.springframework.security.version>3.2.0.RELEASE</org.springframework.security.version>
<!-- persistence --> <!-- persistence -->
<hibernate.version>4.3.0.Final</hibernate.version> <hibernate.version>4.3.0.Final</hibernate.version>
@ -206,11 +206,14 @@
<httpclient.version>4.3.1</httpclient.version> <httpclient.version>4.3.1</httpclient.version>
<rest-assured.version>2.1.0</rest-assured.version> <rest-assured.version>2.1.0</rest-assured.version>
<groovy.version>1.8.9</groovy.version>
<!-- Maven plugins --> <!-- Maven plugins -->
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version> <maven-compiler-plugin.version>3.1</maven-compiler-plugin.version>
<maven-war-plugin.version>2.4</maven-war-plugin.version>
<maven-surefire-plugin.version>2.16</maven-surefire-plugin.version> <maven-surefire-plugin.version>2.16</maven-surefire-plugin.version>
<maven-resources-plugin.version>2.6</maven-resources-plugin.version>
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version>
</properties> </properties>
</project> </project>

View File

@ -2,7 +2,7 @@
<beans:beans xmlns="http://www.springframework.org/schema/security" <beans:beans xmlns="http://www.springframework.org/schema/security"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans"
xsi:schemaLocation=" xsi:schemaLocation="
http://www.springframework.org/schema/security http://www.springframework.org/schema/security/spring-security-3.1.xsd http://www.springframework.org/schema/security http://www.springframework.org/schema/security/spring-security-3.2.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd"> http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd">
<http pattern="/securityNone" security="none" /> <http pattern="/securityNone" security="none" />

View File

@ -1,4 +1,5 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<groupId>org.baeldung</groupId> <groupId>org.baeldung</groupId>
<artifactId>spring-security-mvc-custom</artifactId> <artifactId>spring-security-mvc-custom</artifactId>
@ -184,7 +185,7 @@
<properties> <properties>
<!-- Spring --> <!-- Spring -->
<org.springframework.version>3.2.6.RELEASE</org.springframework.version> <org.springframework.version>3.2.6.RELEASE</org.springframework.version>
<org.springframework.security.version>3.1.4.RELEASE</org.springframework.security.version> <org.springframework.security.version>3.2.0.RELEASE</org.springframework.security.version>
<!-- persistence --> <!-- persistence -->
<hibernate.version>4.3.0.Final</hibernate.version> <hibernate.version>4.3.0.Final</hibernate.version>
@ -210,11 +211,14 @@
<httpcore.version>4.3</httpcore.version> <httpcore.version>4.3</httpcore.version>
<rest-assured.version>2.1.0</rest-assured.version> <rest-assured.version>2.1.0</rest-assured.version>
<groovy.version>1.8.9</groovy.version>
<!-- Maven plugins --> <!-- Maven plugins -->
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version> <maven-compiler-plugin.version>3.1</maven-compiler-plugin.version>
<maven-war-plugin.version>2.4</maven-war-plugin.version>
<maven-surefire-plugin.version>2.16</maven-surefire-plugin.version> <maven-surefire-plugin.version>2.16</maven-surefire-plugin.version>
<maven-resources-plugin.version>2.6</maven-resources-plugin.version>
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version>
</properties> </properties>
</project> </project>

View File

@ -2,7 +2,7 @@
<beans:beans xmlns="http://www.springframework.org/schema/security" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans" <beans:beans xmlns="http://www.springframework.org/schema/security" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans"
xsi:schemaLocation=" xsi:schemaLocation="
http://www.springframework.org/schema/security http://www.springframework.org/schema/security
http://www.springframework.org/schema/security/spring-security-3.1.xsd http://www.springframework.org/schema/security/spring-security-3.2.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-3.2.xsd"> http://www.springframework.org/schema/beans/spring-beans-3.2.xsd">

View File

@ -180,7 +180,7 @@
<properties> <properties>
<!-- Spring --> <!-- Spring -->
<org.springframework.version>3.2.6.RELEASE</org.springframework.version> <org.springframework.version>3.2.6.RELEASE</org.springframework.version>
<org.springframework.security.version>3.1.4.RELEASE</org.springframework.security.version> <org.springframework.security.version>3.2.0.RELEASE</org.springframework.security.version>
<!-- persistence --> <!-- persistence -->
<hibernate.version>4.3.0.Final</hibernate.version> <hibernate.version>4.3.0.Final</hibernate.version>
@ -206,11 +206,14 @@
<httpclient.version>4.3.1</httpclient.version> <httpclient.version>4.3.1</httpclient.version>
<rest-assured.version>2.1.0</rest-assured.version> <rest-assured.version>2.1.0</rest-assured.version>
<groovy.version>1.8.9</groovy.version>
<!-- Maven plugins --> <!-- Maven plugins -->
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version> <maven-compiler-plugin.version>3.1</maven-compiler-plugin.version>
<maven-war-plugin.version>2.4</maven-war-plugin.version>
<maven-surefire-plugin.version>2.16</maven-surefire-plugin.version> <maven-surefire-plugin.version>2.16</maven-surefire-plugin.version>
<maven-resources-plugin.version>2.6</maven-resources-plugin.version>
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version>
</properties> </properties>
</project> </project>

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<beans:beans xmlns="http://www.springframework.org/schema/security" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans" <beans:beans xmlns="http://www.springframework.org/schema/security" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans"
xsi:schemaLocation=" xsi:schemaLocation="
http://www.springframework.org/schema/security http://www.springframework.org/schema/security/spring-security-3.1.xsd http://www.springframework.org/schema/security http://www.springframework.org/schema/security/spring-security-3.2.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd"> http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd">
<beans:bean id="digestFilter" class="org.springframework.security.web.authentication.www.DigestAuthenticationFilter"> <beans:bean id="digestFilter" class="org.springframework.security.web.authentication.www.DigestAuthenticationFilter">

View File

@ -1,4 +1,5 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<groupId>org.baeldung</groupId> <groupId>org.baeldung</groupId>
<artifactId>spring-security-mvc-login</artifactId> <artifactId>spring-security-mvc-login</artifactId>
@ -176,7 +177,7 @@
<properties> <properties>
<!-- Spring --> <!-- Spring -->
<org.springframework.version>3.2.6.RELEASE</org.springframework.version> <org.springframework.version>3.2.6.RELEASE</org.springframework.version>
<org.springframework.security.version>3.1.4.RELEASE</org.springframework.security.version> <org.springframework.security.version>3.2.0.RELEASE</org.springframework.security.version>
<!-- persistence --> <!-- persistence -->
<hibernate.version>4.3.0.Final</hibernate.version> <hibernate.version>4.3.0.Final</hibernate.version>
@ -202,11 +203,14 @@
<httpclient.version>4.3.1</httpclient.version> <httpclient.version>4.3.1</httpclient.version>
<rest-assured.version>2.1.0</rest-assured.version> <rest-assured.version>2.1.0</rest-assured.version>
<groovy.version>1.8.9</groovy.version>
<!-- Maven plugins --> <!-- Maven plugins -->
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version> <maven-compiler-plugin.version>3.1</maven-compiler-plugin.version>
<maven-war-plugin.version>2.4</maven-war-plugin.version>
<maven-surefire-plugin.version>2.16</maven-surefire-plugin.version> <maven-surefire-plugin.version>2.16</maven-surefire-plugin.version>
<maven-resources-plugin.version>2.6</maven-resources-plugin.version>
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version>
</properties> </properties>
</project> </project>

View File

@ -3,30 +3,26 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans"
xsi:schemaLocation=" xsi:schemaLocation="
http://www.springframework.org/schema/security http://www.springframework.org/schema/security
http://www.springframework.org/schema/security/spring-security-3.1.xsd http://www.springframework.org/schema/security/spring-security-3.2.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-3.2.xsd"> http://www.springframework.org/schema/beans/spring-beans-3.2.xsd">
<http use-expressions="true" > <http use-expressions="true">
<intercept-url pattern="/anonymous*" access="isAnonymous()" /> <intercept-url pattern="/anonymous*" access="isAnonymous()" />
<intercept-url pattern="/login*" access="permitAll" /> <intercept-url pattern="/login*" access="permitAll" />
<intercept-url pattern="/**" access="isAuthenticated()" /> <intercept-url pattern="/**" access="isAuthenticated()" />
<form-login <form-login login-page='/login.html' login-processing-url="/perform_login"
login-page='/login.html' default-target-url="/homepage.html" authentication-failure-url="/login.html?error=true"
login-processing-url="/perform_login" always-use-default-target="true" />
default-target-url="/homepage.html"
authentication-failure-url="/login.html?error=true"
always-use-default-target="true"/>
<logout <logout logout-url="/perform_logout" delete-cookies="JSESSIONID"
logout-url="/perform_logout"
delete-cookies="JSESSIONID"
success-handler-ref="customLogoutSuccessHandler" /> success-handler-ref="customLogoutSuccessHandler" />
</http> </http>
<beans:bean name="customLogoutSuccessHandler" class="org.baeldung.security.CustomLogoutSuccessHandler" /> <beans:bean name="customLogoutSuccessHandler"
class="org.baeldung.security.CustomLogoutSuccessHandler" />
<authentication-manager> <authentication-manager>
<authentication-provider> <authentication-provider>

View File

@ -1,4 +1,5 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<groupId>org.baeldung</groupId> <groupId>org.baeldung</groupId>
<artifactId>spring-security-mvc-session</artifactId> <artifactId>spring-security-mvc-session</artifactId>
@ -184,7 +185,7 @@
<properties> <properties>
<!-- Spring --> <!-- Spring -->
<org.springframework.version>3.2.6.RELEASE</org.springframework.version> <org.springframework.version>3.2.6.RELEASE</org.springframework.version>
<org.springframework.security.version>3.1.4.RELEASE</org.springframework.security.version> <org.springframework.security.version>3.2.0.RELEASE</org.springframework.security.version>
<!-- persistence --> <!-- persistence -->
<hibernate.version>4.3.0.Final</hibernate.version> <hibernate.version>4.3.0.Final</hibernate.version>
@ -210,11 +211,14 @@
<httpcore.version>4.3</httpcore.version> <httpcore.version>4.3</httpcore.version>
<rest-assured.version>2.1.0</rest-assured.version> <rest-assured.version>2.1.0</rest-assured.version>
<groovy.version>1.8.9</groovy.version>
<!-- Maven plugins --> <!-- Maven plugins -->
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version> <maven-compiler-plugin.version>3.1</maven-compiler-plugin.version>
<maven-war-plugin.version>2.4</maven-war-plugin.version>
<maven-surefire-plugin.version>2.16</maven-surefire-plugin.version> <maven-surefire-plugin.version>2.16</maven-surefire-plugin.version>
<maven-resources-plugin.version>2.6</maven-resources-plugin.version>
<cargo-maven2-plugin.version>1.4.5</cargo-maven2-plugin.version>
</properties> </properties>
</project> </project>

View File

@ -2,7 +2,7 @@
<beans:beans xmlns="http://www.springframework.org/schema/security" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans" <beans:beans xmlns="http://www.springframework.org/schema/security" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans"
xsi:schemaLocation=" xsi:schemaLocation="
http://www.springframework.org/schema/security http://www.springframework.org/schema/security
http://www.springframework.org/schema/security/spring-security-3.1.xsd http://www.springframework.org/schema/security/spring-security-3.2.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-3.2.xsd"> http://www.springframework.org/schema/beans/spring-beans-3.2.xsd">