Scrub token from logs

This commit is contained in:
sophia 2020-08-18 10:51:42 -05:00
parent b5f6df9ec0
commit f440012b30

View File

@ -1,6 +1,8 @@
require "cgi"
require "uri"
require "vagrant/util/credential_scrubber"
require Vagrant.source_root.join("plugins/commands/cloud/client/client")
module VagrantPlugins
@ -34,6 +36,7 @@ module VagrantPlugins
client = Client.new(env[:env])
token = client.token
target_url = URI.parse(env[:downloader].source)
Vagrant::Util::CredentialScrubber.sensitive(token)
if target_url.host != TARGET_HOST && REPLACEMENT_HOSTS.include?(target_url.host)
begin