Autostart failure with hyphens in username

Discussions related to using VirtualBox on Mac OS X hosts.
Post Reply
Möhre
Posts: 3
Joined: 19. May 2014, 18:40

Autostart failure with hyphens in username

Post by Möhre »

Hi,

I researched for hours why my autostart.cfg does not work for another user on OSX 10.9.1, VBOX 4.3.12.

does not work:

Code: Select all

default_policy = deny
foo-bar = {
allow = true
}
works:

Code: Select all

default_policy = deny
foobar = {
allow = true
}
works (but is only a workaround because of too less security)

Code: Select all

default_policy = allow

Edit:
----------------------------------------------------------------------------------------------
I now tested on another Mac with the same behaviour.

Here are the steps for reproduction:

Code: Select all

sudo su
cp /Applications/VirtualBox.app/Contents/MacOS/org.virtualbox.vboxautostart.plist /Library/LaunchDaemons
vim /Library/LaunchDaemons/org.virtualbox.vboxautostart.plist
org.virtualbox.vboxautostart.plist

Code: Select all

...
  <key>Disabled</key>
---  <true/>
+++  <false/>
  <key>Label</key>
...

Code: Select all

mkdir /etc/vbox
vim /etc/vbox/autostart.cfg
autostart.cfg

Code: Select all

default_policy = deny
foo-bar = {
  allow = true
}

Code: Select all

chmod +x /Applications/VirtualBox.app/Contents/MacOS/VBoxAutostartDarwin.sh
chown root:wheel /etc/vbox
chown root:wheel /etc/vbox/autostart.cfg
chown root:wheel /Library/LaunchDaemons/org.virtualbox.vboxautostart.plist
su - foo-bar VBoxManage modifyvm <VM NAME> --autostart-enabled on
su - foo-bar VBoxManage modifyvm <VM NAME> --autostop-type acpishutdown
launchctl load /Library/LaunchDaemons/org.virtualbox.vboxautostart.plist

su - foo-bar VBoxManage list runningvms
none



Can anyone confirm this bug?


THX
ChipMcK
Volunteer
Posts: 1095
Joined: 20. May 2009, 02:17
Primary OS: Mac OS X other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows, OSX
Location: U S of A

Re: Autostart failure with hyphens in username

Post by ChipMcK »

As I recall, most users of this feature are on Linux Hosts.
You may get a response there, VirtualBox on Linux Hosts.
Möhre
Posts: 3
Joined: 19. May 2014, 18:40

Re: Autostart failure with hyphens in username

Post by Möhre »

I was not sure if it is maybe only related to OSX
ChipMcK
Volunteer
Posts: 1095
Joined: 20. May 2009, 02:17
Primary OS: Mac OS X other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows, OSX
Location: U S of A

Re: Autostart failure with hyphens in username

Post by ChipMcK »

Möhre wrote:I was not sure if it is maybe only related to OSX
LOL! Linux: starting the autostart service
Möhre
Posts: 3
Joined: 19. May 2014, 18:40

Re: Autostart failure with hyphens in username

Post by Möhre »

Nah, u got me wrong. I meant the misbehaviour... Maybe the Bug is only on OSX. Never tried a "normal" Linux distro.
Post Reply