Project

General

Profile

Actions

Bug #9193

closed

The PowerShell list-compatible-inputs version should be executed with Bypass ExecutionPolicy

Added by Matthieu CERDA over 7 years ago. Updated over 7 years ago.

Status:
Released
Priority:
1
Category:
-
Target version:
Severity:
UX impact:
User visibility:
Effort required:
Priority:
Name check:
Fix check:
Regression:

Description

We currently do execute the inventory signature PS script like this:

"sign_script" string => "C:\Windows\System32\WindowsPowershell\v1.0\powershell.exe -ExecutionPolicy Bypass -File \"C:\Program Files\Rudder\sbin\signature.ps1\" -file";

but list-compatible-inputs is executed like this, since #8553:

"list_compatible_inputs" string => "\& '${ncf_path}\common\10_ncf_internals\list-compatible-inputs.ps1\'";

This second command will not work, as the default Restricted ExecutionPolicy will raise an error due to the file being foreign.

We need to do just like we do with the signature script.

Actions

Also available in: Atom PDF