Skip to content

Instantly share code, notes, and snippets.

View JRHeaton's full-sized avatar

John Heaton JRHeaton

View GitHub Profile
John-Heatons-MacBook-Pro:Desktop John$ ibootutil -s
=======================================
::
:: iBEC for n72ap, Copyright 2009, Apple Inc.
::
:: BUILD_TAG: iBoot-636.66.33
::
:: BUILD_STYLE: RELEASE
// Gojohnnyboi
// iPod touch 2G -- 4.0b3 Keys/IVs
Restore Ramdisk(018-7663-006.dmg):
IV: f1b516f9fb2ed5e79b458fdb639857c4
Key: eece7085c092a32e827e45ddc7510222
kernelcache.release.n72:
IV: 95b007d09b26a1dfc9082b8d66f50cda
Key: 32304bbd2043b78f214fbdd99bf77e71
#include <IOKit/IOKitLib.h>
#include <CoreFoundation/CoreFoundation.h>
#include <sys/signal.h>
void iCleanup(int sig) {
printf("Closing...\n");
exit(0);
}
void iDetached(void *refcon, io_iterator_t iterator) {
#include <IOKit/IOKitLib.h>
#include <CoreFoundation/CoreFoundation.h>
#include <sys/signal.h>
IONotificationPortRef nPort = NULL;
void iCleanup(int sig) {
printf("Closing...\n");
exit(0);
}
#include <recovery.h>
int main(int argc, const char **argv) {
if(argc < 3) {
printf("Usage: %s <ramdisk> <kernel>\n", argv[0]);
return -1;
}
printf("Connecting to device...");
iUSBRecoveryDeviceRef device = iUSBRecoveryDeviceCreate(kUSBPIDRecovery, NULL);
#include <IOKit/IOKitLib.h>
#include <stdint.h>
#include <sys/signal.h>
IONotificationPortRef muxNotifyPort = NULL;
io_object_t muxNotification = NULL;
void interupt(int signal) {
printf("Interupted\n");
IONotificationPortDestroy(muxNotifyPort);
#include <sys/mman.h>
#include <stdio.h>
#include <fcntl.h>
#include <stdint.h>
#include <sys/stat.h>
#define IV_SIZE 0x10
#define KEY_SIZE 0x10
int data_is_img3(void *mem) {
#include <stdio.h>
#include <stdint.h>
#include <fcntl.h>
#include <stdlib.h>
#include <string.h>
#include <sys/mman.h>
#include <sys/stat.h>
#define IMG3_MAGIC 0x496D6733
@JRHeaton
JRHeaton / lszip.c
Created May 17, 2011 23:13
List files in a zip archive
#include <stdio.h>
#include <stdint.h>
#include <sys/mman.h>
#include <fcntl.h>
#include <string.h>
#include <unistd.h>
#include <sys/stat.h>
int main(int argc, const char *argv[]) {
struct stat st;
//
// AMDevice.m
// Can I Jailbreak?
//
// Created by John Heaton on 10/1/11.
// Copyright 2011 GJB Software. All rights reserved.
//
#import "AMDevice.h"