xref: /freebsd/usr.bin/mdo/mdo.1 (revision 95eb4b873b6a8b527c5bd78d7191975dfca38998)
1.\"-
2.\" Copyright(c) 2024 Baptiste Daroussin <bapt@FreeBSD.org>
3.\"
4.\" SPDX-License-Identifier: BSD-2-Clause
5.\"
6.Dd May 22, 2024
7.Dt MDO 1
8.Os
9.Sh NAME
10.Nm mdo
11.Nd execute commands as another user
12.Sh SYNOPSIS
13.Nm
14.Op Fl u Ar username
15.Op Fl i
16.Op command Op args
17.Sh DESCRIPTION
18The
19.Nm
20utility executes the specified
21.Ar command
22as user
23.Ar username .
24.Pp
25If no
26.Ar username
27is provided it defaults to the
28.Va root
29user.
30If no
31.Ar command
32is specified, it will execute the shell specified as
33.Va SHELL
34environnement variable, falling back on
35.Pa /bin/sh .
36.Pp
37The
38.Fl i
39option can be used to only call
40.Fn setuid
41and keep the group from the calling user.
42.Sh SEE ALSO
43.Xr su 1
44.Xr mac_do 4
45