LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
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 04-20-2009, 02:09 PM   #1
maas187
Member
 
Registered: Aug 2008
Location: Yemen
Distribution: Fedora, CentOS, RedHat , OpenFiler, ESXI
Posts: 225

Rep: Reputation: 32
Question Sshd_config/


Hi to all,

I have a trixbox machine which is really CentOS , for some reason my sshd_config becare read only ? and i cant edit it . and i believe by default root can edit this file ?

just want to know if my system has been hijacked ? or is this normal ?

thank you
 
Old 04-20-2009, 02:10 PM   #2
kentyler
Member
 
Registered: Dec 2008
Location: Newark Ohio
Distribution: Fedora Core
Posts: 270

Rep: Reputation: 38
run lsattr on the file and see if it's attributes are set, if so the machine may be owned.
 
Old 04-20-2009, 02:20 PM   #3
maas187
Member
 
Registered: Aug 2008
Location: Yemen
Distribution: Fedora, CentOS, RedHat , OpenFiler, ESXI
Posts: 225

Original Poster
Rep: Reputation: 32
Quote:
Originally Posted by kentyler View Post
run lsattr on the file and see if it's attributes are set, if so the machine may be owned.
well just want to know if this is normal behavior from sshd_config ?


thanks
 
Old 04-20-2009, 02:23 PM   #4
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
You can run "sudo rpm -qV openssh" to check if the permissions have changed.

Also take selinux into consideration.

Last edited by jschiwal; 04-20-2009 at 02:24 PM.
 
Old 04-20-2009, 02:42 PM   #5
maas187
Member
 
Registered: Aug 2008
Location: Yemen
Distribution: Fedora, CentOS, RedHat , OpenFiler, ESXI
Posts: 225

Original Poster
Rep: Reputation: 32
Thank you guys.
 
Old 04-21-2009, 06:03 PM   #6
anomie
Senior Member
 
Registered: Nov 2004
Location: Texas
Distribution: RHEL, Scientific Linux, Debian, Fedora
Posts: 3,935
Blog Entries: 5

Rep: Reputation: Disabled
No, that is not normal (unless you or another sysadmin removed the write permission). What does it show when you do a long listing:

# ls -l /etc/ssh/sshd_config

?

And what does this command show?

# mount

(A damaged filesystem can cause / to mount ro.)
 
Old 04-21-2009, 11:07 PM   #7
maas187
Member
 
Registered: Aug 2008
Location: Yemen
Distribution: Fedora, CentOS, RedHat , OpenFiler, ESXI
Posts: 225

Original Poster
Rep: Reputation: 32
Quote:
Originally Posted by anomie View Post
No, that is not normal (unless you or another sysadmin removed the write permission). What does it show when you do a long listing:

# ls -l /etc/ssh/sshd_config

?

And what does this command show?

# mount

(A damaged filesystem can cause / to mount ro.)
I shows the permission 600. or 400 i think .

iam not infront of the machine now .
 
Old 04-21-2009, 11:09 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
It should be 600 (ie rw for root only)
 
  


Reply



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
sshd_config settings powah Linux - Security 3 06-03-2008 01:59 PM
sshd_config Debian Sarge keenboy Linux - Security 2 05-20-2008 08:40 AM
sshd_config allowusers allowgroups wolfipa Linux - Software 2 08-02-2007 05:59 AM
Cannot edit sshd_config as root LOLobo Linux - Server 3 12-16-2006 02:15 PM
sshd_config eyt Linux - Newbie 2 02-19-2004 12:05 PM

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

All times are GMT -5. The time now is 07:52 AM.

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