[colug-432] Creating SSH for New User

Steve VanSlyck s.vanslyck at postpro.net
Sun May 10 22:55:47 EDT 2015


I am assuming that each user has a different authorized keys file. Is
that so? Here are the relevant lines from sshd_config:

#RSAAuthentication yes
# PubkeyAuthentication yes AuthorizedKeysFile .ssh/authorized_keys
# AuthorizedKeysCommand none AuthorizedKeysCommandRunAs nobody





On Sun, May 10, 2015, at 22:35, Christopher Cavello wrote:
> Maybe you added one or more line breaks to the ssh key?


> Try a "wc" on the key on both client and server.


> Or check your sshd_config and make sure keys are allowed.
>
"ssh -vvv" is good for debugging.

> On May 10, 2015 10:27 PM, "Steve VanSlyck"
> <s.vanslyck at postpro.net> wrote:
>> __
>> My new user (me) can't log on via SSH. Can someone look this over and
>> tell me what super basic thing I've done wrong?
>>
>> What I did:
>>
>> _As root_:
>>
>> Add user "name" /usr/sbin/adduser name Create password passwd name
>> [created the password] Give root permissions sudo nano /etc/sudoers
>> [added the line name ALL=(All) ALL Re-enabled password authentication
>> in sshd_config and restarted sshd
>>
>> _As the new user "name"_:
>>
>> made directory mkdir ./ssh created file and added public key to file
>> authorized keys sudo nano ~/.ssh/authorized_keys [entered the public
>> key (which I call a "lock")] updated permissions "just in case" chmod
>> 700 ~/.ssh chmod 600 ~/.ssh/authorized_keys
>>
>> tried to login with the private key Result: server refused the key.
>>
>> Any idea what I'm doing wrong?
>>
>> _______________________________________________
>>
colug-432 mailing list
>> colug-432 at colug.net http://lists.colug.net/mailman/listinfo/colug-432
>>
> _________________________________________________
> colug-432 mailing list colug-432 at colug.net
> http://lists.colug.net/mailman/listinfo/colug-432

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.colug.net/pipermail/colug-432/attachments/20150510/a1d3ff94/attachment.html 


More information about the colug-432 mailing list