From 17af21e717d343bb11eb0e875fa1b88ae7dd7361 Mon Sep 17 00:00:00 2001 From: Guilherme Macedo Date: Mon, 3 Jan 2022 11:30:47 +0100 Subject: [PATCH] Redact SSH key from URL query parameter Signed-off-by: Guilherme Macedo --- url.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/url.go b/url.go index 98b73da4b..a9aed7f50 100644 --- a/url.go +++ b/url.go @@ -3,9 +3,10 @@ package getter import "net/url" // RedactURL is a port of url.Redacted from the standard library, -// which is like url.String but replaces any password with "xxxxx". +// which is like url.String but replaces any password with "redacted". // Only the password in u.URL is redacted. This allows the library // to maintain compatibility with go1.14. +// This port was also extended to redact SSH key from URL query parameter. func RedactURL(u *url.URL) string { if u == nil { return ""