keesschollaart81 / vsts-arm-outputs

Azure DevOps Pipelines Extension - Use your ARM Deployment outputs
https://marketplace.visualstudio.com/items?itemName=keesschollaart.arm-outputs
MIT License
28 stars 14 forks source link

URL encoding #76

Open DonKarlssonSan opened 4 years ago

DonKarlssonSan commented 4 years ago

We use ARM Outputs in several Azure DevOps Release Pipelines. This week we've noticed that our trigger URLs for Logic Apps get "double encoded".

Expected output: https://prod-57.westeurope.logic.azure.com:443/workflows/GUID/triggers/manual/paths/invoke?api-version=2016-06-01&sp=%2Ftriggers%2Fmanual%2Frun&sv=1.0&sig=CODE

Actual output: https://prod-57.westeurope.logic.azure.com:443/workflows/GUID/triggers/manual/paths/invoke?api-version=2016-06-01&sp=%252Ftriggers%252Fmanual%252Frun&sv=1.0&sig=CODE

As you can see %2F becomes %252F

I noticed that there was a 5.3 release made just recently. I guess we get that automatically because we use Task version 5.*

Can it be a bug introduced in the latest release?

AlexandreColnec commented 4 years ago

I have the same issue. Change the version to 4.* seems to work if your agent is not a unix.

JonnyMattsson commented 4 years ago

I have the same issue. The connectionstring to a sql database that gets a '%25' inserted in the middle of the password. Changed the version to 4.* and that works.

raviteja333 commented 4 years ago

Yes, looks like changing to 4.* worked. But, it was giving a deprecated usage warning.

praveenvinay commented 4 years ago

Same issue here. Using 4.* is comparatively slower and deprecated.

nspiteri commented 3 years ago

In version 6 the problem seems to still exist. However as mentioned earlier, version 4 is ok.

bahadir-be commented 3 years ago

Agree!! Changed the version to 4.* seems to work with warnings.

cniak commented 3 years ago

I see it's more internal change in Azure DevOps code than changes in the vsts-arm-outputs task.

The fix will be automatically used in March 2021. https://github.com/microsoft/azure-pipelines-agent/blob/master/docs/design/percentEncoding.md

Conclusion: now you can go back to ARM Output v6, but first you need to apply variable DECODE_PERCENTS = true in your pipelines.