LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 09-29-2004, 12:20 PM   #1
matthewkeen
LQ Newbie
 
Registered: Sep 2004
Posts: 6

Rep: Reputation: 0
SSH keys problem


Hi. im having a problem with ssh keys, its redhat 9, ive tried dsa and rsa keys and get the same problem, if I upload the public key to a root user on another machine I can do a passwordless login no problem, if I upload it to a normal user it doesnt work.


[mkeen mkeen]$ ssh-keygen -t dsa -f .ssh/id_dsa
Generating public/private dsa key pair.
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in .ssh/id_dsa.
Your public key has been saved in .ssh/id_dsa.pub.
The key fingerprint is:
55:**:**:**:**:**:**:**:**:**:**:**:1d:ab:51:fa mkeen@hosting.***.com
[mkeen mkeen]$ cd .ssh/
[mkeen .ssh]$ ls
id_dsa id_dsa.pub
[mkeen .ssh]$ scp id_dsa.pub user@82.138.247.**:~/.ssh/id_dsa.pub
server2@82.138.247.**'s password:
id_dsa.pub 100% 615 0.0KB/s 00:00
[mkeen .ssh]$ ssh user@82.138.247.**
user@82.138.247.**'s password:
[user@server10 server2]$ ls
[user@server10 server2]$ cd .ssh/
[user@server10 .ssh]$ cat id_dsa.pub >> authorized_keys
[user@server10 .ssh]$ chmod 640 authorized_keys
[user@server10 .ssh]$ rm id_dsa.pub
[user@server10 .ssh]$ exit
logout
Connection to 82.138.247.** closed.
[mkeen .ssh]$ ssh user@82.138.247.**
user@82.138.247.**'s password:I have done the exact same thing on a machine with fedora core 2 on and it works fine.


Thanks in advance
Matthew Keen
 
Old 09-29-2004, 04:05 PM   #2
mritch
Member
 
Registered: Nov 2003
Location: austria
Distribution: debian
Posts: 667

Rep: Reputation: 30
be sure the key(directory) is only readable by the user.

sl mritch.
 
Old 10-01-2004, 08:07 AM   #3
matthewkeen
LQ Newbie
 
Registered: Sep 2004
Posts: 6

Original Poster
Rep: Reputation: 0
Yes thats correct.
 
Old 02-25-2005, 02:26 PM   #4
edafe
Member
 
Registered: Feb 2005
Posts: 44

Rep: Reputation: 15
Step-by-step instructions on how to use public key authentication with SSH:

http://www.edafe.org/slackware/index...authentication

Regards,
Edafe
 
  


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
SSH public / private keys problem guideweb Linux - Software 7 08-27-2005 09:49 PM
Problem using SSH keys krish_rsk Linux - Security 2 04-12-2005 09:35 PM
ssh keys merchtemeagle Linux - Newbie 4 10-12-2004 12:12 AM
ssh keys Lucasite Linux - Security 2 03-11-2004 12:43 PM
Configuring SSH to accept only keys (already have keys) fr0st Linux - Security 3 11-04-2003 03:31 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 02:26 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