Skip to content

Instantly share code, notes, and snippets.

@f1shy-dev
f1shy-dev / best_SAE_trick.md
Last active November 14, 2024 08:32
sneakyf1shy's apple intelligence tutorial

the sneakyf1shy apple intelligence tutorial v2.0

Warning

This is patched as of iOS/iPadOS 18.1 DevBeta 5. If you want to follow this, stay on Beta 4.

This actually downloads the models, and is NOT just new SiriUI. Hence, this process is complex and probably not worth it.

⚠️ Prepare to be disappointed and annoyed, and have your time wasted! ⚠️

  • What does not work: Writing Tools, Memories, Reduce Interruptions, Image Eraser and other tools that are within official Apple Intelligence on supported devices.
@steven-michaud
steven-michaud / ThirdPartyKexts.md
Last active November 11, 2024 21:17
Running Third Party Kernel Extensions on Virtualization Framework macOS Guest VMs

Running Third Party Kernel Extensions on Virtualization Framework macOS Guest VMs

As of macOS 12 (Monterey), Apple's Virtualization framework has nice support for macOS guest virtual machines, but with severe limitations: For example you can't install a macOS guest on Intel Macs, install guests with newer versions of macOS than the host, copy and paste between the host and the guest, or install third party kernel extensions in the guest. As usual for Apple, the functionality they do support is nicely implemented, but they've left out so much that the result is only marginally useful -- at least compared to

@tothi
tothi / ms-msdt.MD
Last active September 29, 2024 08:10
The MS-MSDT 0-day Office RCE Proof-of-Concept Payload Building Process

MS-MSDT 0-day Office RCE

MS Office docx files may contain external OLE Object references as HTML files. There is an HTML sceme "ms-msdt:" which invokes the msdt diagnostic tool, what is capable of executing arbitrary code (specified in parameters).

The result is a terrifying attack vector for getting RCE through opening malicious docx files (without using macros).

Here are the steps to build a Proof-of-Concept docx:

  1. Open Word (used up-to-date 2019 Pro, 16.0.10386.20017), create a dummy document, insert an (OLE) object (as a Bitmap Image), save it in docx.
@infernalheaven
infernalheaven / poc.c
Created September 16, 2021 02:18
macOS 11.5.2/iOS 14.7.1 Kernel Race Condition poc
/*
Written By Pan ZhenPeng(@peterpan980927) of Alibaba Security Pandora Lab
use it on macOS: cc poc.c -o poc while True; do ./poc ; done
*/
#include <errno.h>
#include <signal.h>
#include <fcntl.h>
#include <stdio.h>
#include <stdlib.h>
@saagarjha
saagarjha / library_injector.cpp
Last active October 2, 2024 11:26
Load a library into newly spawned processes (using DYLD_INSERT_LIBRARIES and EndpointSecurity)
// To compile: clang++ -arch x86_64 -arch arm64 -std=c++20 library_injector.cpp -lbsm -lEndpointSecurity -o library_injector,
// then codesign with com.apple.developer.endpoint-security.client and run the
// program as root.
#include <EndpointSecurity/EndpointSecurity.h>
#include <algorithm>
#include <array>
#include <bsm/libbsm.h>
#include <cstddef>
#include <cstdint>
@toonetown
toonetown / symbolicate
Last active September 6, 2024 09:28
A script which will help decode macOS dumps, logs, and panics
#!/bin/bash
###########
# A script which will help to decode crashes, spindumps, and samples
###########
# Helper functions
function do_jq {
_J="$(which jq 2>/dev/null)" || {
echo "You must install jq (brew install jq) to use the script" >&2; return 1;
}; "${_J}" "$@"
@DavidRayner
DavidRayner / wanbo.sh
Last active May 15, 2023 06:32
Wanbo T2 apply custom settings on boot
# Connect to device using adb
adb connect <@IP>
# Start su shell (works out of the box - no need to root device)
adb shell
su
# We need to remount the system file-system in order to modify the start-up script
mount -o remount,rw /system
@pwn0rz
pwn0rz / fprpc.c
Created May 30, 2021 09:12
The MIG from FairplayIOKit to fairplayd
#include <stdio.h>
#include <stdint.h>
#include <stdlib.h>
#include <mach/mach.h>
#include <CommonCrypto/CommonCrypto.h>
#include <ctype.h>
void hexdump(void *ptr, int buflen) {
unsigned char *buf = (unsigned char*)ptr;
int i, j;
@Siguza
Siguza / phoenix.c
Last active September 2, 2024 15:49
Phœnix exploit / iOS 9.3.5
// Bugs by NSO Group / Ian Beer.
// Exploit by Siguza & tihmstar.
// Thanks also to Max Bazaliy.
#include <stdint.h> // uint32_t, uint64_t
#include <stdio.h> // fprintf, stderr
#include <string.h> // memcpy, memset, strncmp
#include <unistd.h> // getpid
#include <mach/mach.h>
#include <stdlib.h>
@bazad
bazad / arm64_sysregs_ios.py
Created July 17, 2020 19:58
Label iOS arm64 system registers in IDA Pro
#
# arm64_sysregs_ios.py
# Brandon Azad
#
# Based on https://github.com/gdelugre/ida-arm-system-highlight by Guillaume Delugre.
#
import idautils
import idc