mirror of
https://github.com/mRemoteNG/mRemoteNG.git
synced 2026-02-17 22:11:48 +08:00
Merge pull request #2940 from mRemoteNG/fix/aikido-security-sast-8815714-tnsC
[Aikido] AI Fix for Possible command injection via Process.Start
This commit is contained in:
@@ -156,7 +156,8 @@ namespace mRemoteNG.Tools
|
||||
ExternalToolArgumentParser argParser = new(startConnectionInfo);
|
||||
process.StartInfo.UseShellExecute = true;
|
||||
process.StartInfo.FileName = argParser.ParseArguments(FileName);
|
||||
process.StartInfo.Arguments = argParser.ParseArguments(Arguments);
|
||||
var parsedArgs = argParser.ParseArguments(Arguments).Split(' ');
|
||||
process.StartInfo.ArgumentList.AddRange(parsedArgs);
|
||||
if (WorkingDir != "") process.StartInfo.WorkingDirectory = argParser.ParseArguments(WorkingDir);
|
||||
if (RunElevated) process.StartInfo.Verb = "runas";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user