LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 10-18-2008, 03:27 PM   #1
phantom_cyph
Senior Member
 
Registered: Feb 2007
Location: The Tropics
Distribution: Slackware & Derivatives
Posts: 2,472
Blog Entries: 1

Rep: Reputation: 128Reputation: 128
Unhappy SSH Multiple Problems


Here's my setup:

2 Desktops (A and B) and one server (C)

Desktop A is setup up only as a ssh client, not server, and can access both B and C. B and C cannot access Desktop A, but are set to only accept SSH connections from A's internal IP (on port 22).

This setup worked fine last night. However, now, server (C) cannot be accessed. A can ssh to B, but not to C. C no longer contains the $home/.ssh directory or the known_hosts file in it.

When telling ssh on C to restart (via direct input) it spits out the following errors:

Code:
 * Restarting OpenBSD Secure Shell server...
Could not load host key: /etc/ss/ssh_host_rsa_key
Could not load host key: /etc/ss/ssh_host_dsa_key
Could not load host key: /etc/ss/ssh_host_rsa_key
Could not load host key: /etc/ss/ssh_host_rsa_key
[ OK ]
I also tried the instructions here in another thread about ssh gone wild and used the command: tail -f /var/log/secure.

Whereas in the other thread the user received output, I don't actually have that file.

Strange things that have happened in 10 hours:

Although everything is messed up, Apache is still running and my websites are still up. However, my email PHP scripts will no longer send email. This has change literally overnight and I have not done anything to change the files.

I am using the Firestarter Firewall and leave the GUI running so I can monitor any
"events" that occur. There were 4 ssh attempts last night, and I'm not sure if Firestarter would report anything if one of its rules was broken. It is set to be restrictive by nature and whitelist ports as opposed to being open and blacklist.

Any help is appreciated, only request is that I get some help soon.

Thank you!
 
Old 10-18-2008, 03:55 PM   #2
billymayday
LQ Guru
 
Registered: Mar 2006
Location: Sydney, Australia
Distribution: Fedora, CentOS, OpenSuse, Slack, Gentoo, Debian, Arch, PCBSD
Posts: 6,678

Rep: Reputation: 122Reputation: 122
I'd start with post 3 here http://www.linuxquestions.org/questi...server-664871/
 
Old 10-18-2008, 04:11 PM   #3
phantom_cyph
Senior Member
 
Registered: Feb 2007
Location: The Tropics
Distribution: Slackware & Derivatives
Posts: 2,472

Original Poster
Blog Entries: 1

Rep: Reputation: 128Reputation: 128
Thanks for the link! I already have one question...

Should I assume that any of the files found by the following commands are bad?

find / -user root -perm -4000 -print
find / -group kmem -perm -2000 -print


Surely some are built in to Linux. Maybe I simply don't understand what a setuid file is. If they are all a hindrance to my computer, I have a long list of nasties.
 
Old 10-18-2008, 04:24 PM   #4
phantom_cyph
Senior Member
 
Registered: Feb 2007
Location: The Tropics
Distribution: Slackware & Derivatives
Posts: 2,472

Original Poster
Blog Entries: 1

Rep: Reputation: 128Reputation: 128
Just ran rkhunter over my whole system. Apparently root login via ssh was permitted. Which is not something I had set. Besides that, it hasn't found anything.
 
Old 10-20-2008, 11:39 AM   #5
phantom_cyph
Senior Member
 
Registered: Feb 2007
Location: The Tropics
Distribution: Slackware & Derivatives
Posts: 2,472

Original Poster
Blog Entries: 1

Rep: Reputation: 128Reputation: 128
No more ideas?
 
Old 10-20-2008, 12:51 PM   #6
chort
Senior Member
 
Registered: Jul 2003
Location: Silicon Valley, USA
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660

Rep: Reputation: 76
Quote:
Originally Posted by phantom_cyph View Post
When telling ssh on C to restart (via direct input) it spits out the following errors:

Code:
 * Restarting OpenBSD Secure Shell server...
Could not load host key: /etc/ss/ssh_host_rsa_key
Could not load host key: /etc/ss/ssh_host_dsa_key
Could not load host key: /etc/ss/ssh_host_rsa_key
Could not load host key: /etc/ss/ssh_host_rsa_key
[ OK ]
I also tried the instructions here in another thread about ssh gone wild and used the command: tail -f /var/log/secure.
You made a typo in some config file, because it's looking in the wrong directory (/etc/ss/ instead of /etc/ssh/).

Also, on OpenBSD the ssh stuff is in /var/log/authlog, not /var/log/secure .
 
Old 10-20-2008, 02:04 PM   #7
phantom_cyph
Senior Member
 
Registered: Feb 2007
Location: The Tropics
Distribution: Slackware & Derivatives
Posts: 2,472

Original Poster
Blog Entries: 1

Rep: Reputation: 128Reputation: 128
Well, first of all, I'm not using OpenBSD...

I checked my /etc/ssh/sshd_config file and the pathnames are correct. The files do exist in /etc/ssh and they do have keys in them, so I still have no idea what the problem is.
 
Old 10-20-2008, 02:45 PM   #8
billymayday
LQ Guru
 
Registered: Mar 2006
Location: Sydney, Australia
Distribution: Fedora, CentOS, OpenSuse, Slack, Gentoo, Debian, Arch, PCBSD
Posts: 6,678

Rep: Reputation: 122Reputation: 122
Read post 1 again - you are pointing to

/etc/ss/sshd_*

not

/etc/ssh/sshd_*
 
Old 10-20-2008, 11:51 PM   #9
chort
Senior Member
 
Registered: Jul 2003
Location: Silicon Valley, USA
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660

Rep: Reputation: 76
Quote:
Originally Posted by phantom_cyph View Post
Code:
 * Restarting OpenBSD Secure Shell server...
If this isn't OpenBSD, what the heck is it? What OS are you running, and what modifications have you applied?

Quote:
Code:
Could not load host key: /etc/ss/ssh_host_rsa_key
Could not load host key: /etc/ss/ssh_host_dsa_key
Could not load host key: /etc/ss/ssh_host_rsa_key
Could not load host key: /etc/ss/ssh_host_rsa_key
Your service stop/start script is looking in the wrong directory! It's not going to do you any good to check the files in /etc/ssh/, because the service isn't looking for files there. Whatever command you're using to reload ssh is calling a script or reading a config file that has a typo. Please read what we are telling you.

Code:
$ sudo grep '/ss/' /etc/*
should show you where you've gone wrong.

Last edited by chort; 10-20-2008 at 11:52 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
multiple ssh at once Four Linux - General 2 01-25-2008 10:55 AM
LXer: ssh on multiple servers Using cluster ssh LXer Syndicated Linux News 0 01-11-2008 03:40 PM
SSH tunneling with multiple IPs phoinix Linux - Networking 2 03-27-2007 01:09 PM
SSH to multiple servers DigiCrime Linux - General 6 06-22-2006 08:19 AM
router to multiple IP forwarding for ssh rmanocha Linux - Networking 8 10-27-2003 01:51 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

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