Skip to content

Redact SSH key from URL query parameter#348

Merged
schmichael merged 2 commits into
hashicorp:mainfrom
macedogm:sshkey-redact
Jan 3, 2022
Merged

Redact SSH key from URL query parameter#348
schmichael merged 2 commits into
hashicorp:mainfrom
macedogm:sshkey-redact

Conversation

@macedogm

@macedogm macedogm commented Jan 3, 2022

Copy link
Copy Markdown
Contributor

This PR changes:

  1. Redact SSH key from URL query parameter when printing the URL after a download error happens.
  2. Changed redaction from xxxxx to redacted.
  3. Added two tests for the SSH key redaction.
  4. Added .gitignore.

Signed-off-by: Guilherme Macedo guilherme.macedo@suse.com

Signed-off-by: Guilherme Macedo <guilherme.macedo@suse.com>
@hashicorp-cla

hashicorp-cla commented Jan 3, 2022

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

Signed-off-by: Guilherme Macedo <guilherme.macedo@suse.com>
@schmichael

Copy link
Copy Markdown
Member

Thanks @macedogm!

Doesn't look like any HashiCorp tooling calls RedactURL directly, and we don't universally guarantee error string backward compatibility, so this seems safe to merge from a compatibility standpoint. Code looks good too!

@schmichael schmichael merged commit f5cbbb4 into hashicorp:main Jan 3, 2022
@macedogm macedogm deleted the sshkey-redact branch January 3, 2022 23:14
@macedogm

macedogm commented Jan 5, 2022

Copy link
Copy Markdown
Contributor Author

@schmichael Thanks a lot for the quick review. 👍🏻

@macedogm

Copy link
Copy Markdown
Contributor Author

Hi @schmichael, do you know when a new release will be made with this fix, please?

@schmichael

Copy link
Copy Markdown
Member

Done! Unsure when it will make it into downstream tools (Terraform, Nomad, etc) though.

@msmeissn

Copy link
Copy Markdown

Mitre assigned CVE-2022-29810 to this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants