Skip to content

Instantly share code, notes, and snippets.

View numinit's full-sized avatar

Morgan numinit

View GitHub Profile
#!/usr/bin/env ruby
# usage: $0 <badge ID, in hex or decimal> (this is the number on the Call Jenny screen)
# keygen by numinit
# gr33tz dc858; Distractions, Inc
# NixOS rules
raise ArgumentError, <<EOF if ARGV.empty?
usage: #$0 <badge ID, in hex or decimal> (this is the number on the Call Jenny screen)
Note that you have to enter the following on the Play screen first:
@numinit
numinit / 0-index.md
Last active April 6, 2024 21:54
patch -p0 < fix-vega-reset.patch
@numinit
numinit / example-output.txt
Last active July 9, 2019 17:13
Point this script at a subfolder in your PUBG demos directory. Doesn't get all events (there are more in the UE4 checkpoint files), but will print some interesting stats about your match.
# ruby pubg-summarize.rb /mnt/c/Users/numinit/AppData/Local/TslGame/Saved/Demos/match.bro.official.2017-pre6.na.squad-fpp.2017.12.16.8585b819-02de-428e-bf07-19d9e721b782__USER__76561198040786185
Playing squad-fpp on Desert_Main - took 29.96 minutes
0.00: Weather: Clear, level Weather_Desert_Clear, weight 3
0.00: Map Desert_Main, weather Weather_Desert_Clear, region na, recorded by Hobocop, 0 players, 0 teams
=> Player senord, team 26 (ranked 0), 0 headshots, 0 kills, 0.00 damage, longest kill 0.00m, 0.00km covered
=> Player groxers, team 26 (ranked 0), 0 headshots, 0 kills, 0.00 damage, longest kill 0.00m, 0.00km covered
=> Player Hobocop, team 26 (ranked 0), 0 headshots, 0 kills, 0.00 damage, longest kill 0.00m, 0.15km covered
101.89: Berry-o knocked out UnnamedPone
105.52: Datidol knocked out T3lamon
from PIL import Image
import sys
def maskify(filename):
im = Image.open(filename)
px = im.load()
width, height = im.size
stride = 32
rows = []
#include <stdio.h>
#include <stdlib.h>
#include <dlfcn.h>
#include <stdint.h>
#include <unistd.h>
#include <stddef.h>
#include <stdbool.h>
#include <signal.h>
#include <jni.h>
@numinit
numinit / food.c
Last active June 25, 2017 18:21
Google CTF: solving food the hard way
/* Made for the Google 2017 CTF
* Author: Morgan Jones <me at numin dot it>
*
* Compile: clang -std=gnu99 -fopenmp -O3 -funroll-loops -fomit-frame-pointer -ofood food.c
* Run: ./food <start percentage> <end percentage> [num threads=autodetect]
*/
#include <unistd.h>
#include <stdint.h>
#include <stdio.h>
#!/usr/bin/env ruby
# usage: echo <string> | ruby kryptos.rb
# assumes you have a spreadsheet or something open
# with the top left character (space) at column A, row 1
k4 = <<EOF.chomp.lines.map(&:chomp)
OBKR
UOXOGHULBSOLIFBBWFLRVQQPRNGKSSO
TWTQSJQSSEKZZWATJKLUDIAWINFBNYP
@numinit
numinit / shattered_length_extension.rb
Last active February 24, 2017 04:28
Usage: echo -n text_to_append | ruby shattered_length_extension.rb
#!/usr/bin/env ruby
# output format:
# => collided sha1
# => message 1 base64
# => message 2 base64
require 'base64'
require 'digest/sha1'
def foo a, h
[a, h]
end
foo :bar, {
a: proc do
end,
b: proc do
end
}
@numinit
numinit / dtext.c
Last active January 31, 2022 14:07
Dumps in-memory text segments by single-stepping with ptrace. Usage: dtext <program> [args...]
/* Dumps in-memory text segments by single-stepping with ptrace.
* Usage: dtext <program> [args...]
*/
#define _GNU_SOURCE
#include <stdio.h>
#include <unistd.h>
#include <stdbool.h>
#include <stdlib.h>