microsoft / azure-load-testing

MIT License
22 stars 2 forks source link

[BUG] Pipeline with secrets with special chars does not work #85

Closed nilsgaeq closed 2 years ago

nilsgaeq commented 2 years ago

Describe the bug Using AzureLoadTest@1 task with secrets fails with ##[error]Invalid secrets when the secret value contains "special" characters like : and .. This goes both for secrets referenced in variable group linked to azure keyvault and secrets defined as pipeline variable.

To Reproduce Steps to reproduce the behavior:

  1. Create pipeline using AzureLoadTest@1 task
  2. Define a secret
  3. Put : or . (I would assume other special chars also fails) in the secret value
  4. Run pipeline

Expected behavior Pipeline should run successfully with the provided secrets

AB#1554814

abranj1219 commented 2 years ago

Thanks for reporting this. We will check this and get back to you!!

ninallam commented 2 years ago

@nilsgaeq we have fixed this issue. Can you please confirm if it is working?

nilsgaeq commented 2 years ago

It does work now, thanks. But it appears that using secrets from keyvault cause the output of what little reporting there is being obfuscated (even the link to the run in the portal), so at it's current state, it does not provide anything that can be inspected in the pipeline itself. Only way to inspect the results is to go into azure portal and navigate to the run from there.

ninallam commented 2 years ago

@nilsgaeq are you not able to see the test run results in the pipeline logs?

nilsgaeq commented 2 years ago

It is partially obfuscated. Not sure what causes this, but a colleague suggested the keyvault secret variable integration caused this. So it does not yield any useful information. E.g:

Test1
response time    : avg=289ms min=***0ms med=***9***ms max=622ms p(90)=622ms p(9***)=622ms p(99)=622ms
requests per sec     : avg=***
total requests       : ***
total errors         : 2
total error rate     : 66
Test2
response time    : avg=***ms min=***ms med=402ms max=494ms p(90)=494ms p(9***)=494ms p(99)=494ms
requests per sec     : avg=***
total requests       : ***
total errors         : 0
total error rate     : 0
ninallam commented 2 years ago

Is the portal URL not correct as well? Is it possible to send a screenshot of the entire output? Also, could you confirm if you are running from Azure Pipelines?

nilsgaeq commented 2 years ago

That's correct. The url is also obfuscated. It is run in an Azure Devops Pipeline.

ninallam commented 2 years ago

@nilsgaeq can you please share the screenshot of the output?

ninallam commented 2 years ago

@nilsgaeq we are closing this issue since we haven't received any response. Please re-open if you are still facing it.

mpr555 commented 1 year ago

I am having this exact issue.

I am running key vault secrets from variable pipeline groups.

If the secrets are something simple like "test, " it will work. But when I generate the app secret for the app registration within the portal, it has special characters in it. And this creates a syntax error within the pipeline.

Help on this would be appreciated