Virtualbox & kernel 2.6.37-grsec - is possible?
Posted: Tue Mar 01, 2011 10:36 am
Hello everyone.
I have a system Gentoo Hardened
Linux kernel 2.6.37
gcc version 4.5.1 (Gentoo Hardened 4.5.1-r1 p1.4, pie-0.4.5)
The whole system works smoothly, without too much trouble except for VirtualBox.
I tried kernels 2.6.36 and 2.6.37, and all
VirtualBox versions - 3.2.* and 4.0 .*
Virtual Machine is started (example Android3, Ubuntu Natty, & others):
but in reality, VM is crashed:
Virtualbox error log:
http://pastebin.com/uhsFvJS7
http://pastebin.com/pdG8PYxn
My current config grsec / pax:
http://pastebin.com/U1kuxPUx
My whole kernel config - current:
http://pastebin.com/wYWF3RDH
My current kernel was created tuxonice-sources-2.6.37 - Gentoo overlay,
patch:
Autogroup: https://lkml.org/lkml/2010/11/30/121
Grsecurity: grsecurity-2.2.1-6.2.1937-201101172105.patch
Layer7, IMQ.
Therefore, the question is:
Do you run VirtualBox Virtual Machine requires some configuration changes,
or is it completely impossible?
Yours
My native language is Polish, sorry for bad English.
EDIT:
Sysctl config:
I have a system Gentoo Hardened
Linux kernel 2.6.37
gcc version 4.5.1 (Gentoo Hardened 4.5.1-r1 p1.4, pie-0.4.5)
The whole system works smoothly, without too much trouble except for VirtualBox.
I tried kernels 2.6.36 and 2.6.37, and all
VirtualBox versions - 3.2.* and 4.0 .*
Virtual Machine is started (example Android3, Ubuntu Natty, & others):
- Code: Select all
VBoxManage startvm Droid3
Oracle VM VirtualBox Command Line Management Interface Version 3.2.12
(C) 2005-2010 Oracle Corporation
All rights reserved.
Waiting for the VM to power on...
VM has been successfully started.
but in reality, VM is crashed:
- Code: Select all
2011-03-01T15:29:52.125435+01:00 localhost -bash: HISTORY: PID=10625 UID=1001 VBoxManage startvm Droid3
2011-03-01T15:29:52.194338+01:00 localhost kernel: [ 970.415378] grsec: denied resource overstep by requesting 31 for RLIMIT_NICE against limit 30 for /opt/VirtualBox/VBoxManage[VBoxManage:10653] uid/euid:1001/1001 gid/egid:1001/1001, parent /bin/bash[bash:10625] uid/euid:1001/1001 gid/egid:1001/1001
2011-03-01T15:29:52.196329+01:00 localhost kernel: [ 970.417251] grsec: denied kernel module auto-load of net-pf-10 by /opt/VirtualBox/VBoxManage[VBoxManage:10641] uid/euid:1001/1001 gid/egid:1001/1001, parent /bin/bash[bash:10625] uid/euid:1001/1001 gid/egid:1001/1001
2011-03-01T15:29:52.209357+01:00 localhost kernel: [ 970.430254] grsec: denied resource overstep by requesting 31 for RLIMIT_NICE against limit 30 for /opt/VirtualBox/VBoxXPCOMIPCD[VBoxXPCOMIPCD:10657] uid/euid:1001/1001 gid/egid:1001/1001, parent /opt/VirtualBox/VBoxManage[VBoxManage:10655] uid/euid:1001/1001 gid/egid:1001/1001
2011-03-01T15:29:52.209376+01:00 localhost kernel: [ 970.430575] grsec: denied kernel module auto-load of net-pf-10 by /opt/VirtualBox/VBoxXPCOMIPCD[VBoxXPCOMIPCD:10656] uid/euid:1001/1001 gid/egid:1001/1001, parent /opt/VirtualBox/VBoxManage[VBoxManage:10655] uid/euid:1001/1001 gid/egid:1001/1001
2011-03-01T15:29:52.229338+01:00 localhost kernel: [ 970.450255] grsec: denied resource overstep by requesting 31 for RLIMIT_NICE against limit 30 for /opt/VirtualBox/VBoxSVC[VBoxSVC:10662] uid/euid:1001/1001 gid/egid:1001/1001, parent /opt/VirtualBox/VBoxManage[VBoxManage:10641] uid/euid:1001/1001 gid/egid:1001/1001
2011-03-01T15:29:52.242351+01:00 localhost kernel: [ 970.463265] grsec: denied resource overstep by requesting 31 for RLIMIT_NICE against limit 30 for /opt/VirtualBox/VBoxSVC[VBoxSVC:10666] uid/euid:1001/1001 gid/egid:1001/1001, parent /sbin/init[init:1] uid/euid:0/0 gid/egid:0/0
2011-03-01T15:29:52.242374+01:00 localhost kernel: [ 970.463737] grsec: denied kernel module auto-load of net-pf-10 by /opt/VirtualBox/VBoxSVC[VBoxSVC:10665] uid/euid:1001/1001 gid/egid:1001/1001, parent /sbin/init[init:1] uid/euid:0/0 gid/egid:0/0
2011-03-01T15:29:52.424341+01:00 localhost kernel: [ 970.645266] grsec: denied resource overstep by requesting 31 for RLIMIT_NICE against limit 30 for /opt/VirtualBox/VBoxTestOGL[VBoxTestOGL:10674] uid/euid:1001/1001 gid/egid:1001/1001, parent /opt/VirtualBox/VBoxSVC[VBoxSVC:10669] uid/euid:1001/1001 gid/egid:1001/1001
2011-03-01T15:29:52.583344+01:00 localhost kernel: [ 970.804265] grsec: denied resource overstep by requesting 31 for RLIMIT_NICE against limit 30 for /opt/VirtualBox/VirtualBox[VirtualBox:10679] uid/euid:1001/1001 gid/egid:1001/1001, parent /opt/VirtualBox/VBoxSVC[VBoxSVC:10669] uid/euid:1001/1001 gid/egid:1001/1001
2011-03-01T15:29:52.759333+01:00 localhost kernel: [ 970.980512] grsec: denied kernel module auto-load of net-pf-10 by /opt/VirtualBox/VirtualBox[VirtualBox:10678] uid/euid:1001/1001 gid/egid:1001/1001, parent /opt/VirtualBox/VBoxSVC[VBoxSVC:10669] uid/euid:1001/1001 gid/egid:1001/1001
2011-03-01T15:29:53.061342+01:00 localhost kernel: [ 971.282322] grsec: denied resource overstep by requesting 31 for RLIMIT_NICE against limit 30 for /opt/VirtualBox/VBoxNetDHCP[VBoxNetDHCP:10692] uid/euid:1001/1001 gid/egid:1001/1001, parent /opt/VirtualBox/VBoxSVC[VBoxSVC:10683] uid/euid:1001/1001 gid/egid:1001/1001
2011-03-01T15:29:53.084347+01:00 localhost kernel: [ 971.305424] device vboxnet0 entered promiscuous mode
2011-03-01T15:30:16.361326+01:00 localhost kernel: [ 994.582076] device vboxnet0 left promiscuous mode
Virtualbox error log:
http://pastebin.com/uhsFvJS7
http://pastebin.com/pdG8PYxn
My current config grsec / pax:
http://pastebin.com/U1kuxPUx
My whole kernel config - current:
http://pastebin.com/wYWF3RDH
My current kernel was created tuxonice-sources-2.6.37 - Gentoo overlay,
patch:
Autogroup: https://lkml.org/lkml/2010/11/30/121
Grsecurity: grsecurity-2.2.1-6.2.1937-201101172105.patch
Layer7, IMQ.
Therefore, the question is:
Do you run VirtualBox Virtual Machine requires some configuration changes,
or is it completely impossible?
Yours
My native language is Polish, sorry for bad English.
EDIT:
Sysctl config:
- Code: Select all
sysctl -a | egrep 'grsec|pax'
kernel.grsecurity.linking_restrictions = 1
kernel.grsecurity.fifo_restrictions = 1
kernel.grsecurity.execve_limiting = 1
kernel.grsecurity.ip_blackhole = 1
kernel.grsecurity.lastack_retries = 4
kernel.grsecurity.exec_logging = 0
kernel.grsecurity.signal_logging = 1
kernel.grsecurity.forkfail_logging = 1
kernel.grsecurity.timechange_logging = 1
kernel.grsecurity.chroot_deny_shmat = 1
kernel.grsecurity.chroot_deny_unix = 1
kernel.grsecurity.chroot_deny_mount = 1
kernel.grsecurity.chroot_deny_fchdir = 1
kernel.grsecurity.chroot_deny_chroot = 1
kernel.grsecurity.chroot_deny_pivot = 1
kernel.grsecurity.chroot_enforce_chdir = 1
kernel.grsecurity.chroot_deny_chmod = 1
kernel.grsecurity.chroot_deny_mknod = 1
kernel.grsecurity.chroot_restrict_nice = 1
kernel.grsecurity.chroot_execlog = 1
kernel.grsecurity.chroot_caps = 1
kernel.grsecurity.chroot_deny_sysctl = 1
kernel.grsecurity.tpe = 1
kernel.grsecurity.tpe_gid = 100
kernel.grsecurity.tpe_invert = 1
kernel.grsecurity.tpe_restrict_all = 0
kernel.grsecurity.socket_all = 1
kernel.grsecurity.socket_all_gid = 6100
kernel.grsecurity.socket_client = 1
kernel.grsecurity.socket_client_gid = 6200
kernel.grsecurity.socket_server = 1
kernel.grsecurity.socket_server_gid = 6300
kernel.grsecurity.audit_group = 1
kernel.grsecurity.audit_gid = 100
kernel.grsecurity.audit_chdir = 0
kernel.grsecurity.audit_mount = 0
kernel.grsecurity.dmesg = 1
kernel.grsecurity.chroot_findtask = 1
kernel.grsecurity.resource_logging = 1
kernel.grsecurity.audit_ptrace = 1
kernel.grsecurity.harden_ptrace = 1
kernel.grsecurity.grsec_lock = 0
kernel.grsecurity.romount_protect = 0
kernel.pax.softmode = 0