File tree 3 files changed +9
-3
lines changed
3 files changed +9
-3
lines changed Original file line number Diff line number Diff line change 12
12
# RootModule = ''
13
13
14
14
# このモジュールのバージョン番号です。
15
- ModuleVersion = ' 2.0.0 '
15
+ ModuleVersion = ' 2.0.1 '
16
16
17
17
# サポートされている PSEditions
18
18
# CompatiblePSEditions = @()
Original file line number Diff line number Diff line change @@ -59,7 +59,7 @@ function Get-TargetResource {
59
59
}
60
60
else {
61
61
$private :LsaUtil = New-Object PInvoke.LSAUtil.LSAutil - ArgumentList " DefaultPassword"
62
- $EncryptedPassword = $LsaUtil.GetSecret ()
62
+ $private : EncryptedPassword = $LsaUtil.GetSecret ()
63
63
if ($EncryptedPassword ) {
64
64
Write-Verbose (' Password is encrypted' )
65
65
$GetRes.Encrypt = $true
@@ -79,7 +79,10 @@ function Get-TargetResource {
79
79
else {
80
80
$Fullname = $GetRes.Username
81
81
}
82
- $SecPwd = ConvertTo-SecureString - String $Password - AsPlainText - Force
82
+
83
+ # $SecPwd = ConvertTo-SecureString -String $Password -AsPlainText -Force
84
+ $SecPwd = New-Object System.Security.SecureString
85
+ $Password.ToCharArray () | % {$SecPwd.AppendChar ($_ )} # Workaround for PSScriptAnalyzer issue
83
86
$GetRes.AutoLogonCredential = New-Object System.Management.Automation.PSCredential $Fullname , $SecPwd
84
87
}
85
88
Original file line number Diff line number Diff line change @@ -30,6 +30,9 @@ PowerShell DSC Resource to turn on / off automatic logon in Windows.
30
30
Please look in the [ Example] ( https://github.com/mkht/DSCR_AutoLogon/tree/master/Example ) folder.
31
31
32
32
## ChangeLog
33
+ ### 2.0.1
34
+ + Fix PSSA Issues
35
+
33
36
### 2.0.0
34
37
+ Supports password encryption
35
38
+ Change resource type from composite to MOF-based.
You can’t perform that action at this time.
0 commit comments