View previous topic :: View next topic |
Author |
Message |
demonace n00b
Joined: 15 Apr 2002 Posts: 9
|
Posted: Tue Apr 16, 2002 5:23 am Post subject: ssh connection problems |
|
|
i am having a problem connecting to my gentoo box with ssh as any user other than root.
i can ssh from another linux box(mandrake) or using putty on a win box and log in as root.
useing a username always gives me auth problems. but i can use the user name in a local login and it works fine. All i can think of is that the sshd is not reading the passwords properly.
i get the key host key fine.
I'm not familer with openssh setup enough to know what to look for. any ideas?
i have also tried "emerge openssh" again. and no luck.
i have also made sure several times that the password is correct.
i'm at a loss at the moment. |
|
Back to top |
|
|
anonymous coward Guest
|
Posted: Tue Apr 16, 2002 1:24 pm Post subject: ssh |
|
|
SSH is not set up automagically. You will need to edit some conf files. Man sshd for more information. Basically you have to allow users or groups in sshd conf file. |
|
Back to top |
|
|
demonace n00b
Joined: 15 Apr 2002 Posts: 9
|
Posted: Tue Apr 16, 2002 7:09 pm Post subject: still no luck |
|
|
I have looked at a working SSH setup and edited the gentoo machine setup. still can log in as root, not as user.
was there info that i missed after openssh installed? |
|
Back to top |
|
|
warren smith Guest
|
Posted: Tue Apr 16, 2002 8:40 pm Post subject: Re: still no luck |
|
|
i am also having the same problem.
line from passwd:
Code: | wsmith:x:1000:100::/home/wsmith:/bin/bash |
i copied the sshd_config from a working box as well, with no luck. Also tried AllowUsers/AllowGroups commands in config file. |
|
Back to top |
|
|
Nitro Bodhisattva
Joined: 08 Apr 2002 Posts: 661 Location: San Francisco
|
Posted: Tue Apr 16, 2002 8:55 pm Post subject: |
|
|
I have ssh running with just the following in my config file:
Code: | Port 22
Protocol 2
ListenAddress 0.0.0.0 |
Might want to take a look at the permissions on the user's home directory too. If permissions aren't the problem, make sure you did set a password (everyone forgets the simple things sometimes ). If you are still having problems, look for authentication failure information in you you log files (directory is: /var/log/ ) and post it here. _________________ - Kyle Manna
Please, please SEARCH before posting.
There are three kinds of people in the world: those who can count, and those who can't. |
|
Back to top |
|
|
warren smith Guest
|
Posted: Tue Apr 16, 2002 10:41 pm Post subject: |
|
|
got it! it was in the sshd_config file. thanks! |
|
Back to top |
|
|
demonace n00b
Joined: 15 Apr 2002 Posts: 9
|
Posted: Tue Apr 16, 2002 11:55 pm Post subject: |
|
|
Apr 16 13:58:07 [sshd] debug1: Starting up PAM with username "demonace"
Apr 16 13:58:07 [sshd] debug3: Trying to reverse map address 192.168.1.42.
Apr 16 13:58:07 [sshd] debug1: PAM setting rhost to "host"
Apr 16 13:58:07 [sshd] debug1: Attempting authentication for demonace.
Apr 16 13:58:13 [sshd] debug1: PAM Password authentication for "demonace" failed[7]: Authentication failure
This is the error message, i setup LogLevel DEBUG3 in the sshd_config file.
i have reset the password to several times, and i don't know why i can't login non root. |
|
Back to top |
|
|
Nitro Bodhisattva
Joined: 08 Apr 2002 Posts: 661 Location: San Francisco
|
Posted: Wed Apr 17, 2002 12:05 am Post subject: |
|
|
Can you give me the contents of /etc/pam.d/sshd?
My /etc/pam.d/sshd contains: Code: | #%PAM-1.0
auth required pam_stack.so service=system-auth
auth required pam_shells.so
auth required pam_nologin.so
account required pam_stack.so service=system-auth
password required pam_stack.so service=system-auth
session required pam_stack.so service=system-auth |
_________________ - Kyle Manna
Please, please SEARCH before posting.
There are three kinds of people in the world: those who can count, and those who can't. |
|
Back to top |
|
|
demonace n00b
Joined: 15 Apr 2002 Posts: 9
|
Posted: Wed Apr 17, 2002 12:21 am Post subject: |
|
|
here is my /etc/pam.d/sshd
Code: |
#%PAM-1.0
auth required pam_stack.so service=system-auth
auth required pam_shells.so
auth required pam_nologin.so
account required pam_stack.so service=system-auth
password required pam_stack.so service=system-auth
session required pam_stack.so service=system-auth
|
its the same as what your sys has
but i found the problem when i was going to include part of my /etc/passwd
Code: |
demonace:x:1004:100::/home/demonace:
|
i fixed it to
Code: |
demonace:x:1004:100::/home/demonace:/bin/bash
|
and now i can login, it seems that useradd is broken
or i'm just used to /bin/bash being included automaticly |
|
Back to top |
|
|
Cr0t l33t
Joined: 27 Apr 2002 Posts: 944 Location: USA
|
Posted: Tue May 07, 2002 10:27 pm Post subject: |
|
|
thx man i had the same problem
_________________ cya |
|
Back to top |
|
|
Nitro Bodhisattva
Joined: 08 Apr 2002 Posts: 661 Location: San Francisco
|
Posted: Tue May 07, 2002 10:32 pm Post subject: |
|
|
demonace wrote: | it seems that useradd is broken
or i'm just used to /bin/bash being included automaticly |
If you want to set your default shell to /bin/bash do: Code: | useradd -D -s /bin/bash |
_________________ - Kyle Manna
Please, please SEARCH before posting.
There are three kinds of people in the world: those who can count, and those who can't. |
|
Back to top |
|
|
pjp Administrator
Joined: 16 Apr 2002 Posts: 20067
|
Posted: Sun Aug 18, 2002 3:06 pm Post subject: |
|
|
From Bugs to Networking & Security. _________________ Quis separabit? Quo animo? |
|
Back to top |
|
|
|