LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices

Reply
 
LinkBack Search this Thread
Old 03-24-2010, 07:44 AM   #1
razero
LQ Newbie
 
Registered: Mar 2010
Posts: 4

Rep: Reputation: 0
ssh authentication with rsa


Hello

I have trouble with rsa authentication:

I did create an rsa certificate with ssh-keygen using my root account on a client:
ssh-keygen -t rsa -b 2048
no passphrase
I did copy the rsa pub_key from my client to the server
scp id_rsa sampleuser@sampleserver:/home/sampleuser/.ssh/authorized_keys

I did change the ownership to the "sampleuser" of the pub key file on the server:
I trayd to connect:

ssh sampleuser@sapleserver
I get that: permission denied (public key)...

I know I do smth wrong but I don't know what.

Thanks for help!
 
Old 03-24-2010, 07:53 AM   #2
centosboy
Senior Member
 
Registered: May 2009
Location: london
Distribution: centos5
Posts: 1,137

Rep: Reputation: 116Reputation: 116
Quote:
Originally Posted by razero View Post
Hello

I have trouble with rsa authentication:

I did create an rsa certificate with ssh-keygen using my root account on a client:
ssh-keygen -t rsa -b 2048
no passphrase
I did copy the rsa pub_key from my client to the server
scp id_rsa sampleuser@sampleserver:/home/sampleuser/.ssh/authorized_keys

I did change the ownership to the "sampleuser" of the pub key file on the server:
I trayd to connect:

ssh sampleuser@sapleserver
I get that: permission denied (public key)...

I know I do smth wrong but I don't know what.

Thanks for help!
give some more details....eg what is in the logs... /var/log/secure on ssh server.
i think it could be a permissions problem, but i wont know unless you tell us more...

authorized_keys file should be something like 400 or 600.
either way...check log files for more clues. /var/log/secure or /var/log/messages

Last edited by centosboy; 03-24-2010 at 07:54 AM.
 
1 members found this post helpful.
Old 04-12-2010, 04:24 AM   #3
razero
LQ Newbie
 
Registered: Mar 2010
Posts: 4

Original Poster
Rep: Reputation: 0
Hello

I had a closer look at the RSA certificate.

On the public key i found a the end of the certificate file, my user name and the machine from which i did
create the certificate. I did replace the PC name to the one i want to use to connect to the server and it works.

razero
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
SSH no-password authentication: RSA Passphrase Nokao Linux - Server 8 12-28-2009 10:17 AM
[SOLVED] Debian Etch SSH rsa authentication problem parf Linux - Newbie 6 12-16-2009 02:47 AM
failed ssh RSA key authentication jdarren Linux - Networking 15 07-06-2008 10:25 AM
RSA Key Authentication with SSH fail with no reply for publickey powah Linux - Security 2 11-18-2006 12:24 PM
ssh RSA authentication changed? Moebius Linux - Networking 1 05-20-2006 07:05 PM


All times are GMT -5. The time now is 08:54 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration