Skip to content

Commit 43bc350

Browse files
committed
Made it use a SecureString for the password.
1 parent 8ff1c52 commit 43bc350

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

Management-Utilities/iscsi-vol-create-and-mount/CreateDisk.ps1

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,8 +63,7 @@ Set-Service -Name msiscsi -StartupType Automatic
6363

6464
#### Connect to FSX ####
6565
Write-Host "Connectiong to FSx filesystem" -ForegroundColor Yellow
66-
$PWord = ConvertTo-SecureString -String $password -AsPlainText -Force
67-
$credntials = New-Object -TypeName System.Management.Automation.PSCredential -ArgumentList $user, $PWord
66+
$credntials = New-Object -TypeName System.Management.Automation.PSCredential -ArgumentList $user, $password
6867
try {
6968
Connect-NcController $ip -Credential $credntials -ErrorAction Stop
7069
}

0 commit comments

Comments
 (0)