06-25-2014
...or just use groups to define a group of users? Groups being what groups are... What I would do:
Create a user specifically for the file, so that only that user has access. Then, give that user no password and an invalid login shell. So you have an account that cannot be su-ed into.
Then, use sudo to allow people in a certain group to run commands as that user -- but only the commands you want to allow, only in the exact way you want to allow. Allowing 'sudo -u username /path/to/mycustomwrapper.sh' may be one way to do this.
And finally: If any of these people have root access, there is nothing you can do to protect your system from them.
This User Gave Thanks to Corona688 For This Post:
8 More Discussions You Might Find Interesting
1. Solaris
Hello.
I am asked to build a new UNIX Server for Development environment before we could ask the high level experts to build production environment. Could you please let me know what all must I have to know and the steps inorder to build ux server?
Thank you! (0 Replies)
Discussion started by: panchpan
0 Replies
2. UNIX for Advanced & Expert Users
Hello.
I am asked to build a new UNIX Server for Development environment before we could ask the high level experts to build production environment. Could you please let me know what all must I have to know and the steps inorder to build ux server?
Thank you! (2 Replies)
Discussion started by: panchpan
2 Replies
3. Post Here to Contact Site Administrators and Moderators
Privacy Policy for The UNIX and Linux Forums
If you require any more information or have any questions about our privacy policy, please feel free to contact us by email or post your question as a reply to this thread.
At The UNIX and Linux Forums, the privacy of our visitors is of extreme... (0 Replies)
Discussion started by: Neo
0 Replies
4. Shell Programming and Scripting
For the following perl script, can anyone help to convert it to awk statement in windows2003 server environment ?
Code:
foreach $k (sort {$a <=> $b} keys %psnum) (1 Reply)
Discussion started by: tojzz
1 Replies
5. Shell Programming and Scripting
Hi All,
Let me know how can i find and delete files from one unix server to another unix server which are 'N' days older.
Please note that I need to delete files on remote unix server.So, probably i will need to use sftp, but question is how can i identify files and folders which are 'N'... (2 Replies)
Discussion started by: sachinkl
2 Replies
6. AIX
Hello guys! Can you suggest some software for doucmenting Servers?
thanks in advance
edit by bakunin: typo in thread title corrected. (14 Replies)
Discussion started by: Vit0_Corleone
14 Replies
7. UNIX for Advanced & Expert Users
Hello,
Usually I use "vxresize" to grow vxfs directory in a stand-alone server without any problems, but I am just told to grow vxfs directorys in Veritas Cluster nodes.
Since I never done it before, would like to ask all the experts here to make sure the concept and steps will be fine... (1 Reply)
Discussion started by: sunnychen98
1 Replies
8. What is on Your Mind?
Dear All,
Please read version Version 0.81 28 May 2018 of our draft
UNIX.COM General Data Privacy Regulations (GDPR) Compliance.
If you have any data privacy questions or concerns, or would like to see us address any other data privacy topic related to your personal data at UNIX.COM,... (12 Replies)
Discussion started by: Neo
12 Replies
LEARN ABOUT REDHAT
passwd
PASSWD(5) File formats PASSWD(5)
NAME
passwd - password file
DESCRIPTION
Passwd is a text file, that contains a list of the system's accounts, giving for each account some useful information like user ID, group
ID, home directory, shell, etc. Often, it also contains the encrypted passwords for each account. It should have general read permission
(many utilities, like ls(1) use it to map user IDs to user names), but write access only for the superuser.
In the good old days there was no great problem with this general read permission. Everybody could read the encrypted passwords, but the
hardware was too slow to crack a well-chosen password, and moreover, the basic assumption used to be that of a friendly user-community.
These days many people run some version of the shadow password suite, where /etc/passwd has *'s instead of encrypted passwords, and the
encrypted passwords are in /etc/shadow which is readable by the superuser only.
Regardless of whether shadow passwords are used, many sysadmins use a star in the encrypted password field to make sure that this user can
not authenticate him- or herself using a password. (But see the Notes below.)
If you create a new login, first put a star in the password field, then use passwd(1) to set it.
There is one entry per line, and each line has the format:
account:password:UID:GID:GECOS:directory:shell
The field descriptions are:
account the name of the user on the system. It should not contain capital letters.
password the encrypted user password or a star.
UID the numerical user ID.
GID the numerical primary group ID for this user.
GECOS This field is optional and only used for informational purposes. Usually, it contains the full user name. GECOS means
General Electric Comprehensive Operating System, which has been renamed to GCOS when GE's large systems division was sold
to Honeywell. Dennis Ritchie has reported: "Sometimes we sent printer output or batch jobs to the GCOS machine. The gcos
field in the password file was a place to stash the information for the $IDENTcard. Not elegant."
directory the user's $HOME directory.
shell the program to run at login (if empty, use /bin/sh). If set to a non-existing executable, the user will be unable to
login through login(1).
NOTE
If you want to create user groups, their GIDs must be equal and there must be an entry in /etc/group, or no group will exist.
If the encrypted password is set to a star, the user will be unable to login using login(1), but may still login using rlogin(1), run
existing processes and initiate new ones through rsh(1), cron(1), at(1), or mail filters, etc. Trying to lock an account by simply chang-
ing the shell field yields the same result and additionally allows the use of su(1).
FILES
/etc/passwd
SEE ALSO
passwd(1), login(1), su(1), group(5), shadow(5)
1998-01-05 PASSWD(5)