SEC-674: Created new project modules for cas, captcha, acls and taglibs
This commit is contained in:
parent
59651f5214
commit
2dd9faabc0
|
@ -0,0 +1,50 @@
|
||||||
|
<?xml version="1.0"?>
|
||||||
|
<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/maven-v4_0_0.xsd">
|
||||||
|
<parent>
|
||||||
|
<artifactId>spring-security-parent</artifactId>
|
||||||
|
<groupId>org.springframework.security</groupId>
|
||||||
|
<version>2.0-SNAPSHOT</version>
|
||||||
|
</parent>
|
||||||
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
<groupId>org.springframework.security</groupId>
|
||||||
|
<artifactId>spring-security-acl</artifactId>
|
||||||
|
<name>Spring Security - ACL Module</name>
|
||||||
|
<version>2.0-SNAPSHOT</version>
|
||||||
|
|
||||||
|
<dependencies>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework.security</groupId>
|
||||||
|
<artifactId>spring-security-core</artifactId>
|
||||||
|
<version>${project.version}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework.security</groupId>
|
||||||
|
<artifactId>spring-security-core</artifactId>
|
||||||
|
<version>${project.version}</version>
|
||||||
|
<classifier>tests</classifier>
|
||||||
|
<scope>test</scope>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework</groupId>
|
||||||
|
<artifactId>spring-jdbc</artifactId>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework</groupId>
|
||||||
|
<artifactId>spring-mock</artifactId>
|
||||||
|
<scope>test</scope>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>net.sf.ehcache</groupId>
|
||||||
|
<artifactId>ehcache</artifactId>
|
||||||
|
<version>1.2.4</version>
|
||||||
|
<optional>true</optional>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>hsqldb</groupId>
|
||||||
|
<artifactId>hsqldb</artifactId>
|
||||||
|
<version>1.8.0.4</version>
|
||||||
|
<scope>test</scope>
|
||||||
|
</dependency>
|
||||||
|
</dependencies>
|
||||||
|
</project>
|
|
@ -26,9 +26,7 @@
|
||||||
<property name="cacheManager">
|
<property name="cacheManager">
|
||||||
<bean class="org.springframework.cache.ehcache.EhCacheManagerFactoryBean"/>
|
<bean class="org.springframework.cache.ehcache.EhCacheManagerFactoryBean"/>
|
||||||
</property>
|
</property>
|
||||||
<property name="cacheName">
|
<property name="cacheName" value="aclCache"/>
|
||||||
<value>aclCache</value>
|
|
||||||
</property>
|
|
||||||
</bean>
|
</bean>
|
||||||
</constructor-arg>
|
</constructor-arg>
|
||||||
</bean>
|
</bean>
|
|
@ -14,13 +14,9 @@
|
||||||
*/
|
*/
|
||||||
package org.springframework.security.acls.domain;
|
package org.springframework.security.acls.domain;
|
||||||
|
|
||||||
import org.apache.commons.lang.ArrayUtils;
|
|
||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
import org.apache.commons.logging.LogFactory;
|
import org.apache.commons.logging.LogFactory;
|
||||||
import static org.junit.Assert.assertEquals;
|
import static org.junit.Assert.*;
|
||||||
import static org.junit.Assert.assertFalse;
|
|
||||||
import static org.junit.Assert.assertTrue;
|
|
||||||
import static org.junit.Assert.fail;
|
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
import org.springframework.security.acls.Permission;
|
import org.springframework.security.acls.Permission;
|
||||||
|
|
||||||
|
@ -90,12 +86,4 @@ public class PermissionTests {
|
||||||
new CumulativePermission().set(BasePermission.ADMINISTRATION).set(BasePermission.READ)
|
new CumulativePermission().set(BasePermission.ADMINISTRATION).set(BasePermission.READ)
|
||||||
.clear(BasePermission.ADMINISTRATION).clear(BasePermission.READ).toString());
|
.clear(BasePermission.ADMINISTRATION).clear(BasePermission.READ).toString());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
|
@ -35,8 +35,7 @@ import javax.sql.DataSource;
|
||||||
public class DatabaseSeeder {
|
public class DatabaseSeeder {
|
||||||
//~ Constructors ===================================================================================================
|
//~ Constructors ===================================================================================================
|
||||||
|
|
||||||
public DatabaseSeeder(DataSource dataSource, Resource resource)
|
public DatabaseSeeder(DataSource dataSource, Resource resource) throws IOException {
|
||||||
throws IOException {
|
|
||||||
Assert.notNull(dataSource, "dataSource required");
|
Assert.notNull(dataSource, "dataSource required");
|
||||||
Assert.notNull(resource, "resource required");
|
Assert.notNull(resource, "resource required");
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
<artifactId>spring-security-adapters</artifactId>
|
<artifactId>spring-security-adapters</artifactId>
|
||||||
<version>2.0-SNAPSHOT</version>
|
<version>2.0-SNAPSHOT</version>
|
||||||
</parent>
|
</parent>
|
||||||
<artifactId>spring-security-cas</artifactId>
|
<artifactId>spring-security-cas-adapter</artifactId>
|
||||||
<name>Spring Security - CAS adapter</name>
|
<name>Spring Security - CAS adapter</name>
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<dependency>
|
<dependency>
|
||||||
|
|
|
@ -0,0 +1,34 @@
|
||||||
|
<?xml version="1.0"?>
|
||||||
|
<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/maven-v4_0_0.xsd">
|
||||||
|
<parent>
|
||||||
|
<artifactId>spring-security-parent</artifactId>
|
||||||
|
<groupId>org.springframework.security</groupId>
|
||||||
|
<version>2.0-SNAPSHOT</version>
|
||||||
|
</parent>
|
||||||
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
<groupId>org.springframework.security</groupId>
|
||||||
|
<artifactId>spring-security-captcha</artifactId>
|
||||||
|
<name>Spring Security - Catptcha Module</name>
|
||||||
|
<version>2.0-SNAPSHOT</version>
|
||||||
|
|
||||||
|
<dependencies>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework.security</groupId>
|
||||||
|
<artifactId>spring-security-core</artifactId>
|
||||||
|
<version>${project.version}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework.security</groupId>
|
||||||
|
<artifactId>spring-security-core</artifactId>
|
||||||
|
<version>${project.version}</version>
|
||||||
|
<classifier>tests</classifier>
|
||||||
|
<scope>test</scope>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework</groupId>
|
||||||
|
<artifactId>spring-mock</artifactId>
|
||||||
|
<scope>test</scope>
|
||||||
|
</dependency>
|
||||||
|
</dependencies>
|
||||||
|
</project>
|
|
@ -31,6 +31,9 @@ import org.springframework.mock.web.MockHttpServletResponse;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
|
||||||
import javax.servlet.ServletException;
|
import javax.servlet.ServletException;
|
||||||
|
import javax.servlet.FilterChain;
|
||||||
|
import javax.servlet.ServletRequest;
|
||||||
|
import javax.servlet.ServletResponse;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -217,4 +220,10 @@ public class CaptchaChannelProcessorTemplateTests extends TestCase {
|
||||||
return context.isHuman();
|
return context.isHuman();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private static class MockFilterChain implements FilterChain {
|
||||||
|
public void doFilter(ServletRequest arg0, ServletResponse arg1) throws IOException, ServletException {
|
||||||
|
throw new UnsupportedOperationException("mock method not implemented");
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
|
@ -39,16 +39,6 @@ import java.util.Map;
|
||||||
public class CaptchaEntryPointTests extends TestCase {
|
public class CaptchaEntryPointTests extends TestCase {
|
||||||
//~ Methods ========================================================================================================
|
//~ Methods ========================================================================================================
|
||||||
|
|
||||||
public static void main(String[] args) {
|
|
||||||
junit.textui.TestRunner.run(CaptchaEntryPointTests.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// ~ Methods
|
|
||||||
// ================================================================
|
|
||||||
public final void setUp() throws Exception {
|
|
||||||
super.setUp();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void testDetectsMissingCaptchaFormUrl() throws Exception {
|
public void testDetectsMissingCaptchaFormUrl() throws Exception {
|
||||||
CaptchaEntryPoint ep = new CaptchaEntryPoint();
|
CaptchaEntryPoint ep = new CaptchaEntryPoint();
|
||||||
ep.setPortMapper(new PortMapperImpl());
|
ep.setPortMapper(new PortMapperImpl());
|
|
@ -15,7 +15,7 @@
|
||||||
|
|
||||||
package org.springframework.security.captcha;
|
package org.springframework.security.captcha;
|
||||||
|
|
||||||
import org.springframework.security.context.SecurityContextImplTests;
|
import junit.framework.TestCase;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -24,7 +24,7 @@ import org.springframework.security.context.SecurityContextImplTests;
|
||||||
* @author marc antoine Garrigue
|
* @author marc antoine Garrigue
|
||||||
* @version $Id$
|
* @version $Id$
|
||||||
*/
|
*/
|
||||||
public class CaptchaSecurityContextImplTests extends SecurityContextImplTests {
|
public class CaptchaSecurityContextImplTests extends TestCase {
|
||||||
//~ Methods ========================================================================================================
|
//~ Methods ========================================================================================================
|
||||||
|
|
||||||
public void testDefaultValues() {
|
public void testDefaultValues() {
|
|
@ -0,0 +1,22 @@
|
||||||
|
<?xml version="1.0"?>
|
||||||
|
<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/maven-v4_0_0.xsd">
|
||||||
|
<parent>
|
||||||
|
<artifactId>spring-security-cas</artifactId>
|
||||||
|
<groupId>org.springframework.security</groupId>
|
||||||
|
<version>2.0-SNAPSHOT</version>
|
||||||
|
</parent>
|
||||||
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
<groupId>org.springframework.security</groupId>
|
||||||
|
<artifactId>spring-security-cas-client</artifactId>
|
||||||
|
<name>Spring Security - CAS Client Integration</name>
|
||||||
|
<version>2.0-SNAPSHOT</version>
|
||||||
|
|
||||||
|
<dependencies>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework.security</groupId>
|
||||||
|
<artifactId>spring-security-core</artifactId>
|
||||||
|
<version>${project.version}</version>
|
||||||
|
</dependency>
|
||||||
|
</dependencies>
|
||||||
|
</project>
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue