You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
INFO:Redacting sensitive information from configuration ./config/config-template-nessus.yaml
Traceback (most recent call last):
File "/home/cedric/prodsec/rapidast/rapidast/./rapidast.py", line 292, in <module>
run()
File "/home/cedric/prodsec/rapidast/rapidast/./rapidast.py", line 232, in run
dump_rapidast_redacted_configs(config_file, full_result_dir_path)
File "/home/cedric/prodsec/rapidast/rapidast/./rapidast.py", line 183, in dump_rapidast_redacted_configs
if not dump_redacted_config(main_config_file_location, destination_dir):
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/cedric/prodsec/rapidast/rapidast/./rapidast.py", line 158, in dump_redacted_config
if config[key].get("authentication") and config[key]["authentication"].get("parameters"):
^^^^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'get'
The issue is that some root config (e.g.: general in particular) may be empty, which is translated into None by the YAML translator.
The following modification would resolve it, I think:
156 logging.info(f"Redacting sensitive information from configuration {config_file_location}")
157 for key in config.keys():
158 if isinstance(config[key], dict) and config[key].get("authentication") and config[key]["authentication"].get("parameters"):
159 for param in config[key]["authentication"]["parameters"]:
160 config[key]["authentication"]["parameters"][param] = "*****"
The text was updated successfully, but these errors were encountered:
This happens when loading the currently proposed config nessus template (https://github.com/RedHatProductSecurity/rapidast/blob/nessus/config/config-template-nessus.yaml).
The issue is that some root config (e.g.:
general
in particular) may be empty, which is translated intoNone
by the YAML translator.The following modification would resolve it, I think:
The text was updated successfully, but these errors were encountered: