Skip to content

Instantly share code, notes, and snippets.

@tommy-dong
tommy-dong / EndpointSecurityDemo.m
Created September 6, 2024 02:03 — forked from Omar-Ikram/EndpointSecurityDemo.m
A demo of using Apple's EndpointSecurity framework - tested on macOS Monterey 12.2.1 (21D62)
//
// main.m
// EndpointSecurityDemo
//
// Created by Omar Ikram on 17/06/2019 - macOS Catalina 10.15 Beta 1 (19A471t)
// Updated by Omar Ikram on 15/08/2019 - macOS Catalina 10.15 Beta 5 (19A526h)
// Updated by Omar Ikram on 01/12/2019 - macOS Catalina 10.15 (19A583)
// Updated by Omar Ikram on 31/01/2021 - macOS Big Sur 11.1 (20C69)
// Updated by Omar Ikram on 07/05/2021 - macOS Big Sur 11.3.1 (20E241)
// Updated by Omar Ikram on 04/07/2021 - macOS Monterey 12 Beta 2 (21A5268h)
@tommy-dong
tommy-dong / bluetooth-connection.m
Created March 26, 2024 02:54 — forked from dnicolson/bluetooth-connection.m
IOBluetooth code to log when devices are connected and disconnected
// clang -o bluetooth-connection bluetooth-connection.m -framework Foundation -framework IOBluetooth
#import <Foundation/Foundation.h>
#import <IOBluetooth/IOBluetooth.h>
@interface BluetoothConnection : NSObject {
}
@end
@implementation BluetoothConnection
@tommy-dong
tommy-dong / cve_2016_0728.c
Created January 20, 2016 17:18 — forked from jpouellet/cve_2016_0728.c
cve_2016_0728 exploit
/* $ gcc cve_2016_0728.c -o cve_2016_0728 -lkeyutils -Wall */
/* $ ./cve_2016_072 PP_KEY */
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/types.h>
#include <keyutils.h>
#include <unistd.h>
#include <time.h>