-
Couldn't load subscription status.
- Fork 402
Closed
Labels
Description
- Slack Community Chat: https://powershell.slack.com (you can sign-up at http://slack.poshcode.org/ for an invite)
- Also have a look at the
RoleDocumentationfolder for more information on each rule:
https://github.com/PowerShell/PSScriptAnalyzer/tree/development/RuleDocumentation
AvoidUsingConvertToSecureStringWithPlainText error is triggered when set azure keyvault secret from the example:
https://learn.microsoft.com/en-us/powershell/module/az.keyvault/set-azkeyvaultsecret?view=azps-10.4.1#example-1-modify-the-value-of-a-secret-using-default-attributes
How we can replace:
$Secret = ConvertTo-SecureString -String 'Password' -AsPlainText -Force Set-AzKeyVaultSecret -VaultName 'Contoso' -Name 'ITSecret' -SecretValue $Secret
to avoid triggering the error?