Linux - SecurityThis 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.
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.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have tried killing the SSHD process with no luck. What am I doing wrong?
So I take it you have not restarted sshd? After changing sshd_config you will need to.
The SuSE way is
Code:
sshd restart
or
Code:
/etc/init.d/sshd restart
The FreeBSD way (that I use anyway) is issuing a kill to sshd and then starting it again.
One of these should work on slackware (although your sshd script path will probably differ). So you can tinker some more or wait for a slackware expert to see this.
Totally strange. All I can think of is 1) sshd was not really restarted; or 2) the 'PermitRootLogin no' is not being parsed by the sshd script correctly because of an extra character or something.
Very curious to see the resolution for this one....
Originally posted by mattp No, actually I did restart it. I did a "kill [proc id]". It restarted on its own and still didn't work.
I am issueing all of these commands from work over the SSH if that makes any difference.
The first bit doesn't make any sense. Unless you rebooted, Slack isn't going to restart a daemon on its own. Try running /etc/rc.d/rc.sshd restart and see if that causes sshd to pick up the new setting.
Well, I was doing all of this editing thru SSH. I did Kill [Proc ID], and my connection was terminated. I tried logging in again as root and was successfull. I did ps -e and sshd had a new proc id. I supose this means that SSHD was restarted.
I guess I will have to physically look at the box when I get home.
I'm guessing here, but I bet that you just killed the ssh session you were using at the time, not the ssh daemon. If you had actually killed sshd with kill, you absolutely shouldn't have been able to reconnect via ssh unless you've got some other program monitoring sshd and starting it up again if it dies.
By the way, if you us the restart command in my previous post, it actually will maintain the ssh connections in use. The way you did it, you would need physical access to the machine to restart sshd.
handog is right. Also ...
from sshd manpage:
sshd rereads its configuration file when it receives a hangup signal,
SIGHUP, by executing itself with the name and options it was started
with, e.g., /usr/sbin/sshd.
You could also edit your rc.sshd under the sshd_start function and add the -d parameter for debugging output
If ssh is no longer allowing anyone in, you're going to have to dig through your logs (/var/log/messages and /var/log/syslog) to find some clues as to why. Even without the -d flag, ssh usually leaves some clue as to what is happening.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.