Remove logged chap secret (#53287)

pull/55101/head
ndswartz 6 years ago committed by ansibot
parent de14cd7ae8
commit eee51486fd

@ -157,7 +157,7 @@ class IscsiTarget(object):
if not self.url.endswith('/'): if not self.url.endswith('/'):
self.url += '/' self.url += '/'
self._logger.info(self.chap_secret)
if self.chap_secret is not None: if self.chap_secret is not None:
if len(self.chap_secret) < 12 or len(self.chap_secret) > 16: if len(self.chap_secret) < 12 or len(self.chap_secret) > 16:
self.module.fail_json(msg="The provided CHAP secret is not valid, it must be between 12 and 16" self.module.fail_json(msg="The provided CHAP secret is not valid, it must be between 12 and 16"
@ -235,8 +235,6 @@ class IscsiTarget(object):
update = True update = True
body.update(dict(enableChapAuthentication=False)) body.update(dict(enableChapAuthentication=False))
self._logger.info(pformat(body))
if update and not self.check_mode: if update and not self.check_mode:
try: try:
request(self.url + 'storage-systems/%s/iscsi/target-settings' % self.ssid, method='POST', request(self.url + 'storage-systems/%s/iscsi/target-settings' % self.ssid, method='POST',

Loading…
Cancel
Save