02-09-2005
How can l create a user that as all the Attribute & Privilages of root
Hi,
Is it possible to create a user in Linux 8.0 with all the attribute and the privilages of super user (root). Without using root as the logg in name.
Thanx
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Is there a way to create or better yet modify a user account so it has the same privs as root? (6 Replies)
Discussion started by: xadamz23
6 Replies
2. UNIX for Advanced & Expert Users
Hi all,
I am using Sun Solaris 9 .In this system normal users unable to create files from the command line.I added these users in bin,adm and even root group i found them unable to create a file. (1 Reply)
Discussion started by: mallesh
1 Replies
3. Shell Programming and Scripting
I maintain the root password so the other sysadmins cannot have it due to security. They have a script that is used to shutdown and reboot multiple clients. but it needs to be run as root. they mentioned sticky bit and another type of setting called RBAC. I want them to be able to run this script... (4 Replies)
Discussion started by: deaconf19
4 Replies
4. SCO
I need to regular users to be able to launch a script which does something requiring root privilages. I've tried using chmod 4755 which gives it
-rwsr-xr-x permissions but it still can not be run as the regular user. (1 Reply)
Discussion started by: checkpro
1 Replies
5. AIX
hello
I would like to create another user like root
With smit user, I have duplicate all the configuration from root to root2 (groupe, secondary group, administrative, etc...)
But when I connect with root2, i don't go to all directory: "permission denied !"
I don't understand where is the... (10 Replies)
Discussion started by: pascalbout
10 Replies
6. Shell Programming and Scripting
Hi All,
I have directory under /opt/test.
The ownership of the test directory is root:root.
I have login to the server as test user.
I need to have some script to create a directory inside /opt/test.
This script will be called as test user.
When I try to execute... (4 Replies)
Discussion started by: kalpeer
4 Replies
7. Solaris
Hi All,
I am trying to uninstall jdk 1.5 from my Solaris 10 64 bit but some how was not successful.so tried to delete the folder of jdk from /usr but its throughing error as:
Unable to remove directory jdk: Read-only file system
Even I tried to create a dir in /usr but its not allowing me... (4 Replies)
Discussion started by: Pshah
4 Replies
8. AIX
please give me any suggestion, how can i create user as root privilege. (please give me very safest way because i have production servers) (5 Replies)
Discussion started by: reply.ravi
5 Replies
9. UNIX for Dummies Questions & Answers
Hi All,
I need to give an user sudo ability to root.
We have also generated RSA key but unable to proceed further.
For example after a user logs into the server normally and when he executes below command
$ssh root@server_name
This should take you to root prompt #
Please help me.... (3 Replies)
Discussion started by: Rockyc3400
3 Replies
10. UNIX for Dummies Questions & Answers
Is there any way to create a file in linux that root user also can't delete? (8 Replies)
Discussion started by: palani13dec
8 Replies
SETUID(2) Linux Programmer's Manual SETUID(2)
NAME
setuid - set user identity
SYNOPSIS
#include <sys/types.h>
#include <unistd.h>
int setuid(uid_t uid);
DESCRIPTION
setuid() sets the effective user ID of the calling process. If the effective UID of the caller is root, the real UID and saved set-user-ID
are also set.
Under Linux, setuid() is implemented like the POSIX version with the _POSIX_SAVED_IDS feature. This allows a set-user-ID (other than root)
program to drop all of its user privileges, do some un-privileged work, and then reengage the original effective user ID in a secure man-
ner.
If the user is root or the program is set-user-ID-root, special care must be taken. The setuid() function checks the effective user ID of
the caller and if it is the superuser, all process-related user ID's are set to uid. After this has occurred, it is impossible for the
program to regain root privileges.
Thus, a set-user-ID-root program wishing to temporarily drop root privileges, assume the identity of an unprivileged user, and then regain
root privileges afterwards cannot use setuid(). You can accomplish this with seteuid(2).
RETURN VALUE
On success, zero is returned. On error, -1 is returned, and errno is set appropriately.
ERRORS
EAGAIN The uid does not match the current uid and uid brings process over its RLIMIT_NPROC resource limit.
EPERM The user is not privileged (Linux: does not have the CAP_SETUID capability) and uid does not match the real UID or saved set-user-ID
of the calling process.
CONFORMING TO
SVr4, POSIX.1-2001. Not quite compatible with the 4.4BSD call, which sets all of the real, saved, and effective user IDs.
NOTES
Linux Notes
Linux has the concept of file system user ID, normally equal to the effective user ID. The setuid() call also sets the file system user ID
of the calling process. See setfsuid(2).
If uid is different from the old effective uid, the process will be forbidden from leaving core dumps.
SEE ALSO
getuid(2), seteuid(2), setfsuid(2), setreuid(2), capabilities(7), credentials(7)
COLOPHON
This page is part of release 3.27 of the Linux man-pages project. A description of the project, and information about reporting bugs, can
be found at http://www.kernel.org/doc/man-pages/.
Linux 2010-02-21 SETUID(2)