Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here. |
| Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
 |
GNU/Linux Basic Guide
This 255-page guide will provide you with the keys to understand the philosophy of free software, teach you how to use and handle it, and give you the tools required to move easily in the world of GNU/Linux. Many users and administrators will be taking their first steps with this GNU/Linux Basic guide and it will show you how to approach and solve the problems you encounter.
Click Here to receive this Complete Guide absolutely free. |
|
 |
08-25-2010, 09:42 AM
|
#1
|
|
Member
Registered: Oct 2005
Posts: 465
Rep:
|
SSH not working after ssh-keygen due to lack of entropy
My /proc/sys/kernel/random/entropy_avail went from 2200 to <200 after ssh-keygen. The generated key pairs also doesn't work (ie I'm asked to provide a password). Anyone knows what is the minimum before and after entropy number I should see in order to have the keys generated properly?
|
|
|
|
08-25-2010, 10:39 AM
|
#2
|
|
Senior Member
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,474
|
The two are not necessarily related.
Quote:
|
The generated key pairs also doesn't work
|
Get an `ssh -vv user@host` to the server and post it.
|
|
|
|
08-26-2010, 11:34 AM
|
#3
|
|
Senior Member
Registered: Nov 2004
Location: Texas
Distribution: RHEL, Debian, FreeBSD, Ubuntu (desktop)
Posts: 3,859
Rep: 
|
Also, what OS / version? (It's a good idea to include that info when starting a thread.)
|
|
|
|
08-27-2010, 11:34 PM
|
#4
|
|
Member
Registered: Oct 2005
Posts: 465
Original Poster
Rep:
|
It's CentOS 5.5 64-bit. Isn't this the same for most Linux distro?
|
|
|
|
08-28-2010, 08:38 AM
|
#5
|
|
Senior Member
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,474
|
The two are not necessarily related.
Quote:
|
The generated key pairs also doesn't work
|
Get an `ssh -vv user@host` to the server and post it.
|
|
|
|
08-28-2010, 08:46 AM
|
#6
|
|
Member
Registered: Oct 2005
Posts: 465
Original Poster
Rep:
|
I run badblocks twice just to increase the entropy level and generated the key pair again, yet failed again. This was going from my Physical Box A to my VM Box B.
I then tried generating the key pair on Physical Box C and put the public key on Physical Box A. I then ssh from Physical Box C to Physical Box A and it worked fine. This proves my procedure was correct.
Unfortunately the original key pair generated on VM Box B was removed. Nevertheless, I did "ssh -vv username@<VM Box B>" from Physical Box A, and I saw the following at the end:
Code:
debug1: Next authentication method: publickey
debug1: Trying private key: /home/backup/.ssh/identity
debug1: Trying private key: /home/backup/.ssh/id_rsa
debug1: read PEM private key done: type RSA
debug2: we sent a publickey packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-with-mic,password
debug1: Trying private key: /home/backup/.ssh/id_dsa
debug2: we did not send a packet, disable method
debug1: Next authentication method: password
Is this hinting at something?
|
|
|
|
08-28-2010, 09:41 AM
|
#7
|
|
Senior Member
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,474
|
Sorry, I wanted "-vvv" not "-vv".
Are ~/.ssh and all files in it on the client only readable and writable by you (chmod 0700)? Is PubkeyAuthentication set to yes in /etc/ssh/sshd_config on the server and have you restarted sshd?
|
|
|
|
08-28-2010, 09:56 AM
|
#8
|
|
Member
Registered: Oct 2005
Posts: 465
Original Poster
Rep:
|
OMG! I can't believe this. It's that simple permission thing!
Initially I had this for .ssh
drwxrwxr-x 2 backup backup 4096 Aug 28 07:52 .
When I changed .ssh to the following it works!
drwx------ 2 backup backup 4096 Aug 28 07:52 .
Thanks!
|
|
|
|
08-28-2010, 11:33 AM
|
#9
|
|
Senior Member
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,474
|
|
|
|
|
| Thread Tools |
Search this Thread |
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 07:16 AM.
|
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|