From c533c7a9a2b35e0ffeef97ae3c88a2557c8401d0 Mon Sep 17 00:00:00 2001 From: rkillen Date: Wed, 25 Apr 2018 16:50:06 -0500 Subject: [PATCH] Issue#84 - Avoid displaying password fields as part of entry logging. Password fields appear as , consistent with other logging. Fixes #84 --- core/src/main/python/wlsdeploy/aliases/alias_entries.py | 2 +- core/src/main/python/wlsdeploy/tool/validate/validator.py | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/core/src/main/python/wlsdeploy/aliases/alias_entries.py b/core/src/main/python/wlsdeploy/aliases/alias_entries.py index de2f3cb2c7..da2a8452a3 100644 --- a/core/src/main/python/wlsdeploy/aliases/alias_entries.py +++ b/core/src/main/python/wlsdeploy/aliases/alias_entries.py @@ -155,7 +155,7 @@ class AliasEntries(object): __domain_info_attributes_and_types = { 'AdminUserName': 'string', - 'AdminPassword': 'string', + 'AdminPassword': 'password', 'ServerStartMode': 'string', 'domainLibraries': 'list', # A map of Server Group names to the list of servers/clusters to which they should diff --git a/core/src/main/python/wlsdeploy/tool/validate/validator.py b/core/src/main/python/wlsdeploy/tool/validate/validator.py index c381de5237..78305c0f4d 100644 --- a/core/src/main/python/wlsdeploy/tool/validate/validator.py +++ b/core/src/main/python/wlsdeploy/tool/validate/validator.py @@ -715,7 +715,12 @@ def __validate_attribute(self, attribute_name, attribute_value, valid_attr_infos model_folder_path, validation_location, validation_result): _method_name = '__validate_attribute' - self._logger.entering(attribute_name, attribute_value, str(valid_attr_infos), str(path_tokens_attr_keys), + log_value = attribute_value + expected_data_type = dictionary_utils.get_element(valid_attr_infos, attribute_name) + if expected_data_type == 'password': + log_value = '' + + self._logger.entering(attribute_name, log_value, str(valid_attr_infos), str(path_tokens_attr_keys), model_folder_path, str(validation_location), class_name=_class_name, method_name=_method_name)