Hello!
Looking to create a rule for syslog & trap events in SW NPM with an alert action "execute an external program" that calls a powershell script that writes a json formatted event into an http event collector in Splunk.
- The script works fine from the command line of SW NPM but once I add it to a rule it fails to inject into splunk when the alert rule fires.
- The powershell script must be called with the -file option.
- Other actions (email or another "perl" script) fires successfully
- Example of Alert "Action Program to execute":
C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -File C:\scriptlocationhere\scriptname.ps1
Thanks!