Previously, data which may be considered sensitive such as the X-Auth-Token or X-Storage-Token headers is hidden for the --info option but not --debug. This patch enables truncating of LOGGER_SENSITIVE_HEADERS by default for --debug so that end users can share debug output more easily without having to manually sanitize logs and adds unit tests for it. A separate --debug-with-secrets option is provided should explicit printing of auth tokens be desirable, mimicking the old behaviour. --debug-insecure, suggested on launchpad naming was considered as well however a --insecure param which skips SSL verification already exists and does something else. The --with-secrets suffix should also help make the purpose of this param explicit enough. Closes-Bug: #2061011 Closes-Bug: #2061012 Change-Id: Ie64b0f496c016a5871de7ada84acb572c008d127
91 KiB
Executable File
91 KiB
Executable File