Re: Bad passphrase with public key authentication

Greg Wooledge <[email protected]> Wed, 29 Dec 2010 16:04:20 -0500
Newsgroups gmane.network.openssh.general
Message-ID <[email protected]>
On Wed, Dec 29, 2010 at 07:02:48PM +0100, Niels Stevens wrote:
> I tried generating and using different keys.
> 
> And still every time again the ssh server is complaining : "bad passphrase given, try again..." .

First of all, it's the client that says that, not the server.  The server
never sees the passphrase you use for your private key.  (It never sees
the actual private key, either.)

This problem is most likely caused by an ssh-agent caching the original
key's passphrase and attempting to use that on the new key.  Either
disable the agent, or restart it (which probably means restarting your
login session).