I am trying to set up a guest user that allows ssh access without a password AND without a keyfile.
All my searches turns up people trying to set up password-less entry with a keyfile. This is not what I'm looking for.
I would settle for just having a blank password, but I can't get that working either; if I delete the user's password, the SSH daemon won't allow any access. I've set "PermitEmptyPasswords yes" in the config file and restarted the service.
I'm running Ubuntu 14.04.1 LTS.
1 Answer
What you're looking for is anonymous SSH access. I found an article for SFTP, which applies to SSH too, if you leave out SFTP-specific stuff:
Create a new user:
adduser --disabled-password anonymousMake the password actually empty:
sed -i -re 's/^anonymous:[^:]+:/anonymous::/' /etc/passwd /etc/shadowAllow blank passwords for SSH sessions in PAM: edit
/etc/pam.d/sshdand replace the line that reads@include common-authwith:auth [success=1 default=ignore] pam_unix.so nullok auth requisite pam_deny.so auth required pam_permit.soAllow blank passwords for SSH sessions of
anonymousin/etc/ssh/sshd_config:Match user anonymous PermitEmptyPasswords yesRestart sshd:
initctl restart ssh
I didn't try it myself, but it looks plausible, since my first thought for the culprit was PAM.
1