CI Pipeline expose secrets

There is a trick to recover a stored secret variable of the CI/CD pipeline if you canโ€™t remember its value. The pipeline tries to hide the value of its secrets in the debugging output, but it can be revealed with the following script:

1
2
3
Write-Host "This will not be displayed: $($Env:SuperSecret)"
Write-Host "This will not be displayed: $($Env:MappedSecred)"
Write-Host "This will be displayed: $($Env:MappedSecred.ToCharArray())"

pipeline variables

pipeline variables