Skip to content

Instantly share code, notes, and snippets.

View jevinskie's full-sized avatar

Jevin Sweval jevinskie

View GitHub Profile
@moyix
moyix / pybefore.py
Created April 28, 2024 21:03
Script to list the most recent version of a PyPI package released before a particular date
#!/usr/bin/env python3
import sys
import requests
from datetime import datetime, timezone
# Ok I'll be honest ChatGPT wrote the vast majority of this
# Use at your own risk
def get_latest_version_before_date(package_name, cutoff_date):
@Cryptiiiic
Cryptiiiic / Cryptex.md
Last active October 30, 2024 03:38
Short overview of iOS 16+ nonce-seeds nvram variable most notably used for cryptex.

Cryptex

Short overview of iOS 16+ nonce-seeds nvram variable most notably used for cryptex.

Some structs

struct nonce_seeds_header {
    uint32_t blob_version;
    uint8_t pad[6];
@0xilis
0xilis / Form_Apple_Archive_From_Unsigned_Shortcut.c
Last active March 25, 2025 03:24
Hacky reforming signed shortcut AEA from apple archive
struct libshortcutsign_header_info {
char *header;
int keyCount;
uint32_t fieldKeys[30];
uint32_t fieldKeyPositions[30];
uint32_t currentPos;
};
uint32_t get_aa_header_field_key(struct libshortcutsign_header_info info, uint32_t i) {
if (i >= info.keyCount) {
@ArcaneNibble
ArcaneNibble / notes.md
Created April 5, 2024 21:59
QingKe RISC-V XW opcode encoding

WCH QingKe RISC-V XW extension opcode encoding

This has been reverse engineered from the toolchain only and has not been tested on hardware.

The c.lbu, c.lhu, c.sb, and c.sh opcodes replace some standard opcodes (that the QingKe cores do not implement, as the replaced opcodes require the D extension), and they also appear to be compatible with "Huawei" extensions mentioned here.

The c.lbusp, c.lhusp, c.sbsp, and c.shsp opcodes exist in a "reserved" opcode block.

001 uimm[0] uimm[4:3] rs1` uimm[2:1] rd`  00			c.lbu		(replacing c.fld)
@lab313ru
lab313ru / password.bin
Last active August 26, 2025 16:10
USB Password fuse generator for Amlogic A113X (AXG)
password12345678
@al3xtjames
al3xtjames / flake.nix
Last active November 2, 2025 16:00
Thunderbolt NVM firmware
{
description = "Minimal NixOS installation media";
inputs.nixos.url = "nixpkgs/nixos-23.11";
outputs = { self, nixos }: {
nixosConfigurations = {
exampleIso = nixos.lib.nixosSystem {
system = "x86_64-linux";
modules = [
"${nixos}/nixos/modules/installer/cd-dvd/installation-cd-graphical-plasma5.nix"
({
@iMrDJAi
iMrDJAi / CVE-2006-4304.py
Last active July 16, 2025 01:15
My implementation of a proof of concept for the `CVE-2006-4304` sppp driver vulnerability that affected PS4/PS5 and earlier versions of FreeBSD/NetBSD
from scapy.all import sniff, sendp
from socket import *
import time
# Replace with your PS4/5's MAC address.
dst_mac=b'\xaa\xbb\xcc\xdd\xee\xff'
# Replacing source MAC address is not mandatory
src_mac= b'\xab\xcd\xef\xab\xcd\xef'
# Replace this with your computer's ethernet interface name
iface_name = 'Ethernet'
@ArcaneNibble
ArcaneNibble / test.c
Created March 27, 2024 04:22
CH579 deblobbing WIP
#include <stdint.h>
#include <string.h>
#include "CH579SFR.h"
void write_str(const char *s) {
for (uint32_t i = 0; i < strlen(s); i++) {
while (!(R8_UART1_LSR & RB_LSR_TX_FIFO_EMP)) {}
R8_UART1_THR = s[i];
}
@OrionReed
OrionReed / dom3d.js
Last active September 28, 2025 08:09
3D DOM viewer, copy-paste this into your console to visualise the DOM topographically.
// 3D Dom viewer, copy-paste this into your console to visualise the DOM as a stack of solid blocks.
// You can also minify and save it as a bookmarklet (https://www.freecodecamp.org/news/what-are-bookmarklets/)
(() => {
const SHOW_SIDES = false; // color sides of DOM nodes?
const COLOR_SURFACE = true; // color tops of DOM nodes?
const COLOR_RANDOM = false; // randomise color?
const COLOR_HUE = 190; // hue in HSL (https://hslpicker.com)
const MAX_ROTATION = 180; // set to 360 to rotate all the way round
const THICKNESS = 20; // thickness of layers
const DISTANCE = 10000; // ¯\\_(ツ)_/¯
@theevilbit
theevilbit / get_apple_technotes.sh
Created March 26, 2024 09:13
Download Apple Technotes
#!/bin/zsh
#ugly script bu works. Most of the time. You might need to rerun to get all pages.
#need to open the pages before we can do --print-to-pdf or --dump-dom as otherwise it doesn't load them
#doing PDFs as raw htmls look really ugly
/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --incognito https://developer.apple.com/documentation/technotes/
sleep 10
/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --headless=new --incognito --dump-dom https://developer.apple.com/documentation/technotes/ > technotes.html
cat technotes.html | grep -Eo "href=\"/documentation/technotes/tn[a-zA-Z0-9/-]*\"" | cut -d "\"" -f 2 | cut -d "/" -f 4 | sort -u > urls.txt