MAILET-144 Use the same certificate in all SMIME tests (end of validity in 2044)


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/bc0d0a30
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/bc0d0a30
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/bc0d0a30

Branch: refs/heads/master
Commit: bc0d0a30484afb61bcf492194ea629bb03548ab5
Parents: 46afd92
Author: Antoine Duprat <adup...@linagora.com>
Authored: Wed Jan 4 13:40:18 2017 +0100
Committer: Antoine Duprat <adup...@linagora.com>
Committed: Mon Jan 30 10:33:26 2017 +0100

----------------------------------------------------------------------
 .../james/mailets/TemporaryFilesystemModule.java    |   1 -
 .../mailets/crypto/SMIMESignIntegrationTest.java    |   9 +++------
 .../src/test/resources/smime_1.p12                  | Bin 4069 -> 0 bytes
 3 files changed, 3 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/bc0d0a30/server/mailet/integration-testing/src/test/java/org/apache/james/mailets/TemporaryFilesystemModule.java
----------------------------------------------------------------------
diff --git 
a/server/mailet/integration-testing/src/test/java/org/apache/james/mailets/TemporaryFilesystemModule.java
 
b/server/mailet/integration-testing/src/test/java/org/apache/james/mailets/TemporaryFilesystemModule.java
index 7e6786d..d470352 100644
--- 
a/server/mailet/integration-testing/src/test/java/org/apache/james/mailets/TemporaryFilesystemModule.java
+++ 
b/server/mailet/integration-testing/src/test/java/org/apache/james/mailets/TemporaryFilesystemModule.java
@@ -54,7 +54,6 @@ public class TemporaryFilesystemModule extends AbstractModule 
{
             "recipientrewritetable.xml",
             "smtpserver.xml",
             "usersrepository.xml",
-            "smime_1.p12",
             "smime.p12");
 
     private final Supplier<File> workingDirectory;

http://git-wip-us.apache.org/repos/asf/james-project/blob/bc0d0a30/server/mailet/integration-testing/src/test/java/org/apache/james/mailets/crypto/SMIMESignIntegrationTest.java
----------------------------------------------------------------------
diff --git 
a/server/mailet/integration-testing/src/test/java/org/apache/james/mailets/crypto/SMIMESignIntegrationTest.java
 
b/server/mailet/integration-testing/src/test/java/org/apache/james/mailets/crypto/SMIMESignIntegrationTest.java
index 4ff2af1..20992b0 100644
--- 
a/server/mailet/integration-testing/src/test/java/org/apache/james/mailets/crypto/SMIMESignIntegrationTest.java
+++ 
b/server/mailet/integration-testing/src/test/java/org/apache/james/mailets/crypto/SMIMESignIntegrationTest.java
@@ -44,7 +44,6 @@ import com.jayway.awaitility.core.ConditionFactory;
 
 public class SMIMESignIntegrationTest {
 
-
     private static final ZonedDateTime DATE_2015 = 
ZonedDateTime.parse("2015-10-15T14:10:00Z");
     private static final String DEFAULT_DOMAIN = "domain";
     private static final String LOCALHOST_IP = "127.0.0.1";
@@ -63,8 +62,6 @@ public class SMIMESignIntegrationTest {
 
     @Before
     public void setup() throws Exception {
-        temporaryFolder.newFile("smime.pk12");
-
         MailetContainer mailetContainer = MailetContainer.builder()
             .postmaster("postmaster@" + DEFAULT_DOMAIN)
             .threads(5)
@@ -101,8 +98,8 @@ public class SMIMESignIntegrationTest {
                 .addMailet(MailetConfiguration.builder()
                     .clazz("SMIMESign")
                     .match("SenderIsLocal")
-                    .addProperty("keyStoreFileName", 
temporaryFolder.getRoot().getAbsoluteFile().getAbsolutePath() + 
"/conf/smime_1.p12")
-                    .addProperty("keyStorePassword", "totototo")
+                    .addProperty("keyStoreFileName", 
temporaryFolder.getRoot().getAbsoluteFile().getAbsolutePath() + 
"/conf/smime.p12")
+                    .addProperty("keyStorePassword", "secret")
                     .addProperty("keyStoreType", "PKCS12")
                     .addProperty("debug", "true")
                     .build())
@@ -135,7 +132,7 @@ public class SMIMESignIntegrationTest {
             .build();
 
         jamesServer = new TemporaryJamesServer(temporaryFolder, 
mailetContainer,
-            binder -> binder.bind(ZonedDateTimeProvider.class).toInstance(() 
-> DATE_2015));
+                binder -> 
binder.bind(ZonedDateTimeProvider.class).toInstance(() -> DATE_2015));
         Duration slowPacedPollInterval = Duration.FIVE_HUNDRED_MILLISECONDS;
         calmlyAwait = 
Awaitility.with().pollInterval(slowPacedPollInterval).and().with().pollDelay(slowPacedPollInterval).await();
 

http://git-wip-us.apache.org/repos/asf/james-project/blob/bc0d0a30/server/mailet/integration-testing/src/test/resources/smime_1.p12
----------------------------------------------------------------------
diff --git a/server/mailet/integration-testing/src/test/resources/smime_1.p12 
b/server/mailet/integration-testing/src/test/resources/smime_1.p12
deleted file mode 100644
index 8a91933..0000000
Binary files a/server/mailet/integration-testing/src/test/resources/smime_1.p12 
and /dev/null differ


---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscr...@james.apache.org
For additional commands, e-mail: server-dev-h...@james.apache.org

Reply via email to