Skip to content

Commit

Permalink
Update SubmitTo-MicrosoftStore.ps1
Browse files Browse the repository at this point in the history
  • Loading branch information
0x5bfa authored Jul 25, 2024
1 parent 755400e commit c62f713
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions scripts/SubmitTo-MicrosoftStore.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ Set-PSRepository -Name "PSGallery" -InstallationPolicy Trusted
Install-Module -Name StoreBroker

# Authenticate StoreBroker
$username = $PartnerCenterClientId
$password = ConvertTo-SecureString $PartnerCenterClientSecret -AsPlainText -Force
$cred = New-Object System.Management.Automation.PSCredential ($username, $password)
Set-StoreBrokerAuthentication -TenantId $PartnerCenterTenantId -Credential $cred
$UserName = $PartnerCenterClientId
$Password = ConvertTo-SecureString $PartnerCenterClientSecret -AsPlainText -Force

Check failure on line 21 in scripts/SubmitTo-MicrosoftStore.ps1

View check run for this annotation

codefactor.io / CodeFactor

scripts/SubmitTo-MicrosoftStore.ps1#L21

File 'SubmitTo-MicrosoftStore.ps1' uses ConvertTo-SecureString with plaintext. This will expose secure information. Encrypted standard strings should be used instead. (PSAvoidUsingConvertToSecureStringWithPlainText)
$Credential = New-Object System.Management.Automation.PSCredential ($UserName, $Password)
Set-StoreBrokerAuthentication -TenantId $PartnerCenterTenantId -Credential $Credential

# Prepare the submission package
New-SubmissionPackage -ConfigPath $StoreBrokerConfigPath -AppxPath $AppxPackagePath -OutPath $SubmissionDirPath -OutName 'submission'
Expand Down

0 comments on commit c62f713

Please sign in to comment.