Just arrived to C#Corner. I'm having a lot of problems getting a result that seems so obvious and easy.
Take a look at the following code:
Process p = new Process();
p.StartInfo.UseShellExecute = false;
p.StartInfo.RedirectStandardOutput = true;
p.StartInfo.FileName = "openssl\\openssl.exe";
p.StartInfo.Arguments = "\"2010-05-18;2010-05-18T11:22:19;FAC 001/14;3.12; \" | openssl dgst -sha1 -sign prikeyofs.pem | openssl enc -base64";
string output = p.StandardOutput.ReadToEnd();
This example returns an empty string. And why is this happening?
If I replace the file name for cmd and remove the arguments I get the usual "Microsoft Windows [Versão 6.1.7600]...". I can't even send the result to another file like "> something.txt".
Does anyone knows why is this happening.
Thanks in advance.