0

I've a problem with SSH public key authentication.

I'm a travel agent and need to give to the client (Amadeus) the access to only one folder on my server located in home directory, ex. xxx so I created SFTP user, ex. yyy, with permissions to access only to this folder.

The client is going to enter this folder and upload files that later will be read by back office of the travel agency.

The client provided me their IP (that I included on my trust IPs) and Public Key. I created on my server .ssh folder with permissions 700 and authorized_keys file with permissions 600 and I copied public key inside.

The client receives this answer when trying to connect:

(SSH key)...[AUTHENTICATION ERROR] Authentication failed.

I don't know where the problem is. Maybe it is necessary to indicate the server from where to read this public key or give the user any additional permissions in relation to .ssh folder.

If you have any idea where can be the problem any comments are appreciated.

MC68020
  • 7,981
Damian
  • 1
  • Check in /etc/ssh/sshd_config if the parameter PubkeyAuthentication = yes is present and if PasswordAuthentication no is there (note you can have both to yes). By default sshd refers to both .ssh/authorized_keys and .ssh/authorized_keys2 in home folder for ssh keys. – admstg Mar 29 '24 at 14:44
  • Could be PAM settings too, but sshd_config is one place to start. However, the very first debugging step I would take if I had access to both sides of the connection, would be to have the client repeat the ssh attempt with -v or -vv or -vvv and see more details about the error. That will get you exactly on the right track rather than guessing. – Wildcard Mar 29 '24 at 16:38

0 Answers0