diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 3e83be98c..19bb2a4ba 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -161,6 +161,9 @@ include_directories(AFTER
${CMAKE_CURRENT_SOURCE_DIR}/CrashReporterSupport/include
${CMAKE_CURRENT_SOURCE_DIR}/SecurityFoundation/include
${CMAKE_CURRENT_SOURCE_DIR}/AuthKit/include
+ ${CMAKE_CURRENT_SOURCE_DIR}/IOPlatformPluginFamily/include
+ ${CMAKE_CURRENT_SOURCE_DIR}/PlugInKit/include
+ ${CMAKE_CURRENT_SOURCE_DIR}/libsysmon/include
${CMAKE_CURRENT_SOURCE_DIR}/lkm/include
)
@@ -311,6 +314,9 @@ add_subdirectory(LoggingSupport)
add_subdirectory(CrashReporterSupport)
add_subdirectory(SecurityFoundation)
add_subdirectory(AuthKit)
+add_subdirectory(IOPlatformPluginFamily)
+add_subdirectory(PlugInKit)
+add_subdirectory(libsysmon)
add_subdirectory(external/bsm)
add_subdirectory(external/gdb)
add_subdirectory(external/Heimdal)
diff --git a/src/IOPlatformPluginFamily/CMakeLists.txt b/src/IOPlatformPluginFamily/CMakeLists.txt
new file mode 100644
index 000000000..2efca7a8e
--- /dev/null
+++ b/src/IOPlatformPluginFamily/CMakeLists.txt
@@ -0,0 +1,19 @@
+project(IOPlatformPluginFamily)
+
+set(DYLIB_COMPAT_VERSION "1.0.0")
+set(DYLIB_CURRENT_VERSION "1.0.0")
+
+file(GLOB PPF_C src/*.c)
+
+add_framework(IOPlatformPluginFamily
+ FAT
+ CURRENT_VERSION
+ PRIVATE
+ VERSION "A"
+
+ SOURCES
+ ${PPF_C}
+
+ DEPENDENCIES
+ system
+)
diff --git a/src/IOPlatformPluginFamily/include/IOPlatformPluginFamily/IOPlatformPluginFamily.h b/src/IOPlatformPluginFamily/include/IOPlatformPluginFamily/IOPlatformPluginFamily.h
new file mode 100755
index 000000000..5106c8500
--- /dev/null
+++ b/src/IOPlatformPluginFamily/include/IOPlatformPluginFamily/IOPlatformPluginFamily.h
@@ -0,0 +1,28 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+void* IOPPFGetDiagProperty(void);
+void* IOPPFGetDiagPropertyFromDict(void);
+void* IOPPFGetHandler(void);
+void* IOPPFGetProperty(void);
+void* IOPPFPrintTest(void);
+void* IOPPFSetFanThrottleMode(void);
+void* IOPPFSetProperties(void);
diff --git a/src/IOPlatformPluginFamily/src/functions.c b/src/IOPlatformPluginFamily/src/functions.c
new file mode 100755
index 000000000..2a86d7ce2
--- /dev/null
+++ b/src/IOPlatformPluginFamily/src/functions.c
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+
+#include
+static int verbose = 0;
+__attribute__((constructor)) static void initme(void) {
+ verbose = getenv("STUB_VERBOSE") != NULL;
+}
+void* IOPPFGetDiagProperty(void) { if (verbose) puts("STUB: IOPPFGetDiagProperty called"); return NULL; }
+void* IOPPFGetDiagPropertyFromDict(void) { if (verbose) puts("STUB: IOPPFGetDiagPropertyFromDict called"); return NULL; }
+void* IOPPFGetHandler(void) { if (verbose) puts("STUB: IOPPFGetHandler called"); return NULL; }
+void* IOPPFGetProperty(void) { if (verbose) puts("STUB: IOPPFGetProperty called"); return NULL; }
+void* IOPPFPrintTest(void) { if (verbose) puts("STUB: IOPPFPrintTest called"); return NULL; }
+void* IOPPFSetFanThrottleMode(void) { if (verbose) puts("STUB: IOPPFSetFanThrottleMode called"); return NULL; }
+void* IOPPFSetProperties(void) { if (verbose) puts("STUB: IOPPFSetProperties called"); return NULL; }
diff --git a/src/PlugInKit/CMakeLists.txt b/src/PlugInKit/CMakeLists.txt
new file mode 100644
index 000000000..eaac64b28
--- /dev/null
+++ b/src/PlugInKit/CMakeLists.txt
@@ -0,0 +1,23 @@
+project(PlugInKit)
+
+set(DYLIB_COMPAT_VERSION "1.0.0")
+set(DYLIB_CURRENT_VERSION "1.0.0")
+
+file(GLOB PK_C src/*.c)
+file(GLOB PK_OBJC src/*.m)
+
+add_framework(PlugInKit
+ FAT
+ CURRENT_VERSION
+ PRIVATE
+ VERSION "A"
+
+ SOURCES
+ ${PK_C}
+ ${PK_OBJC}
+
+ DEPENDENCIES
+ system
+ objc
+ Foundation
+)
diff --git a/src/PlugInKit/include/PlugInKit/PKBundle.h b/src/PlugInKit/include/PlugInKit/PKBundle.h
new file mode 100755
index 000000000..678a2238f
--- /dev/null
+++ b/src/PlugInKit/include/PlugInKit/PKBundle.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface PKBundle : NSObject
+
+@end
diff --git a/src/PlugInKit/include/PlugInKit/PKDaemonClient.h b/src/PlugInKit/include/PlugInKit/PKDaemonClient.h
new file mode 100755
index 000000000..05f546c76
--- /dev/null
+++ b/src/PlugInKit/include/PlugInKit/PKDaemonClient.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface PKDaemonClient : NSObject
+
+@end
diff --git a/src/PlugInKit/include/PlugInKit/PKDiscoveryDriver.h b/src/PlugInKit/include/PlugInKit/PKDiscoveryDriver.h
new file mode 100755
index 000000000..ad7f62643
--- /dev/null
+++ b/src/PlugInKit/include/PlugInKit/PKDiscoveryDriver.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface PKDiscoveryDriver : NSObject
+
+@end
diff --git a/src/PlugInKit/include/PlugInKit/PKDiscoveryLSWatcher.h b/src/PlugInKit/include/PlugInKit/PKDiscoveryLSWatcher.h
new file mode 100755
index 000000000..677687be3
--- /dev/null
+++ b/src/PlugInKit/include/PlugInKit/PKDiscoveryLSWatcher.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface PKDiscoveryLSWatcher : NSObject
+
+@end
diff --git a/src/PlugInKit/include/PlugInKit/PKHost.h b/src/PlugInKit/include/PlugInKit/PKHost.h
new file mode 100755
index 000000000..aa97503ba
--- /dev/null
+++ b/src/PlugInKit/include/PlugInKit/PKHost.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface PKHost : NSObject
+
+@end
diff --git a/src/PlugInKit/include/PlugInKit/PKHostDefaults.h b/src/PlugInKit/include/PlugInKit/PKHostDefaults.h
new file mode 100755
index 000000000..c8b8aa872
--- /dev/null
+++ b/src/PlugInKit/include/PlugInKit/PKHostDefaults.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface PKHostDefaults : NSUserDefaults
+
+@end
diff --git a/src/PlugInKit/include/PlugInKit/PKHostPlugIn.h b/src/PlugInKit/include/PlugInKit/PKHostPlugIn.h
new file mode 100755
index 000000000..8ed760e21
--- /dev/null
+++ b/src/PlugInKit/include/PlugInKit/PKHostPlugIn.h
@@ -0,0 +1,24 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@interface PKHostPlugIn : PKPlugInCore
+
+@end
diff --git a/src/PlugInKit/include/PlugInKit/PKManager.h b/src/PlugInKit/include/PlugInKit/PKManager.h
new file mode 100755
index 000000000..8cd32ef57
--- /dev/null
+++ b/src/PlugInKit/include/PlugInKit/PKManager.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface PKManager : NSObject
+
+@end
diff --git a/src/PlugInKit/include/PlugInKit/PKPlugInCore.h b/src/PlugInKit/include/PlugInKit/PKPlugInCore.h
new file mode 100755
index 000000000..0e3578552
--- /dev/null
+++ b/src/PlugInKit/include/PlugInKit/PKPlugInCore.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface PKPlugInCore : NSObject
+
+@end
diff --git a/src/PlugInKit/include/PlugInKit/PKSandboxExtension.h b/src/PlugInKit/include/PlugInKit/PKSandboxExtension.h
new file mode 100755
index 000000000..947b26a98
--- /dev/null
+++ b/src/PlugInKit/include/PlugInKit/PKSandboxExtension.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface PKSandboxExtension : NSObject
+
+@end
diff --git a/src/PlugInKit/include/PlugInKit/PKService.h b/src/PlugInKit/include/PlugInKit/PKService.h
new file mode 100755
index 000000000..925069521
--- /dev/null
+++ b/src/PlugInKit/include/PlugInKit/PKService.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface PKService : NSObject
+
+@end
diff --git a/src/PlugInKit/include/PlugInKit/PKServiceDefaults.h b/src/PlugInKit/include/PlugInKit/PKServiceDefaults.h
new file mode 100755
index 000000000..923fd2f21
--- /dev/null
+++ b/src/PlugInKit/include/PlugInKit/PKServiceDefaults.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface PKServiceDefaults : NSUserDefaults
+
+@end
diff --git a/src/PlugInKit/include/PlugInKit/PKServicePersonality.h b/src/PlugInKit/include/PlugInKit/PKServicePersonality.h
new file mode 100755
index 000000000..82b6a4029
--- /dev/null
+++ b/src/PlugInKit/include/PlugInKit/PKServicePersonality.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface PKServicePersonality : PKPlugInCore
+
+@end
diff --git a/src/PlugInKit/include/PlugInKit/PKXPCObject.h b/src/PlugInKit/include/PlugInKit/PKXPCObject.h
new file mode 100755
index 000000000..4727d4be0
--- /dev/null
+++ b/src/PlugInKit/include/PlugInKit/PKXPCObject.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface PKXPCObject : NSObject
+
+@end
diff --git a/src/PlugInKit/include/PlugInKit/PlugInKit.h b/src/PlugInKit/include/PlugInKit/PlugInKit.h
new file mode 100755
index 000000000..8b07b255c
--- /dev/null
+++ b/src/PlugInKit/include/PlugInKit/PlugInKit.h
@@ -0,0 +1,48 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+void* oslog(void);
+void* oslog_ext(void);
+void* oslog_ls(void);
+void* oslog_traffic(void);
+void* pkAugmentInterface(void);
+void* pkError(void);
+void* pkErrorf(void);
+void* pkFindProtocol(void);
+void* pkFindProtocols(void);
+void* pkIssueSandboxExtension(void);
+void* xpc_dictionary_get_array(void);
+void* xpc_dictionary_get_dictionary(void);
+
+#import
+#import
+#import
+#import
+#import
+#import
+#import
+#import
+#import
+#import
+#import
+#import
+#import
+#import
diff --git a/src/PlugInKit/src/PKBundle.m b/src/PlugInKit/src/PKBundle.m
new file mode 100755
index 000000000..fade95c20
--- /dev/null
+++ b/src/PlugInKit/src/PKBundle.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation PKBundle
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/PlugInKit/src/PKDaemonClient.m b/src/PlugInKit/src/PKDaemonClient.m
new file mode 100755
index 000000000..73b6875f0
--- /dev/null
+++ b/src/PlugInKit/src/PKDaemonClient.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation PKDaemonClient
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/PlugInKit/src/PKDiscoveryDriver.m b/src/PlugInKit/src/PKDiscoveryDriver.m
new file mode 100755
index 000000000..922121e9b
--- /dev/null
+++ b/src/PlugInKit/src/PKDiscoveryDriver.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation PKDiscoveryDriver
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/PlugInKit/src/PKDiscoveryLSWatcher.m b/src/PlugInKit/src/PKDiscoveryLSWatcher.m
new file mode 100755
index 000000000..3c374c3d4
--- /dev/null
+++ b/src/PlugInKit/src/PKDiscoveryLSWatcher.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation PKDiscoveryLSWatcher
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/PlugInKit/src/PKHost.m b/src/PlugInKit/src/PKHost.m
new file mode 100755
index 000000000..8be29ef7a
--- /dev/null
+++ b/src/PlugInKit/src/PKHost.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation PKHost
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/PlugInKit/src/PKHostDefaults.m b/src/PlugInKit/src/PKHostDefaults.m
new file mode 100755
index 000000000..7862fe97a
--- /dev/null
+++ b/src/PlugInKit/src/PKHostDefaults.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation PKHostDefaults
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/PlugInKit/src/PKHostPlugIn.m b/src/PlugInKit/src/PKHostPlugIn.m
new file mode 100755
index 000000000..799bfe447
--- /dev/null
+++ b/src/PlugInKit/src/PKHostPlugIn.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation PKHostPlugIn
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/PlugInKit/src/PKManager.m b/src/PlugInKit/src/PKManager.m
new file mode 100755
index 000000000..c4be14ec6
--- /dev/null
+++ b/src/PlugInKit/src/PKManager.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation PKManager
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/PlugInKit/src/PKPlugInCore.m b/src/PlugInKit/src/PKPlugInCore.m
new file mode 100755
index 000000000..e74220cc6
--- /dev/null
+++ b/src/PlugInKit/src/PKPlugInCore.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation PKPlugInCore
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/PlugInKit/src/PKSandboxExtension.m b/src/PlugInKit/src/PKSandboxExtension.m
new file mode 100755
index 000000000..4f4eb0b0f
--- /dev/null
+++ b/src/PlugInKit/src/PKSandboxExtension.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation PKSandboxExtension
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/PlugInKit/src/PKService.m b/src/PlugInKit/src/PKService.m
new file mode 100755
index 000000000..da2c29987
--- /dev/null
+++ b/src/PlugInKit/src/PKService.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation PKService
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/PlugInKit/src/PKServiceDefaults.m b/src/PlugInKit/src/PKServiceDefaults.m
new file mode 100755
index 000000000..6ed9f095a
--- /dev/null
+++ b/src/PlugInKit/src/PKServiceDefaults.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation PKServiceDefaults
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/PlugInKit/src/PKServicePersonality.m b/src/PlugInKit/src/PKServicePersonality.m
new file mode 100755
index 000000000..3f712478a
--- /dev/null
+++ b/src/PlugInKit/src/PKServicePersonality.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation PKServicePersonality
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/PlugInKit/src/PKXPCObject.m b/src/PlugInKit/src/PKXPCObject.m
new file mode 100755
index 000000000..3255d4d23
--- /dev/null
+++ b/src/PlugInKit/src/PKXPCObject.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation PKXPCObject
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/PlugInKit/src/functions.c b/src/PlugInKit/src/functions.c
new file mode 100755
index 000000000..2a77568e4
--- /dev/null
+++ b/src/PlugInKit/src/functions.c
@@ -0,0 +1,37 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+
+#include
+static int verbose = 0;
+__attribute__((constructor)) static void initme(void) {
+ verbose = getenv("STUB_VERBOSE") != NULL;
+}
+void* oslog(void) { if (verbose) puts("STUB: oslog called"); return NULL; }
+void* oslog_ext(void) { if (verbose) puts("STUB: oslog_ext called"); return NULL; }
+void* oslog_ls(void) { if (verbose) puts("STUB: oslog_ls called"); return NULL; }
+void* oslog_traffic(void) { if (verbose) puts("STUB: oslog_traffic called"); return NULL; }
+void* pkAugmentInterface(void) { if (verbose) puts("STUB: pkAugmentInterface called"); return NULL; }
+void* pkError(void) { if (verbose) puts("STUB: pkError called"); return NULL; }
+void* pkErrorf(void) { if (verbose) puts("STUB: pkErrorf called"); return NULL; }
+void* pkFindProtocol(void) { if (verbose) puts("STUB: pkFindProtocol called"); return NULL; }
+void* pkFindProtocols(void) { if (verbose) puts("STUB: pkFindProtocols called"); return NULL; }
+void* pkIssueSandboxExtension(void) { if (verbose) puts("STUB: pkIssueSandboxExtension called"); return NULL; }
+void* xpc_dictionary_get_array(void) { if (verbose) puts("STUB: xpc_dictionary_get_array called"); return NULL; }
+void* xpc_dictionary_get_dictionary(void) { if (verbose) puts("STUB: xpc_dictionary_get_dictionary called"); return NULL; }
diff --git a/src/libsysmon/CMakeLists.txt b/src/libsysmon/CMakeLists.txt
new file mode 100644
index 000000000..18021e2d1
--- /dev/null
+++ b/src/libsysmon/CMakeLists.txt
@@ -0,0 +1,16 @@
+project(sysmon)
+
+set(DYLIB_INSTALL_NAME "/usr/lib/libsysmon.dylib")
+set(DYLIB_COMPAT_VERSION "1.0.0")
+set(DYLIB_CURRENT_VERSION "1.0.0")
+
+file(GLOB sysmon_objc "src/*.m")
+
+add_darling_library(sysmon
+ src/sysmon.c
+ ${sysmon_objc}
+)
+make_fat(sysmon)
+target_link_libraries(sysmon system objc Foundation)
+
+install(TARGETS sysmon DESTINATION libexec/darling/usr/lib)
diff --git a/src/libsysmon/include/sysmon/OS_sysmon_object.h b/src/libsysmon/include/sysmon/OS_sysmon_object.h
new file mode 100755
index 000000000..38e1d99dd
--- /dev/null
+++ b/src/libsysmon/include/sysmon/OS_sysmon_object.h
@@ -0,0 +1,26 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface OS_object
+
+@end
+
+@interface OS_sysmon_object : OS_object
+
+@end
diff --git a/src/libsysmon/include/sysmon/OS_sysmon_request.h b/src/libsysmon/include/sysmon/OS_sysmon_request.h
new file mode 100755
index 000000000..6c7a5ff38
--- /dev/null
+++ b/src/libsysmon/include/sysmon/OS_sysmon_request.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface OS_sysmon_request : OS_sysmon_object
+
+@end
diff --git a/src/libsysmon/include/sysmon/OS_sysmon_row.h b/src/libsysmon/include/sysmon/OS_sysmon_row.h
new file mode 100755
index 000000000..786acce2c
--- /dev/null
+++ b/src/libsysmon/include/sysmon/OS_sysmon_row.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface OS_sysmon_row : OS_sysmon_object
+
+@end
diff --git a/src/libsysmon/include/sysmon/OS_sysmon_table.h b/src/libsysmon/include/sysmon/OS_sysmon_table.h
new file mode 100755
index 000000000..b516698db
--- /dev/null
+++ b/src/libsysmon/include/sysmon/OS_sysmon_table.h
@@ -0,0 +1,22 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+@interface OS_sysmon_table : OS_sysmon_object
+
+@end
diff --git a/src/libsysmon/include/sysmon/sysmon.h b/src/libsysmon/include/sysmon/sysmon.h
new file mode 100755
index 000000000..2fca9cbd5
--- /dev/null
+++ b/src/libsysmon/include/sysmon/sysmon.h
@@ -0,0 +1,46 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+void* sysmon_copy_process_info(void);
+void* sysmon_release(void);
+void* sysmon_request_add_attribute(void);
+void* sysmon_request_add_attributes(void);
+void* sysmon_request_alloc(void);
+void* sysmon_request_cancel(void);
+void* sysmon_request_create(void);
+void* sysmon_request_execute(void);
+void* sysmon_request_set_flags(void);
+void* sysmon_request_set_interval(void);
+void* sysmon_retain(void);
+void* sysmon_row_alloc(void);
+void* sysmon_row_apply(void);
+void* sysmon_row_get_value(void);
+void* sysmon_table_alloc(void);
+void* sysmon_table_apply(void);
+void* sysmon_table_copy_row(void);
+void* sysmon_table_get_count(void);
+void* sysmon_table_get_row(void);
+void* sysmon_table_get_timestamp(void);
+
+#import
+#import
+#import
+#import
diff --git a/src/libsysmon/src/OS_sysmon_object.m b/src/libsysmon/src/OS_sysmon_object.m
new file mode 100755
index 000000000..0ba9be664
--- /dev/null
+++ b/src/libsysmon/src/OS_sysmon_object.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation OS_sysmon_object
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/libsysmon/src/OS_sysmon_request.m b/src/libsysmon/src/OS_sysmon_request.m
new file mode 100755
index 000000000..691271e21
--- /dev/null
+++ b/src/libsysmon/src/OS_sysmon_request.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation OS_sysmon_request
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/libsysmon/src/OS_sysmon_row.m b/src/libsysmon/src/OS_sysmon_row.m
new file mode 100755
index 000000000..d57562bae
--- /dev/null
+++ b/src/libsysmon/src/OS_sysmon_row.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation OS_sysmon_row
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/libsysmon/src/OS_sysmon_table.m b/src/libsysmon/src/OS_sysmon_table.m
new file mode 100755
index 000000000..660153a0f
--- /dev/null
+++ b/src/libsysmon/src/OS_sysmon_table.m
@@ -0,0 +1,32 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+#import
+
+@implementation OS_sysmon_table
+
+- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector {
+ return [NSMethodSignature signatureWithObjCTypes: "v@:"];
+}
+
+- (void)forwardInvocation:(NSInvocation *)anInvocation {
+ NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
+}
+
+@end
diff --git a/src/libsysmon/src/sysmon.c b/src/libsysmon/src/sysmon.c
new file mode 100755
index 000000000..5d4cb0c9f
--- /dev/null
+++ b/src/libsysmon/src/sysmon.c
@@ -0,0 +1,45 @@
+/*
+This file is part of Darling.
+
+Copyright (C) 2017 Lubos Dolezel
+
+Darling is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+Darling is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Darling. If not, see .
+*/
+
+
+#include
+static int verbose = 0;
+__attribute__((constructor)) static void initme(void) {
+ verbose = getenv("STUB_VERBOSE") != NULL;
+}
+void* sysmon_copy_process_info(void) { if (verbose) puts("STUB: sysmon_copy_process_info called"); return NULL; }
+void* sysmon_release(void) { if (verbose) puts("STUB: sysmon_release called"); return NULL; }
+void* sysmon_request_add_attribute(void) { if (verbose) puts("STUB: sysmon_request_add_attribute called"); return NULL; }
+void* sysmon_request_add_attributes(void) { if (verbose) puts("STUB: sysmon_request_add_attributes called"); return NULL; }
+void* sysmon_request_alloc(void) { if (verbose) puts("STUB: sysmon_request_alloc called"); return NULL; }
+void* sysmon_request_cancel(void) { if (verbose) puts("STUB: sysmon_request_cancel called"); return NULL; }
+void* sysmon_request_create(void) { if (verbose) puts("STUB: sysmon_request_create called"); return NULL; }
+void* sysmon_request_execute(void) { if (verbose) puts("STUB: sysmon_request_execute called"); return NULL; }
+void* sysmon_request_set_flags(void) { if (verbose) puts("STUB: sysmon_request_set_flags called"); return NULL; }
+void* sysmon_request_set_interval(void) { if (verbose) puts("STUB: sysmon_request_set_interval called"); return NULL; }
+void* sysmon_retain(void) { if (verbose) puts("STUB: sysmon_retain called"); return NULL; }
+void* sysmon_row_alloc(void) { if (verbose) puts("STUB: sysmon_row_alloc called"); return NULL; }
+void* sysmon_row_apply(void) { if (verbose) puts("STUB: sysmon_row_apply called"); return NULL; }
+void* sysmon_row_get_value(void) { if (verbose) puts("STUB: sysmon_row_get_value called"); return NULL; }
+void* sysmon_table_alloc(void) { if (verbose) puts("STUB: sysmon_table_alloc called"); return NULL; }
+void* sysmon_table_apply(void) { if (verbose) puts("STUB: sysmon_table_apply called"); return NULL; }
+void* sysmon_table_copy_row(void) { if (verbose) puts("STUB: sysmon_table_copy_row called"); return NULL; }
+void* sysmon_table_get_count(void) { if (verbose) puts("STUB: sysmon_table_get_count called"); return NULL; }
+void* sysmon_table_get_row(void) { if (verbose) puts("STUB: sysmon_table_get_row called"); return NULL; }
+void* sysmon_table_get_timestamp(void) { if (verbose) puts("STUB: sysmon_table_get_timestamp called"); return NULL; }