Skip to content

Instantly share code, notes, and snippets.

View Maximus-'s full-sized avatar
😣

Max Maximus-

😣
View GitHub Profile
@Jinmo
Jinmo / _.md
Last active May 28, 2024 15:08
C/C++ header to IDA

Usage

In IDAPython,

execfile('<path>/cxxparser.py')
parse_file('<path>/a.cpp',[r'-I<path>\LuaJIT-2.0.5\src', '-D__NT__', '-D__X64__', '-D__EA64__'])
parse_file('<path>/malloc.c',['-target=x86_64-linux-gnu'])
@drvink
drvink / cornbread.md
Created December 15, 2018 23:46
best cornbread recipe

The cornbread recipe is easy; it's right off the Alber's Yellow Cornmeal box.

  • 1 cup Alber's yellow cornmeal
  • 1 cup all purpose flour
  • 1/4 cup granulated sugar
  • 1 Tbs. baking powder (Not soda)
  • 1 tsp. salt
  • 1 cup milk
  • 1/3 cup vegetable oil (like canola)
  • 1 large egg, slightly beaten
@kernelsmith
kernelsmith / key_peele_east_west_names.rb
Created April 13, 2018 20:28
All the names, teams, schools, and East-West episode numbers for Key & Peele's East vs West skits...in ruby
names = [
["D'Marcus Williums", "1", "east", "University of Georgia"],
["T.J. Juckson", "1", "east", "Wayne State University"],
["T'varisuness King", "1", "east", "Merrimack College"],
["Tyroil Smoochie-Wallace", "1", "east", "University of Miami"],
["D'Squarius Green, Jr.", "east", "University of Notre Dame"],
["Ibrahim Moizoos", "1", "east", "University of Tennessee at Chatanooga"],
["Jackmerius Tacktheritrix", "1", "east", "Michigan State University"],
["D'Isiah T. Billings-Clyde", "1", "east", "Coastal Carolina University"],
["D'Jasper Probincrux III", "1", "east", "South Carolina State University"],
@spq
spq / nope.py
Created January 1, 2018 16:18
34c3ctf exploits
#!/usr/bin/env python2
import socket
import struct
import telnetlib
import os, sys, time
HOST, PORT = "35.198.126.67", 4444
p32 = lambda v: struct.pack("<I", v)
p64 = lambda v: struct.pack("<Q", v)

Setting up netboot.xyz with an EdgeRouter

This document covers how to setup netboot.xyz, a service that provides iPXE-based installation and live boot of a bunch of operating systems, on a Ubiquiti EdgeRouter.

Assumptions

I've made a few assumptions throughout this document that will probably be different for your setup:

@itszn
itszn / subleq.py
Created October 16, 2017 04:24
Binary Ninja subleq plugin
from binaryninja import (Architecture, RegisterInfo, InstructionInfo,
InstructionTextToken, InstructionTextTokenType, InstructionTextTokenContext,
BranchType,
LowLevelILOperation, LLIL_TEMP,
LowLevelILLabel,
FlagRole,
LowLevelILFlagCondition,
log_error,
CallingConvention,
interaction,
As of iOS 11/macOS High Sierra, and only including ones in Foundation and CoreFoundation
Strings:
_NSCFString - a CFStringRef or CFMutableStringRef. This is the most common type of string object currently.
- May have 8 bit (ASCII) or 16 bit (UTF-16) backing store
_NSCFConstantString - a compile time constant CFStringRef, like you'd get with @"foo"
- May also be generated by dynamic string creation if matches a string in a pre-baked table of common strings called the StringROM
NSBigMutableString - an NSString backed by a CFStorage (https://github.com/opensource-apple/CF/blob/master/CFStorage.h) for faster handling of very large strings
NSCheapMutableString - a very limited NSMutableString that allows for zero-copy initialization. Used in NSFileManager for temporarily wrapping stack buffers.
@hellman
hellman / rsa_timing_attack_d_Montgomery.py
Created May 1, 2017 12:23
DEF CON 2017 Quals - Godzilla (Reverse/Crypto)
#-*- coding:utf-8 -*-
'''
DEF CON 2017 Quals - Godzilla (Reverse)
Timing attack on RSA decryption.
Based on http://www.cs.jhu.edu/~fabian/courses/CS600.624/Timing-full.pdf
Another solutions:
https://gist.github.com/nneonneo/367240ae2d8e705bb9173a49a7c8b0cd by b2xiao
https://gist.github.com/Riatre/caac24840b176cf843b3f66ad9a5eeaf by riatre
@ChiChou
ChiChou / iOS-checksec.py
Last active March 8, 2023 02:30
checksec for iOS executables based on lief
#!/usr/bin/env python3
import struct
import lief
from lief.MachO import LOAD_COMMAND_TYPES, HEADER_FLAGS
def check(filename):
macho = lief.parse(filename)
# check this?