2025-12-16 10:20:31 -07:00
|
|
|
# doas
|
|
|
|
|
|
|
|
|
|
> Voer een commando uit als een andere gebruiker.
|
2026-02-18 06:55:01 -07:00
|
|
|
> Zie ook: `sudo`, `pkexec`, `run0`.
|
2025-12-16 10:20:31 -07:00
|
|
|
> Meer informatie: <https://man.openbsd.org/doas>.
|
|
|
|
|
|
|
|
|
|
- Voer een commando uit als root:
|
|
|
|
|
|
2026-02-18 06:55:01 -07:00
|
|
|
`doas {{commando}}`
|
2025-12-16 10:20:31 -07:00
|
|
|
|
|
|
|
|
- Voer een commando uit als een andere gebruiker:
|
|
|
|
|
|
|
|
|
|
`doas -u {{gebruiker}} {{commando}}`
|
|
|
|
|
|
|
|
|
|
- Start de standaard shell als root:
|
|
|
|
|
|
|
|
|
|
`doas -s`
|
|
|
|
|
|
|
|
|
|
- Parse een configuratiebestand en controleer of de uitvoering van het commando als een andere gebruiker toegestaan is:
|
|
|
|
|
|
2026-02-18 06:55:01 -07:00
|
|
|
`doas -C {{pad/naar/configuratiebestand}} {{commando}}`
|
2025-12-16 10:20:31 -07:00
|
|
|
|
|
|
|
|
- Zorg ervoor dat `doas` om een wachtwoord vraagt, zelfs als het eerder is opgegeven:
|
|
|
|
|
|
|
|
|
|
`doas -L`
|