diff options
| author | Beat Gaetzi <beat@FreeBSD.org> | 2010-01-13 08:03:17 +0000 |
|---|---|---|
| committer | Beat Gaetzi <beat@FreeBSD.org> | 2010-01-13 08:03:17 +0000 |
| commit | 078a3145868546becb1f18ad4ff3f84b346ab7ae (patch) | |
| tree | 4bc52f53b8d0d76da7646866e5ecebe1d952923d /emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-Support-SUPR3HardenedMain.cpp | |
| parent | - Update to 1.4.0 (diff) | |
emulators/virtualbox:
- Remove emulators/virtualbox port. Renamed to emulators/virtualbox-ose
and seperate port for the kernel modules created:
emulators/virtualbox-ose-kmod.
emulators/virtualbox-ose:
- Update to 3.1.2
- Update guest additions to 3.1.2
- Port has been renamed to virtualbox-ose to reflect that we are using
the OSE version. [1]
- Added proper PulseAudio support for FreeBSD [2]
- procfs is not required anymore because vbox uses sysctl(3) now [3]
- Update pkg-message to reflect recent changes
- Add nox's FreeBSD host networking patches that are now also in the
upstream vbox svn (modulo vbox variable naming style adjustments:)
http://lists.freebsd.org/pipermail/freebsd-emulation/2010-January/007260.html
http://www.virtualbox.org/changeset/25698
1. Allow direct tap networking again (for users that need the best
network performance and/or need more complex network setups, like when
they want to use routing instead of bridging to e.g. protect from guests
messing with the lan's arp tables; a tap + routing + proxy arp example
is in the above freebsd-emulation posting.)
2. Enable vbox' shared mac feature when using bridged mode on a wifi
interface, together with the virtualbox-ose-kmod change this
should fix bridged mode for wifi users. [4]
emulators/virtualbox-ose-kmod:
- Update to 3.1.2
- Add rc.d script to load kernel modules
- Fix build with a non-standard location for the system source [5]
- Merge aeichner's vboxnetflt fix committed to upstream vbox svn
(thanks!) that makes the shared mac feature enabled above actually work
on FreeBSD hosts. [6]
Please see http://wiki.freebsd.org/VirtualBox for update instructions.
Many thanks to the VirtualBox developers, all tester, patch submitter and
the whole vbox@ team.
PR: ports/141630 [2]
Noticed by: mm@ [1]
Submitted by: Noriyoshi Kawano <bowie AT nrik.jp> [2],
Baptiste Daroussin <baptiste.daroussin AT gmail.com> [3]
and Bernhard Froehlich <decke AT bluelife.at> [3],
nox@ [4], scf@ [5]
Obtained from: http://www.virtualbox.org/changeset/25699 [6]
On behalf of: vbox@ (decke, dhn, itetcu, miwi, nox)
Diffstat (limited to 'emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-Support-SUPR3HardenedMain.cpp')
| -rw-r--r-- | emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-Support-SUPR3HardenedMain.cpp | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-Support-SUPR3HardenedMain.cpp b/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-Support-SUPR3HardenedMain.cpp new file mode 100644 index 000000000000..4a89fec97dfa --- /dev/null +++ b/emulators/virtualbox-ose/files/patch-src-VBox-HostDrivers-Support-SUPR3HardenedMain.cpp @@ -0,0 +1,33 @@ +--- src/VBox/HostDrivers/Support/SUPR3HardenedMain.cpp (revision 25471) ++++ src/VBox/HostDrivers/Support/SUPR3HardenedMain.cpp (revision 25472) +@@ -66,6 +66,9 @@ + # ifndef CAP_TO_MASK + # define CAP_TO_MASK(cap) RT_BIT(cap) + # endif ++# elif defined(RT_OS_FREEBSD) ++# include <sys/param.h> ++# include <sys/sysctl.h> + # elif defined(RT_OS_SOLARIS) + # include <priv.h> + # endif +@@ -325,7 +328,19 @@ + sprintf(szFileBuf, "/proc/%ld/path/a.out", (long)getpid()); + int cchLink = readlink(szFileBuf, &g_szSupLibHardenedExePath[0], sizeof(g_szSupLibHardenedExePath) - 1); + # else /* RT_OS_FREEBSD: */ +- int cchLink = readlink("/proc/curproc/file", &g_szSupLibHardenedExePath[0], sizeof(g_szSupLibHardenedExePath) - 1); ++ int aiName[4]; ++ size_t cbPath; ++ ++ aiName[0] = CTL_KERN; ++ aiName[1] = KERN_PROC; ++ aiName[2] = KERN_PROC_PATHNAME; ++ aiName[3] = getpid(); ++ ++ cbPath = sizeof(g_szSupLibHardenedExePath) - 1; ++ if(sysctl(aiName, RT_ELEMENTS(aiName), g_szSupLibHardenedExePath, &cbPath, NULL, 0) < 0) ++ supR3HardenedFatal("supR3HardenedExecDir: sysctl failed\n"); ++ ++ int cchLink = strlen(g_szSupLibHardenedExePath); + # endif + if (cchLink < 0 || cchLink == sizeof(g_szSupLibHardenedExePath) - 1) + supR3HardenedFatal("supR3HardenedExecDir: couldn't read \"%s\", errno=%d cchLink=%d\n", |
