SSH Connection reporting "Server refused our key"

Post new topic   Reply to topic    DD-WRT Forum Forum Index -> Broadcom SoC basierende Hardware
Author Message
jracz
DD-WRT Novice


Joined: 13 Jun 2006
Posts: 15
Location: Houston, Texas

PostPosted: Tue Jan 23, 2007 15:37    Post subject: SSH Connection reporting "Server refused our key" Reply with quote
Anyone have any ideas why when I connect to my router using SSH it would report "Server refused our key". Everything I've tried through the tunnel seems to work. I'm assuming that the tunnel is encrypted. None of the solutions I've found Googling for this error seem to work. I'm using v23 SP2.

Putty session screen shot follows

login as: root
DD-WRT v23 SP2 std (c) 2006 NewMedia-NET GmbH
Release: 09/15/06 (SVN revision: 3932)
Server refused our key
root@xxxxxxx.xxxx.xx's password:
==========================================================

____ ___ __ ______ _____ ____ _____
| _ \| _ \ \ \ / / _ \_ _| __ _|___ \|___ /
|| | || ||____\ \ /\ / /| |_) || | \ \ / / __) | |_ \
||_| ||_||_____\ V V / | _ < | | \ V / / __/ ___) |
|___/|___/ \_/\_/ |_| \_\|_| \_/ |_____|____/

DD-WRT v23 SP2
http://www.dd-wrt.com

==========================================================


DD-WRT VeryBusyBox v1.2.1 (2006.09.15-18:06+0000) Built-in shell (ash)
Enter 'help' for a list of built-in commands.

~ #
Sponsor
BrainSlayer
Site Admin


Joined: 06 Jun 2006
Posts: 6858
Location: Dresden, Germany

PostPosted: Tue Jan 23, 2007 15:56    Post subject: Reply with quote
maybe delete your local key storage
_________________
one cigarette costs 2 minutes of your life.
one bottle of beer costs 4 minutes of your life.
one working day costs 8 hours of your life.

Yummee:
Linux DD-WRT 4.14.8 #42 SMP PREEMPT Thu Dec 21 18:11:16 CET 2017 armv7l DD-WRT
root@DD-WRT:/sys# nvram get DD_BOARD
Netgear R7800
jracz
DD-WRT Novice


Joined: 13 Jun 2006
Posts: 15
Location: Houston, Texas

PostPosted: Tue Jan 23, 2007 16:52    Post subject: Reply with quote
Deleted the local key storage in the Windows Registry. When I reconnected, I got the usual pop-up that comes with the first connection, but it still reports server refused our key.
jracz
DD-WRT Novice


Joined: 13 Jun 2006
Posts: 15
Location: Houston, Texas

PostPosted: Sun Jan 28, 2007 0:06    Post subject: Reply with quote
Bad Public/Private key pair... i replaced both and it's working without issue now.
Cathinfo
DD-WRT Novice


Joined: 21 Mar 2007
Posts: 8

PostPosted: Thu Mar 22, 2007 16:36    Post subject: Reply with quote
How did you fix it?

I tried generating a new private/public key (I use PuTTY .59 to connect) and it STILL doesn't let me connect via SSH.

What exactly did you paste in the "Authorized Keys" field in DD-WRT (Administration tab)?

Matthew
jgorres
DD-WRT Novice


Joined: 08 Jun 2006
Posts: 7

PostPosted: Fri Mar 23, 2007 7:10    Post subject: Reply with quote
Good morning, Matthew,
Cathinfo wrote:
What exactly did you paste in the "Authorized Keys" field in DD-WRT (Administration tab)?

Matthew

Presuming you are using PuTTYgen for creating the key pair it worked with me when I pasted the string in the window "Public key for pasting into OpenSSH authorized_keys file".

It___ DID NOT___ work using the file created clicking on "Save public key".

Regards,
Jörn.
jracz
DD-WRT Novice


Joined: 13 Jun 2006
Posts: 15
Location: Houston, Texas

PostPosted: Fri Mar 23, 2007 11:24    Post subject: Reply with quote
I also used the public key generated by puttygen. I cut/pasted it right from the puttygen dialog box. I was also unable to use the public key data from the file created that had the public key in it. I suspect that the key file has new lines in it and that the key shouldn't contain those new lines.
Cathinfo
DD-WRT Novice


Joined: 21 Mar 2007
Posts: 8

PostPosted: Fri Mar 23, 2007 13:37    Post subject: Reply with quote
Did either of you change your password?

I have a new login name and password -- that might have something to do with why I can't log in via SSH (I can log in via web interface with no problem)

I did paste in that exact thing myself -- I have NO idea why it refuses to work.

Matthew
pipan
DD-WRT Novice


Joined: 09 Apr 2007
Posts: 1

PostPosted: Mon Apr 09, 2007 17:48    Post subject: Reply with quote
Matthew,
You shall not use your new username when trying to login. Use root as username and as password you shall use whatever you set when you created you key pair. I changed my username and tried to login with that user but got "Server refused our key" until i tried to login with root instead of my webinterface user.
frozenthorn
DD-WRT Novice


Joined: 28 Jul 2017
Posts: 3

PostPosted: Fri Jul 28, 2017 6:55    Post subject: Reply with quote
pipan wrote:
Matthew,
You shall not use your new username when trying to login. Use root as username and as password you shall use whatever you set when you created you key pair. I changed my username and tried to login with that user but got "Server refused our key" until i tried to login with root instead of my webinterface user.


THANKS! I really can't understand this bug and why nobody else points this problem out. It's 2017 and I still had to spend an hour researching to find out what is wrong.

When you first create the login anyone with a brain changes the username away from root, but nothing about the sshd login tells you to provide root as the username? I looked at a dozen guides. Thanks, swapping root works even though it isn't technically a user at all on my router =/
Display posts from previous:    Page 1 of 1
Post new topic   Reply to topic    DD-WRT Forum Forum Index -> Broadcom SoC basierende Hardware All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum