You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by cl...@apache.org on 2018/09/26 13:20:57 UTC

activemq-artemis git commit: ARTEMIS-2087 fix NPE; mask password in example

Repository: activemq-artemis
Updated Branches:
  refs/heads/2.6.x cfb50fe73 -> 4f6a13e0f


ARTEMIS-2087 fix NPE; mask password in example

(cherry picked from commit 5d329a70d197cea551b0e26a55c73d099f5e8093)


Project: http://git-wip-us.apache.org/repos/asf/activemq-artemis/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq-artemis/commit/4f6a13e0
Tree: http://git-wip-us.apache.org/repos/asf/activemq-artemis/tree/4f6a13e0
Diff: http://git-wip-us.apache.org/repos/asf/activemq-artemis/diff/4f6a13e0

Branch: refs/heads/2.6.x
Commit: 4f6a13e0fb3636ad45ad853182d89faa7489e6fa
Parents: cfb50fe
Author: Justin Bertram <jb...@apache.org>
Authored: Tue Sep 25 13:59:51 2018 -0500
Committer: Clebert Suconic <cl...@apache.org>
Committed: Wed Sep 26 09:20:43 2018 -0400

----------------------------------------------------------------------
 .../org/apache/activemq/artemis/utils/PasswordMaskingUtil.java   | 2 +-
 .../jmx-ssl/src/main/resources/activemq/server0/management.xml   | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/4f6a13e0/artemis-commons/src/main/java/org/apache/activemq/artemis/utils/PasswordMaskingUtil.java
----------------------------------------------------------------------
diff --git a/artemis-commons/src/main/java/org/apache/activemq/artemis/utils/PasswordMaskingUtil.java b/artemis-commons/src/main/java/org/apache/activemq/artemis/utils/PasswordMaskingUtil.java
index be56046..796f1d8 100644
--- a/artemis-commons/src/main/java/org/apache/activemq/artemis/utils/PasswordMaskingUtil.java
+++ b/artemis-commons/src/main/java/org/apache/activemq/artemis/utils/PasswordMaskingUtil.java
@@ -61,7 +61,7 @@ public final class PasswordMaskingUtil {
    }
 
    public static boolean isEncMasked(String password) {
-      return (password.startsWith(BEGIN_ENC) && password.endsWith(END_ENC));
+      return password == null ? false : (password.startsWith(BEGIN_ENC) && password.endsWith(END_ENC));
    }
 
    //remove ENC() from the password body

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/4f6a13e0/examples/features/standard/jmx-ssl/src/main/resources/activemq/server0/management.xml
----------------------------------------------------------------------
diff --git a/examples/features/standard/jmx-ssl/src/main/resources/activemq/server0/management.xml b/examples/features/standard/jmx-ssl/src/main/resources/activemq/server0/management.xml
index 802079c..dd15e5c 100644
--- a/examples/features/standard/jmx-ssl/src/main/resources/activemq/server0/management.xml
+++ b/examples/features/standard/jmx-ssl/src/main/resources/activemq/server0/management.xml
@@ -21,9 +21,9 @@
          connector-host="localhost"
          secured="true"
          key-store-path="${data.dir}/../etc/server-side-keystore.jks"
-         key-store-password="secureexample"
+         key-store-password="ENC(2a7c211d21c295cdbcde3589c205decb)"
          trust-store-path="${data.dir}/../etc/server-side-truststore.jks"
-         trust-store-password="secureexample"/>
+         trust-store-password="ENC(2a7c211d21c295cdbcde3589c205decb)"/>
    <authorisation>
       <whitelist>
          <entry domain="hawtio"/>