TLS connection error/bug
I'm trying to do a TLS connection using .NET library in C#, but I'm receiving a SSH error, it seems a bug.
Here my code:
If I set:
I get the error:
I get the same error above.
If I set:
I get the same error above, again
If I set
I get the error:
Can anyone help me?
Here my code:
SessionOptions sessionOptions = new SessionOptions(); sessionOptions.HostName = _hostName; sessionOptions.Password = _password; sessionOptions.UserName = _userName; sessionOptions.Protocol = Protocol.Ftp; sessionOptions.FtpSecure = FtpSecure.Implicit; sessionOptions.PortNumber = 990; sessionOptions.FtpMode = FtpMode.Passive;
sessionOptions.GiveUpSecurityAndAcceptAnyTlsHostCertificate = true;
If I set:System.ArgumentException: SessionOptions.SshHostKey or SessionOptions.GiveUpSecurityAndAcceptAnySshHostKey is set, but SessionOptions.Protocol is not Protocol.Sftp nor Protocol.Scp.
sessionOptions.GiveUpSecurityAndAcceptAnySshHostKey
If I set:
sessionOptions.TlsHostCertificateFingerprint = "61:79:71...";
If I set
sessionOptions.SshHostKeyFingerprint = "61:79:71..."
When I set TLS properties, the error says that I'm using SSH properties. So I believe it is a bug.System.ArgumentException: SSH host key fingerprint "61:79:71..." does not match pattern /((ssh-rsa|ssh-dss)( |-))?(\d+ )?([0-9a-f]{2}(:|-)){15}[0-9a-f]{2}(;((ssh-rsa|ssh-dss)( |-))?(\d+ )?([0-9a-f]{2}(:|-)){15}[0-9a-f]{2})*/
Can anyone help me?