Currently, I audit the security of Azure Devops service connections: How secure are the credentials stored in the service connection?
Example in case is the TwineAuthenticate Task. It will pull the credentials from the service connection pythonUploadServiceConnection
and writes them to a PyPI resource file.
Or does it?
Inspection of this file (edit)
- script: |
cat $(PYPIRC_PATH)
shows user and password have values of ***
, which are not the credentials provided by the service connection.
So what magic is going on when twine
reads the PyPI resource file? Is this safe or just obfuscated?
Azure DevOps mask you secret as far as it is aware of the variable nature. This article is about github action but you may apply the same rules for Azure DevOps.
And please take a look here in docs