Skip to content

Commit

Permalink
add extra sanitation strings
Browse files Browse the repository at this point in the history
  • Loading branch information
lmayorga1980 committed Jul 2, 2024
1 parent 80c806f commit 48693e5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion provisioner/ansible/provisioner.go
Original file line number Diff line number Diff line change
Expand Up @@ -931,7 +931,9 @@ func (p *Provisioner) executeAnsible(ui packersdk.Ui, comm packersdk.Communicato
continue
}
if strings.Contains(strings.ToLower(args[0]), "password") ||
strings.Contains(strings.ToLower(args[0]), "secret") {
strings.Contains(strings.ToLower(args[0]), "secret") ||
strings.Contains(strings.ToLower(args[0]), "token") ||
strings.Contains(strings.ToLower(args[0]), "key") {
sanitized = strings.Replace(sanitized,
args[1], "*****", -1)
}
Expand Down

0 comments on commit 48693e5

Please sign in to comment.