LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-26-2014, 01:12 PM   #1
amrogers3
Member
 
Registered: Jan 2004
Posts: 45

Rep: Reputation: 15
could use some help with SSH and strictmodes


I am attempting to setup an SSH pubkey login using a non-root user. I can login if I use a password, however, no go with a public key.

I turned "Strictmodes" to no in the sshd_config file and pubkey login works. However if I leave Strictmodes to yes, I can't log in with pubkey.

I think it is because the group owner is not the user

Code:
drwx------+ 2 amrogers3 share   4096 Jan 26 08:32 .ssh
I am getting an error when I do

Code:
chown -R amrogers3:amrogers3 /home/amrogers3/.ssh

chown: invalid group: `amrogers3:amrogers3'
I tried googling but haven't found a solution. Coming here in a last ditch effort to figure this out. Any help would be greatly appreciated.

Thanks for your time.
 
Old 01-26-2014, 02:52 PM   #2
lleb
Senior Member
 
Registered: Dec 2005
Location: Florida
Distribution: CentOS/Fedora/Pop!_OS
Posts: 2,983

Rep: Reputation: 551Reputation: 551Reputation: 551Reputation: 551Reputation: 551Reputation: 551
read the links in my sig, they should help.
 
Old 01-26-2014, 02:59 PM   #3
amrogers3
Member
 
Registered: Jan 2004
Posts: 45

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by lleb View Post
read the links in my sig, they should help.
Unfortunately, those links don't really address my issue. Apparently it is a permissions problem and I need to change ownership of the .ssh and authorized_keys file to amrogers3: amrogers3.

When I run chown amrogers3:amrogers3 I get "invalid group: amrogers3:amrogers3"

I can't figure this out. I have reached the end of the internet tried to google this issue.
 
Old 01-26-2014, 08:19 PM   #4
btmiller
Senior Member
 
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 4,290

Rep: Reputation: 378Reputation: 378Reputation: 378Reputation: 378
It looks like there's no amrogers3 group. Can you type "id" on the command line to see what your account's primary group ID is?
 
Old 01-26-2014, 08:31 PM   #5
amrogers3
Member
 
Registered: Jan 2004
Posts: 45

Original Poster
Rep: Reputation: 15
Two groups, share and www-data.

i have tried everything I can think of and I cannot login without turning "Strictmode" off in sshd_config.
 
Old 01-27-2014, 12:04 AM   #6
lleb
Senior Member
 
Registered: Dec 2005
Location: Florida
Distribution: CentOS/Fedora/Pop!_OS
Posts: 2,983

Rep: Reputation: 551Reputation: 551Reputation: 551Reputation: 551Reputation: 551Reputation: 551
what is the owner group of your /home directory. again my links talk about permissions.

you could always try running the following command:

Code:
chmod -R go= ~/.ssh
that will set proper strict permissions on the .ssh directory.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Help with Ubuntu server remote ssh and local network ssh issues using putty. scottpops Linux - Server 8 05-17-2012 05:07 PM
ssh-agent, ssh-add and ssh-keygen AND CVS raylpc Linux - General 2 11-19-2008 02:50 AM
setting up an ssh soxy or local ssh tunnel from within an ssh soxy Mangenius Linux - Networking 0 03-05-2007 03:15 PM
Passwordless SSH with SSH commercial server and open ssh cereal83 Linux - General 7 04-18-2006 12:34 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:46 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration