Jump to content

Recommended Posts

Posted

So this simple script works on any computer. reg query HKEY_CURRENT_USER\Network /s 

I am testing out Pulseway right now and trying to see what its limits are for scripting. It seems Pulsway executes Batches and Powershell as a system account and not the local logged in user. I can understand batch files to add mapped drives not working but this query should not be affected by that same issue.

It shows me all the mapped drives for the logged in user. What I do not understand is why Running this in Pulseway it returns this;

  • ERROR: The system was unable to find the specified registry key or value.
  • 0
    Exit Code
  • Staff
Posted

Hi Philip,

Have you tried to configure the Powershell impersonation?

image.png.cdfaee9afb295efd11f5ba69dc217c89.png

 

If you want to execute the PS script as the system, then you will need to disable this configuration from the code by setting the value for this registry key to 0:

HKEY_LOCAL_MACHINE\SOFTWARE\MMSOFT Design\PC Monitor\PowerShellUserImpersonation

I hope this helps.

  • 2 weeks later...
  • 8 months later...
  • 4 weeks later...
  • Staff
Posted

@Tyson,

In order to update the details for the PS impersonation you will need to use the batch script.

At first we need to configure the Powershel impersonation on one of monitored systems and the copy the required values from the registry.

REG ADD "HKLM\Software\MMSOFT Design\PC Monitor" /v PowerShellUserImpersonation /t REG_SZ /d value_here /f
REG ADD "HKLM\Software\MMSOFT Design\PC Monitor" /v PowerShellUserImpersonationDomain /t REG_SZ /d value_here /f
REG ADD "HKLM\Software\MMSOFT Design\PC Monitor" /v PowerShellUserImpersonationPassword /t REG_SZ /d value_here /f
REG ADD "HKLM\Software\MMSOFT Design\PC Monitor" /v PowerShellUserImpersonationPasswordCtrl /t REG_SZ /d value_here /f
REG ADD "HKLM\Software\MMSOFT Design\PC Monitor" /v PowerShellUserImpersonationUsername /t REG_SZ /d value_here /f

 

Or simply use this command to enable or disable it by changing the value from 1- enabled to 0 - disabled

REG ADD "HKLM\Software\MMSOFT Design\PC Monitor" /v PowerShellUserImpersonation /t REG_SZ /d o /f

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...