Deleted Added
full compact
setuid.2 (17995) setuid.2 (18012)
1.\" Copyright (c) 1983, 1991, 1993
2.\" The Regents of the University of California. All rights reserved.
3.\"
4.\" Redistribution and use in source and binary forms, with or without
5.\" modification, are permitted provided that the following conditions
6.\" are met:
7.\" 1. Redistributions of source code must retain the above copyright
8.\" notice, this list of conditions and the following disclaimer.

--- 16 unchanged lines hidden (view full) ---

25.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
26.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30.\" SUCH DAMAGE.
31.\"
32.\" @(#)setuid.2 8.1 (Berkeley) 6/4/93
1.\" Copyright (c) 1983, 1991, 1993
2.\" The Regents of the University of California. All rights reserved.
3.\"
4.\" Redistribution and use in source and binary forms, with or without
5.\" modification, are permitted provided that the following conditions
6.\" are met:
7.\" 1. Redistributions of source code must retain the above copyright
8.\" notice, this list of conditions and the following disclaimer.

--- 16 unchanged lines hidden (view full) ---

25.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
26.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30.\" SUCH DAMAGE.
31.\"
32.\" @(#)setuid.2 8.1 (Berkeley) 6/4/93
33.\" $Id: setuid.2,v 1.2 1996/08/29 21:24:16 wosch Exp $
33.\" $Id: setuid.2,v 1.3 1996/09/01 22:42:13 ache Exp $
34.\"
35.Dd June 4, 1993
36.Dt SETUID 2
37.Os BSD 4.2
38.Sh NAME
39.Nm setuid ,
40.Nm seteuid ,
41.Nm setgid ,

--- 12 unchanged lines hidden (view full) ---

54.Fn setegid "gid_t egid"
55.Sh DESCRIPTION
56The
57.Fn setuid
58function
59sets the real and effective
60user IDs and the saved set-user-ID of the current process
61to the specified value.
34.\"
35.Dd June 4, 1993
36.Dt SETUID 2
37.Os BSD 4.2
38.Sh NAME
39.Nm setuid ,
40.Nm seteuid ,
41.Nm setgid ,

--- 12 unchanged lines hidden (view full) ---

54.Fn setegid "gid_t egid"
55.Sh DESCRIPTION
56The
57.Fn setuid
58function
59sets the real and effective
60user IDs and the saved set-user-ID of the current process
61to the specified value.
62.\" Comment out next line for !_POSIX_SAVED_IDS
63The real user ID and the saved set-user-ID are changed only if the effective user ID is that of the super user.
62.\" Comment out next block for !_POSIX_SAVED_IDS
63The real user ID and the saved set-user-ID are changed only if the
64effective user ID is that of the super user.
65I.e.
66.Fn setuid
67function is equal to
68.Fn seteuid
69function if the effective user ID is not that of the super user.
70.\" End of block
64The
65.Fn setuid
66function is permitted if the specified ID is equal to the real user ID
67.\" Comment out next line for !_POSIX_SAVED_IDS
68or the saved set-user-ID
69of the process, or if the effective user ID is that of the super user.
70.Pp
71The
72.Fn setgid
73function
74sets the real and effective
75group IDs and the saved set-group-ID of the current process
76to the specified value.
71The
72.Fn setuid
73function is permitted if the specified ID is equal to the real user ID
74.\" Comment out next line for !_POSIX_SAVED_IDS
75or the saved set-user-ID
76of the process, or if the effective user ID is that of the super user.
77.Pp
78The
79.Fn setgid
80function
81sets the real and effective
82group IDs and the saved set-group-ID of the current process
83to the specified value.
77.\" Comment out next line for !_POSIX_SAVED_IDS
78The real group ID and the saved set-group-ID are changed only if the effective user ID is that of the super user.
84.\" Comment out next block for !_POSIX_SAVED_IDS
85The real group ID and the saved set-group-ID are changed only if the
86effective user ID is that of the super user.
87I.e.
88.Fn setgid
89function is equal to
90.Fn setegid
91function if the effective user ID is not that of the super user.
92.\" End of block
79The
80.Fn setgid
81function is permitted if the specified ID is equal to the real group ID
82.\" Comment out next line for !_POSIX_SAVED_IDS
83or the saved set-groupd-ID
84of the process, or if the effective user ID is that of the super user.
85.Pp
86The

--- 54 unchanged lines hidden ---
93The
94.Fn setgid
95function is permitted if the specified ID is equal to the real group ID
96.\" Comment out next line for !_POSIX_SAVED_IDS
97or the saved set-groupd-ID
98of the process, or if the effective user ID is that of the super user.
99.Pp
100The

--- 54 unchanged lines hidden ---