LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > SUSE / openSUSE
User Name
Password
SUSE / openSUSE This Forum is for the discussion of Suse Linux.

Notices


Reply
  Search this Thread
Old 05-15-2007, 09:05 PM   #1
swamprat
Member
 
Registered: Sep 2005
Location: New Jersey, USA
Distribution: VMware V12 and V15 in Windows 10, MX Linux 23.1, Kubuntu 23.10, IBM z/VM 5.4
Posts: 558

Rep: Reputation: 34
Question Mean of 'S' in front of permission on the ls command


Hello all,

I saw the following while doing an ls -la command and I don't know what the 'S' means in front of the permissions.

Newbie - Suse 9.2

srwxrwxrwx 1 root root 0 2007-05-15 21:04 X2


Thanks
 
Old 05-15-2007, 09:25 PM   #2
GrapefruiTgirl
LQ Guru
 
Registered: Dec 2006
Location: underground
Distribution: Slackware64
Posts: 7,594

Rep: Reputation: 556Reputation: 556Reputation: 556Reputation: 556Reputation: 556Reputation: 556
The S is the 'SUID' bit. It means that when someone runs the program, it runs with ROOT permissions (or with the permissions of its owner, in that case, ROOT).
Do some Googling about Linux File Permissions for further details, and also read the man pages for 'chmod' and 'chgrp' for more related info.

As in the 'su' command, which means 'Switch User', the SUID bit implies 'Switch User I.D.'.

S can also mean GID or STICKY, depending on its location amongst the rwx's. You can also read about this when you Google File Permissions.

Last edited by GrapefruiTgirl; 05-15-2007 at 09:26 PM.
 
Old 05-15-2007, 09:54 PM   #3
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,141

Rep: Reputation: 168Reputation: 168
In the example you give of srwxrwxrwx, X2 is a socket. If it was a file with the suid bit set it would have permissions similar to the sudo command where the execute bit for user is set to s instead of x:
Code:
$ ls -l /usr/bin/sudo
-rws--x--x 1 root bin 90400 2006-02-07 05:00 /usr/bin/sudo
Have a look at http://rute.2038bug.com/node17.html.gz for a description of permissions for files, directories, etc.
 
Old 05-16-2007, 04:21 AM   #4
GrapefruiTgirl
LQ Guru
 
Registered: Dec 2006
Location: underground
Distribution: Slackware64
Posts: 7,594

Rep: Reputation: 556Reputation: 556Reputation: 556Reputation: 556Reputation: 556Reputation: 556
@ Gilead -- thank you for the correction; once again, I learn something new as the 'socket' aspect clearly slipped right by me in the wee hours! My apology to Swamprat for any misdirection.
 
  


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
what is mean by "~/" in front of a command line? Niceman2005 Linux - Newbie 4 12-20-2004 07:59 AM
Command permission acbenny Linux - General 3 08-02-2004 08:01 AM
permission for a command bhupee Linux - Newbie 2 07-01-2004 01:45 PM
cp command change the file permission? myunicom Linux - General 6 09-24-2003 08:15 AM
Changing Permission of a command Encrypted Linux - General 5 01-16-2003 07:30 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > SUSE / openSUSE

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