Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hardened VirtualBox is broken #24512

Closed
abbradar opened this issue Mar 31, 2017 · 2 comments
Closed

Hardened VirtualBox is broken #24512

abbradar opened this issue Mar 31, 2017 · 2 comments
Labels
0.kind: bug Something is broken
Milestone

Comments

@abbradar
Copy link
Member

abbradar commented Mar 31, 2017

Issue description

  1. We need to wrap Qt 5 applications for them to work correctly (for example to have working file dialogs when GTK3 integration is used) -- so we wrap VirtualBox;
  2. Wrappers are currently implemented as shell scripts (see wrapProgram & friends depend on linux kernel shebang feature #11133);
  3. Hardened VirtualBox requires its binaries to be suid -- we achieve this using our setuid wrappers.

We need to save all uids in our wrapper intact and Linux doesn't allow us to run shell scripts that way. So we can't currently fully use hardened VirtualBox (especially in GTK environments, but other bugs may surface).

Steps to reproduce

  1. Install and run hardened VirtualBox;
  2. Attempt to open a file in a GTK environment.

Technical details

  • System: (NixOS: nixos-version, Ubuntu/Fedora: lsb_release -a, ...) 186cc51

A proper way out of this is to fix #11133 however we also need to somehow fix this on release channel without introducing such groundbreaking changes. I propose to disable hardening in VirtualBox on 17.03 unless anyone has a better idea.

EDIT: clarified that VirtualBox works somewhat, but not ideally.

@abbradar abbradar added the 0.kind: bug Something is broken label Mar 31, 2017
@abbradar abbradar added this to the 17.03 milestone Mar 31, 2017
@IreneKnapp
Copy link
Contributor

I am also experiencing this. The workaround, in case it's not obvious to somebody, is virtualisation.virtualbox.host.enableHardening = false. And for the benefit of people coming here from a web search, this can manifest as "Failed to open a session for the virtual machine ____" with details like:

The virtual machine 'Steam' has terminated unexpectedly during startup with exit code 1 (0x1).

Result Code:
NS_ERROR_FAILURE (0x80004005)
Component:
MachineWrap
Interface:
IMachine {b2547866-a0a1-4391-8b86-6952d82efaa0}

Or at least, I'm reasonably sure the error I'm experiencing is caused by this issue; it occurs when clicking to open a GTK file box to choose a boot disk while setting up a never-booted VM.

@fpletz
Copy link
Member

fpletz commented Jul 25, 2017

Is this the same issue as #5283?

@fpletz fpletz modified the milestones: 17.09, 17.03 Jul 25, 2017
@matthewbauer matthewbauer modified the milestones: 17.09, 18.09 Apr 17, 2018
@matthewbauer matthewbauer modified the milestones: 18.09, 19.03 Nov 5, 2018
@matthewbauer matthewbauer modified the milestones: 19.03, 19.09 May 27, 2019
@veprbl veprbl modified the milestones: 19.09, 20.03 Nov 20, 2019
@alyssais alyssais closed this as completed Apr 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0.kind: bug Something is broken
Projects
None yet
Development

No branches or pull requests

6 participants