LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-27-2018, 06:12 AM   #1
catiewong
Member
 
Registered: Aug 2018
Posts: 190

Rep: Reputation: Disabled
what is of difference of this two directories


I have two directories in same server , ls -ld show different result , one have "." , what is the difference of these two directories ?


Code:
drwxr-xr-x  
drwxr-xr-x.
 
Old 12-27-2018, 06:32 AM   #2
sgrlscz
Member
 
Registered: Aug 2008
Posts: 123

Rep: Reputation: 84
The '.' at the end indicates there is an SELinux context on that directory. If you use 'ls -Zd' on the directory, it'll show the context.

SELinux can be either enabled or disabled. If enabled, it can be either enforcing or permissive. If enforcing, it provides additional access control. If permissive, it doesn't block access that would be denied if enforcing, but it logs messages to audit those accesses that would violate the policy in place.
 
1 members found this post helpful.
Old 12-27-2018, 06:46 AM   #3
catiewong
Member
 
Registered: Aug 2018
Posts: 190

Original Poster
Rep: Reputation: Disabled
the SElinux is co-related with sshd_config , or they do not have any relation ?
 
Old 12-27-2018, 07:04 AM   #4
dc.901
Senior Member
 
Registered: Aug 2018
Location: Atlanta, GA - USA
Distribution: CentOS/RHEL, openSuSE/SLES, Ubuntu
Posts: 1,005

Rep: Reputation: 370Reputation: 370Reputation: 370Reputation: 370
Quote:
Originally Posted by catiewong View Post
the SElinux is co-related with sshd_config , or they do not have any relation ?
Don't understand your question...
May be these will help:
https://access.redhat.com/documentat...ide/ch-selinux

https://access.redhat.com/documentat...ide/ch-openssh
 
1 members found this post helpful.
Old 12-27-2018, 07:17 AM   #5
sgrlscz
Member
 
Registered: Aug 2008
Posts: 123

Rep: Reputation: 84
You're question isn't really clear. SELinux affects file access, so it can affect sshd's functionality. However, it's not specific to sshd, it can affect any file access on the system, so it affects all applications and users. It's an OS feature.

SELinux is a security feature. You can see if it's enabled using sestatus. For example (bold added by me):

Code:
> sestatus
SELinux status:                 enabled
SELinuxfs mount:                /sys/fs/selinux
SELinux root directory:         /etc/selinux
Loaded policy name:             targeted
Current mode:                   enforcing
Mode from config file:          enforcing
Policy MLS status:              enabled
Policy deny_unknown status:     allowed
Max kernel policy version:      31
On this system, it's enabled and enforcing. Because of that, file access is affected not only by the permissions on files/directories, but also the SELinux context, which can create issues because permissions may look fine, but access still gets denied.
 
1 members found this post helpful.
  


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
[SOLVED] List Difference Between Two Directories devUnix Linux - General 2 12-06-2012 07:21 AM
Merging Two Files from Two Different Directories scittlez227 Linux - General 6 05-20-2011 08:31 AM
shell script to find the difference betwwn two file and place the difference to other kittunot4u Linux - General 3 07-19-2010 04:26 AM
how to compare two directories residing in two different servers prasenjit.patra AIX 2 09-28-2009 09:20 PM
two, two, two cd players in one blistfix Linux - Newbie 3 07-03-2001 04:18 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

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