-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathCmd.cs
More file actions
26 lines (23 loc) · 760 Bytes
/
Cmd.cs
File metadata and controls
26 lines (23 loc) · 760 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
namespace keystoreBrute
{
using System;
using System.Diagnostics;
public class Cmd
{
public static Process Execute(String command, String arguments = "")
{
Process proc = new Process();
proc.EnableRaisingEvents = false;
proc.StartInfo.FileName = command;
proc.StartInfo.Arguments = arguments;
proc.StartInfo.RedirectStandardOutput=true;
proc.StartInfo.RedirectStandardError=true;
proc.StartInfo.CreateNoWindow = true;
proc.StartInfo.UseShellExecute = false;
proc.StartInfo.WindowStyle = ProcessWindowStyle.Hidden;
proc.Start();
proc.WaitForExit();
return proc;
}
}
}