LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 05-03-2012, 02:52 PM   #1
Upendra Pratap Singh
Member
 
Registered: May 2011
Location: India
Distribution: Ubuntu 14.04
Posts: 110
Blog Entries: 4

Rep: Reputation: 0
Question public key VS private key in automation


Hi,

I learnt some basics of automation in linux using ssh.

Suppose that I have distributed my public key to remote systems that I want an access to, and that I have lost my private key.

Under this situation the solution lies in generating a new pair of public and private key using ssh-keygen.

Will generating a new public and private key pair overwrite the previous public key(the private key to which I have lost) or the previous public key would still be available to the person who has stolen my private key.

Regards,

Upendra Pratap Singh
 
Old 05-03-2012, 02:59 PM   #2
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,831
Blog Entries: 15

Rep: Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669
It will overwrite the private and public key for the user/host on which you run the command.

However, any site that has a trust using your public key would also have to get the new public key from the user/host you did the generate on. If you your private key has actually been "stolen" as you said you should advise all people that have the old public key to immediately remove it then add your new one. It is the key rather than the host/user that specifies the source of the connection so anyone with the old private key can pretend to be the user/host that generated it originally.
 
  


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
can we regenerate public key from private key hahacc Linux - Security 1 02-07-2012 09:24 PM
SSH skips public key authentication for a key, but works with another key simopal6 Linux - General 1 07-06-2011 08:33 AM
Public key, private key explained calande Linux - Security 3 06-12-2008 05:23 AM
need help with SSH private/public key taduser Linux - Security 2 04-02-2007 07:07 PM
RSA public key encryption/private key decription koningshoed Linux - Security 1 08-08-2002 07:25 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

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