Project

General

Profile

Actions

Feature #13764

closed

bhyve could reduce privileges(5)

Added by Andy Fiddaman 9 months ago. Updated 8 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
bhyve
Start date:
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:

Description

By default, bhyve(1M) runs as root with all privileges. We could use illumos privileges to reduce this.
(NB: when run in a zone on SmartOS, OmniOS and OpenIndiana, the privileges are already reduced using the brand config, but they could still be reduced further)


Related issues

Related to illumos gate - Bug #13788: restart of privilege-aware zone init failsClosedAndy Fiddaman

Actions
Actions #1

Updated by Electric Monk 9 months ago

  • Gerrit CR set to 1454
Actions #2

Updated by Andy Fiddaman 9 months ago

  • Subject changed from bhyve could use privileges(5) to bhyve could reduce privileges(5)
Actions #3

Updated by Andy Fiddaman 9 months ago

  • Related to Bug #13788: restart of privilege-aware zone init fails added
Actions #4

Updated by Andy Fiddaman 8 months ago

This change has been tested on OmniOS with a wide range of guests and combinations of devices and options.

The final version that has been submitted for RTI only drops privileges after all of the setup is done which minimises the risk of regressions.

Also note that since bhyve branded zones on OmniOS, OpenIndiana and SmartOS already reduce privileges at the zone brand level, there is a lot of experience of running bhyve with reduced privileges on illumos.

Actions #5

Updated by Electric Monk 8 months ago

  • Status changed from In Progress to Closed
  • % Done changed from 0 to 100

git commit 2817ebc2366683391690bbd0e0dd2e82aaa281f7

commit  2817ebc2366683391690bbd0e0dd2e82aaa281f7
Author: Andy Fiddaman <omnios@citrus-it.co.uk>
Date:   2021-05-24T18:14:16.000Z

    13764 bhyve could reduce privileges(5)
    Reviewed by: Robert Mustacchi <rm@fingolfin.org>
    Approved by: Dan McDonald <danmcd@joyent.com>

Actions

Also available in: Atom PDF