Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
resinfo-gt
swmb
resinfo-swmb
Commits
ed4fd2cf
Commit
ed4fd2cf
authored
May 11, 2022
by
Olivier De Marchi
Browse files
bug in var AgentCredential
parent
86946332
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
Modules/SWMB/Experimental.psm1
Modules/SWMB/Experimental.psm1
+1
-1
No files found.
Modules/SWMB/Experimental.psm1
View file @
ed4fd2cf
...
...
@@ -123,7 +123,7 @@ Function TweakUninstallKasperskyEndpoint { # RESINFO
# Batch - encrypted (blurred) password
$AgentCryptPassword
=
$
(
$
Global
:
SWMB_Custom
.
KesAgentPass
)
|
ConvertTo-SecureString
-Key
(
Get-Content
$
(
$
Global
:
SWMB_Custom
.
KesKeyFile
))
$AgentCredential
=
New-Object
System.Management.Automation.PsCredential
(
$
(
$
Global
:
SWMB_Custom
.
KesLogin
),
$AgentCryptPassword
)
$AgentPlainPassword
=
$Credential
.
GetNetworkCredential
()
.
Password
$AgentPlainPassword
=
$
Agent
Credential
.
GetNetworkCredential
()
.
Password
}
ElseIf
(
$
(
$
Global
:
SWMB_Custom
.
KesAgentPass
))
{
# Batch - password defined in clear text
$AgentPlainPassword
=
$
(
$
Global
:
SWMB_Custom
.
KesPassword
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment