Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handling child_process.spawn() parameter "windowsVerbatimArguments" #18

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

rebrec
Copy link

@rebrec rebrec commented Dec 26, 2019

Here is a basic implementation which solve the following issue :

#17

TLDR : Under Windows, child_process.spawn() method escape process arguments and add quotes to them. This can lead to improper parameter handling by the called process.

Example: If we pass the following processCommand and processArgs parameters to the StatefulProcessCommandProxy

const processCommand = 'C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\powershell.exe'
const processArgs = ['-NoProfile -ExecutionPolicy bypass']

This pull request provide a new parameter to ProcessProxy to handle this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant