You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@stratos.apache.org by ni...@apache.org on 2014/10/11 20:47:03 UTC
[39/50] [abbrv] git commit: Fixed trying to decrypt empty password
Fixed issue in CEPPublisherConfiguration
Fixed trying to decrypt empty password
Fixed issue in CEPPublisherConfiguration
Project: http://git-wip-us.apache.org/repos/asf/stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/stratos/commit/c4c5f75e
Tree: http://git-wip-us.apache.org/repos/asf/stratos/tree/c4c5f75e
Diff: http://git-wip-us.apache.org/repos/asf/stratos/diff/c4c5f75e
Branch: refs/heads/master
Commit: c4c5f75e12c689cbcb01fe90bff866c8ced63eda
Parents: 4955598
Author: Chamila de Alwis <ch...@wso2.com>
Authored: Sat Oct 11 18:16:41 2014 +0530
Committer: Chamila de Alwis <ch...@wso2.com>
Committed: Sat Oct 11 18:16:41 2014 +0530
----------------------------------------------------------------------
.../cartridge-agent/modules/healthstatspublisher/healthstats.py | 4 ++--
.../cartridge-agent/modules/util/cartridgeagentutils.py | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/stratos/blob/c4c5f75e/tools/python-cartridge-agent/cartridge-agent/modules/healthstatspublisher/healthstats.py
----------------------------------------------------------------------
diff --git a/tools/python-cartridge-agent/cartridge-agent/modules/healthstatspublisher/healthstats.py b/tools/python-cartridge-agent/cartridge-agent/modules/healthstatspublisher/healthstats.py
index ddc2543..aafe4db 100644
--- a/tools/python-cartridge-agent/cartridge-agent/modules/healthstatspublisher/healthstats.py
+++ b/tools/python-cartridge-agent/cartridge-agent/modules/healthstatspublisher/healthstats.py
@@ -199,10 +199,10 @@ class CEPPublisherConfiguration:
self.server_port = None
self.admin_username = None
self.admin_password = None
- self.read_config()
-
self.cartridge_agent_config = CartridgeAgentConfiguration()
+ self.read_config()
+
def read_config(self):
self.enabled = True if self.cartridge_agent_config.read_property(
cartridgeagentconstants.CEP_PUBLISHER_ENABLED, False).strip().lower() == "true" else False
http://git-wip-us.apache.org/repos/asf/stratos/blob/c4c5f75e/tools/python-cartridge-agent/cartridge-agent/modules/util/cartridgeagentutils.py
----------------------------------------------------------------------
diff --git a/tools/python-cartridge-agent/cartridge-agent/modules/util/cartridgeagentutils.py b/tools/python-cartridge-agent/cartridge-agent/modules/util/cartridgeagentutils.py
index 556a348..42a7dd5 100644
--- a/tools/python-cartridge-agent/cartridge-agent/modules/util/cartridgeagentutils.py
+++ b/tools/python-cartridge-agent/cartridge-agent/modules/util/cartridgeagentutils.py
@@ -41,8 +41,8 @@ def decrypt_password(pass_str, secret):
:rtype: str
"""
- if pass_str is None:
- return pass_str
+ if pass_str is None or pass_str.strip() == "":
+ return pass_str.strip()
dec_pass = ""