0

I am trying to connect to an SFTP server using WinSCP. When I do it in a Win forms app it connects no problem. However, using exactly the same code in a WCF service returns 'Access Denied'.

I have checked repeatedly that Protocol, HostName, UserName, Password, SshPrivateKeyPassphrase and SshHostKeyFingerprint are the same in both apps, and that SshPrivateKeyPath points to a file that the DefaultAppPool can access.

Is there something else that I am missing to get this to work in WCF.

Edit: I should have mentioned that is the call to session.Open(sessionOptions); that returns 'Access Denied'.

GlenW
  • 13
  • 1
  • 6

0 Answers0