Voici le debug de la commande du dédié vers le NAS:
max@dedie:~$ ssh -vv -p 22 root@NAShome.fr
OpenSSH_6.0p1 Debian-4, OpenSSL 1.0.1e 11 Feb 2013
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug2: ssh_connect: needpriv 0
debug1: Connecting to NAShome.fr [IP_DU_NAS] port 22.
debug1: Connection established.
debug1: identity file /home/max/.ssh/id_rsa type -1
debug1: identity file /home/max/.ssh/id_rsa-cert type -1
debug1: identity file /home/max/.ssh/id_dsa type -1
debug1: identity file /home/max/.ssh/id_dsa-cert type -1
debug1: identity file /home/max/.ssh/id_ecdsa type -1
debug1: identity file /home/max/.ssh/id_ecdsa-cert type -1
debug1: Remote protocol version 2.0, remote software version OpenSSH_5.8p1-hpn13v11
debug1: match: OpenSSH_5.8p1-hpn13v11 pat OpenSSH_5*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_6.0p1 Debian-4
debug2: fd 3 setting O_NONBLOCK
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug2: kex_parse_kexinit: abcde-fgdh-ijkl
debug2: kex_parse_kexinit: abcde-fgdh-ijkl
debug2: kex_parse_kexinit: 123-5678-9101
debug2: kex_parse_kexinit: 123-5678-9101
debug2: kex_parse_kexinit: 4567-9101-1213
debug2: kex_parse_kexinit: 4567-9101-1213
debug2: kex_parse_kexinit: none,zlib@openssh.com,zlib
debug2: kex_parse_kexinit: none,zlib@openssh.com,zlib
debug2: kex_parse_kexinit:
debug2: kex_parse_kexinit:
debug2: kex_parse_kexinit: first_kex_follows 0
debug2: kex_parse_kexinit: reserved 0
debug2: kex_parse_kexinit: az45-az45-az45
debug2: kex_parse_kexinit: ssh-rsa,ssh-dss,ecdsa-sha2-nistp256
debug2: kex_parse_kexinit: 123-5678-9101
debug2: kex_parse_kexinit: 123-5678-9101
debug2: kex_parse_kexinit: az98-az98
debug2: kex_parse_kexinit: az98-az98
debug2: kex_parse_kexinit: none,zlib@openssh.com
debug2: kex_parse_kexinit: none,zlib@openssh.com
debug2: kex_parse_kexinit:
debug2: kex_parse_kexinit:
debug2: kex_parse_kexinit: first_kex_follows 0
debug2: kex_parse_kexinit: reserved 0
debug2: mac_setup: found hmac-md5
debug1: kex: server->client aes128-ctr hmac-md5 none
debug2: mac_setup: found hmac-md5
debug1: kex: client->server aes128-ctr hmac-md5 none
debug1: sending SSH2_MSG_KEX_ECDH_INIT
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: ECDSA [b]la_cle_de_l'hote[/b]
debug1: checking without port identifier
debug1: Host 'NAShome.fr' is known and matches the ECDSA host key.
debug1: Found key in /home/max/.ssh/known_hosts:1
debug1: found matching key w/out port
debug1: ssh_ecdsa_verify: signature correct
debug2: kex_derive_keys
debug2: set_newkeys: mode 1
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug2: set_newkeys: mode 0
debug1: SSH2_MSG_NEWKEYS received
debug1: Roaming not allowed by server
debug1: SSH2_MSG_SERVICE_REQUEST sent
debug2: service_accept: ssh-userauth
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug2: key: /home/max/.ssh/id_rsa ((nil))
debug2: key: /home/max/.ssh/id_dsa ((nil))
debug2: key: /home/max/.ssh/id_ecdsa ((nil))
debug1: Authentications that can continue: publickey,password
debug1: Next authentication method: publickey
debug1: Trying private key: /home/max/.ssh/id_rsa
debug1: Trying private key: /home/max/.ssh/id_dsa
debug1: Trying private key: /home/max/.ssh/id_ecdsa
debug2: we did not send a packet, disable method
debug1: Next authentication method: password
Serait-ce le nom des clés qui pose problème ?
Le nom de ma clé est id_dsa_dedie_max.pub
En fait, j’ai créé un jeu de clé pour le portable => extérieur (NAS et Dédié) et un jeu de clé Dédié => extérieur (NAS).
Ai-je eu tort ? Il ne me semble pas, étant donné qu’une clé publique dépend d’une clé privée, et que la clé privée est celle de la machine qui veut se connecter…