xenial @ 1:7.2p2-4ubuntu2.1 on amd64 has this bug. trusty @ 1:6.6p1-2ubuntu2.8 on amd64 does not have this bug. I have not tested any other ssh versions.
The following should reproduce the issue:
#ssh-keyscan XXXX > ~/.ssh/known_hosts
# ssh root@XXXXX
Permission denied (publickey).
# ssh-keygen -H
/root/.ssh/known_hosts updated.
Original contents retained as /root/.ssh/known_hosts.old
WARNING: /root/.ssh/known_hosts.old contains unhashed entries
Delete this file to ensure privacy of hostnames
# ssh root@XXXXXX
Permission denied (publickey).
# ssh-keygen -H
/root/.ssh/known_hosts updated.
Original contents retained as /root/.ssh/known_hosts.old
WARNING: /root/.ssh/known_hosts.old contains unhashed entries
Delete this file to ensure privacy of hostnames
# ssh root@XXXXX
The authenticity of host 'XXXXXX' can't be established.
RSA key fingerprint is XXXXXX.
Are you sure you want to continue connecting (yes/no)?
xenial @ 1:7.2p2-4ubuntu2.1 on amd64 has this bug. trusty @ 1:6.6p1-2ubuntu2.8 on amd64 does not have this bug. I have not tested any other ssh versions.
The following should reproduce the issue:
#ssh-keyscan XXXX > ~/.ssh/known_hosts ssh/known_ hosts updated. ssh/known_ hosts.old ssh/known_ hosts.old contains unhashed entries ssh/known_ hosts updated. ssh/known_ hosts.old ssh/known_ hosts.old contains unhashed entries
# ssh root@XXXXX
Permission denied (publickey).
# ssh-keygen -H
/root/.
Original contents retained as /root/.
WARNING: /root/.
Delete this file to ensure privacy of hostnames
# ssh root@XXXXXX
Permission denied (publickey).
# ssh-keygen -H
/root/.
Original contents retained as /root/.
WARNING: /root/.
Delete this file to ensure privacy of hostnames
# ssh root@XXXXX
The authenticity of host 'XXXXXX' can't be established.
RSA key fingerprint is XXXXXX.
Are you sure you want to continue connecting (yes/no)?
# diff known_hosts.old known_hosts zyprJcbjdepeDh8 =|x/1AcaLxh45Fl ShmVQnlgx2qjxY= XXXXX Zi3pqOa2pc/ cX64=|bUH5qwZlZ Pp8msMGHdLtslf3 Huk= XXXXX
1c1
< |1|BoAbRpUE3F5A
---
> |1|nTPsoLxCugQy