Skip to Content
Aug 16, 2022 at 06:37 AM

Error while establishing SFTP connection with public key based authentication

225 Views Last edit Aug 16, 2022 at 12:38 PM 3 rev

Hi Experts,

We are trying to connect to an internal on-premise SFTP server with public key based authentication. We have followed the below steps:

1.Updated the CPI's known hosts file with SFTP server keys.

2.Created SSH key pair in CPI key store and downloaded the pub key from it.

3.Updated the authorized_keys file in ssh directory of SFTP server with CPI pub key details.

After all these steps when we try the connection test we are getting "com.jcraft.jsch.JSchException: Auth fail" error.

Did anyone face the similar issue and able to fix it? Kindly share any suggestions/inputs on this.