Hi.
Thank you for ssh.net library.
I'm having an issue when trying to use double quotes in a command executed on a ssh server running on Windows.
```
ConnectionInfo connectionInfo = new ConnectionInfo(
"hostname",
22,
"username",
new AuthenticationMethod[] { new PasswordAuthenticationMethod("username", "password") });
using (SshClient sshclient = new SshClient(connectionInfo))
{
sshclient.Connect();
SshCommand sshCommand = sshclient.CreateCommand("tasklist /FI \"SessionName eq Console\"");
string output = sshCommand.Execute();
Trace.WriteLine(string.Format("ExitStatus: {0}", sshCommand.ExitStatus));
Trace.WriteLine(string.Format("Output: {0}", output));
string result = sshCommand.Result;
string error = sshCommand.Error;
Trace.WriteLine(string.Format("Result: {0}", result));
Trace.WriteLine(string.Format("Error: {0}", error));
sshclient.Disconnect();
}
```
Result:
```
ExitStatus: 0
Output:
Result:
Error: ERROR: The search filter cannot be recognized.
```
Any ideas?
Thank you.
Thank you for ssh.net library.
I'm having an issue when trying to use double quotes in a command executed on a ssh server running on Windows.
```
ConnectionInfo connectionInfo = new ConnectionInfo(
"hostname",
22,
"username",
new AuthenticationMethod[] { new PasswordAuthenticationMethod("username", "password") });
using (SshClient sshclient = new SshClient(connectionInfo))
{
sshclient.Connect();
SshCommand sshCommand = sshclient.CreateCommand("tasklist /FI \"SessionName eq Console\"");
string output = sshCommand.Execute();
Trace.WriteLine(string.Format("ExitStatus: {0}", sshCommand.ExitStatus));
Trace.WriteLine(string.Format("Output: {0}", output));
string result = sshCommand.Result;
string error = sshCommand.Error;
Trace.WriteLine(string.Format("Result: {0}", result));
Trace.WriteLine(string.Format("Error: {0}", error));
sshclient.Disconnect();
}
```
Result:
```
ExitStatus: 0
Output:
Result:
Error: ERROR: The search filter cannot be recognized.
```
Any ideas?
Thank you.