blob: b3d7c40aa47d4e66f733978883af86465f700bdc (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
#include "capsicum.h"
#include "capsicum-test.h"
#include <sys/sysctl.h>
// Certain sysctls are permitted in capability mode, but most are not. Test
// for the ones that should be, and try one or two that shouldn't.
TEST(Sysctl, Capability) {
int oid[2] = {CTL_KERN, KERN_OSRELDATE};
int ii;
size_t len = sizeof(ii);
EXPECT_OK(sysctl(oid, 2, &ii, &len, NULL, 0));
}
|