- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- File Permission
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2002 09:29 PM
06-13-2002 09:29 PM
What is the difference between the following file permission of abc1 and abc2:
-rwsr-sr-- 1 root informix 242 Jun 13 2002 abc1
-rwSr-Sr-- 1 root informix 242 Jun 13 2002 abc2
What is the meaning of small "s" and capital "s" and where are they used?
Thanks,
Raje.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2002 09:40 PM
06-13-2002 09:40 PM
Re: File Permission
rws
s setuid with execute permissions
rwS
S setuid without execute permissions
The first one is for the user(setuid)
The next one
r-s
setgid with execute permissions
r-S
setgid without execute permissions
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2002 09:46 PM
06-13-2002 09:46 PM
SolutionWhen a file is executed by a user he gets the permission of the owner during the execution of that file.
For ex.
consider you have the /etc/passwd file and the /usr/bin/passwd .
Normally the user cannot alter the /etc/passwd file as he has no permissions.
But when he is using the passwd command he is able to change it.
If you check the /usr/bin/passwd permissions
it is -r-sr-xr-x
So when the /usr/bin/passwd command is executed by the normal user he gets the permission of root during the execution of the command as he has the setuid set for that command.
During the execution he has the permissions of the owner.
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2002 09:47 PM
06-13-2002 09:47 PM
Re: File Permission
The small s and big S is used to differentiate whether executable bits are set.
-rwS------
The big S in the first set (user portion) means setuid bits has been set without executable bits on.
----rwS---
The big S in the 2nd set (group portion) means setgid bits has been set without executable bits on.
If the executabie bits have been set before the setuid/setgid bits are set, then it will use the small letter s.
An example will be clearer:
# touch a
# ll a
-rw-r--r-- 1 root root 0 Jun 14 13:45 a
# chmod +s a
# ll a
-rwSr-Sr-- 1 root root 0 Jun 14 13:45 a
# chmod +x a
# ll a
-rwsr-sr-x 1 root root 0 Jun 14 13:45 a
# touch b
# ll b
-rw-r--r-- 1 root root 0 Jun 14 13:47 b
# chmod +x b
# ll b
-rwxr-xr-x 1 root root 0 Jun 14 13:47 b
# chmod +s b
# ll b
-rwsr-sr-x 1 root root 0 Jun 14 13:47 b
Hope this helps. Regards.
Steven Sim Kok Leong
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2002 09:56 PM
06-13-2002 09:56 PM
Re: File Permission
eg.
#touch test
#chmod u+s test
sets setuserid suid rwsr
#chmod g+S test
sets setgroupid sgid rwS
regards,
U.SivaKumar