Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Azure Pipes prints password and SQL Connection String as cleartext to build log

Stefan Naegeli April 26, 2019

When using Azure Pipes to deploy an Azure Web App while having the DEBUG flag to true, in one statement the logger logs the <publishData> response to the build log.

<publishData>...</publishData> not only contains the user password as cleartext but also the SQL Server connection string including the user and password.

This seems to be a security threat because anyone who can enable the Debug flag can get access to the deployment password and database login credentials.

1 answer

1 accepted

0 votes
Answer accepted
Raul Gomis
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
May 3, 2019

Hey @Stefan Naegeli 

Thanks for raising this issue. I have notified the Microsoft team and they are looking into this. 

I strongly agree with you that credentials shouldn't be exposed. After investigating the issue, it's related to the Azure CLI: It prints the password when you pass the --debug flag to the CLI deploy command.

Let me clarify, the credentials that are exposed are from the PublishProfile (credentials that Azure Web Apps generates to allow publishing your application from IDE for example). Your Azure Credentials (i.e. Service Principal) that give you access to your account / resources are not exposed. 

For example, this command would print the whole PublishProfile (user and password included): 

az webapp deployment source config-zip --resource-group example-azure-web-apps-deploy --name example-azure-web-apps-deploy --src app.zip --debug 

(You can see the source code here: https://bitbucket.org/microsoft/azure-web-apps-deploy)

Unfortunately, this would happen even using raw commands (i.e. without using the pipe), as we depend on the Azure CLI to execute the command, and we cannot prevent this.

For now, if your publishProfile has been exposed in the logs, I would suggest rotating it ("Reset Publish Profile" from the Azure Portal) and not using DEBUG mode unless you need to debug any problem with your deployment.

Thanks again for your feedback,

Raul

Stefan Naegeli May 5, 2019

Hi Raul

Thanks for raising this with Microsoft. Can you share an Issue-Link to watch or will you post again on this thread when you get an update? 

You are correct: not the Service Principal but the content of the publish profile is exposed. This is unfortunate as the publish profile might also contain the SQL Connection string including the login user and password.

Best regards,
Stefan

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events