You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by co...@apache.org on 2019/11/11 18:03:04 UTC

[camel] 01/04: Use SecureRandom to generate the as2 message Id

This is an automated email from the ASF dual-hosted git repository.

coheigea pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 6f1b82fe708e0facbc8b6b4855861ab09fd10043
Author: Colm O hEigeartaigh <co...@apache.org>
AuthorDate: Mon Nov 11 15:15:34 2019 +0000

    Use SecureRandom to generate the as2 message Id
---
 .../main/java/org/apache/camel/component/as2/api/util/AS2Utils.java   | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/components/camel-as2/camel-as2-api/src/main/java/org/apache/camel/component/as2/api/util/AS2Utils.java b/components/camel-as2/camel-as2-api/src/main/java/org/apache/camel/component/as2/api/util/AS2Utils.java
index a5d4c40..2e50e67 100644
--- a/components/camel-as2/camel-as2-api/src/main/java/org/apache/camel/component/as2/api/util/AS2Utils.java
+++ b/components/camel-as2/camel-as2-api/src/main/java/org/apache/camel/component/as2/api/util/AS2Utils.java
@@ -21,7 +21,7 @@ import java.io.ByteArrayOutputStream;
 import java.io.IOException;
 import java.io.PrintStream;
 import java.nio.charset.StandardCharsets;
-import java.util.Random;
+import java.security.SecureRandom;
 import java.util.regex.Matcher;
 import java.util.regex.Pattern;
 
@@ -53,7 +53,7 @@ public final class AS2Utils {
 
     public static final Pattern AS_NAME_PATTERN = Pattern.compile(AS2_NAME);
 
-    private static Random generator = new Random();
+    private static SecureRandom generator = new SecureRandom();
 
     private AS2Utils() {
     }