DOAS(1) | General Commands Manual | DOAS(1) |
doas
— execute
commands as another user
doas |
[-ns ] [-a
style] [-C
config] [-u
user] command
[args] |
The doas
utility executes the given
command as another user. The command argument is
mandatory unless -C
or -s
is
specified.
The options are as follows:
-a
style-C
configdoas
will also perform command matching. In the
latter case either ‘permit’, ‘permit nopass’
or ‘deny’ will be printed on standard output, depending on
command matching results. No command is executed.-n
doas
would prompt
for password.-s
SHELL
or
/etc/passwd.-u
userThe doas
utility exits 0 on
success, and >0 if an error occurs. It may fail for one of the
following reasons:
The doas
command first appeared in
OpenBSD 5.8.
Ted Unangst <tedu@openbsd.org>
June 11, 2016 | OpenBSD-6.0 |