Skip to content

Instantly share code, notes, and snippets.

View grant-h's full-sized avatar

Grant Hernandez grant-h

View GitHub Profile
@grant-h
grant-h / hello.c
Last active August 2, 2022 06:12
A 400 byte, alternative "Hello world!"
// Run with gcc -o hello hello.c && ./hello
// An alternative "Hello World!" By DigitalCold
#include<unistd.h>
#include<errno.h>
main(){char*s=&errno,
*a=s,*t="@?>=",*z=t,
h[]={12,29,7,0,3,177,
87,-8,3,-6,-8,189,233,
1};for(;*z;s--){for(
;access(s,0),*a==14;
@grant-h
grant-h / epic_manager.py
Created August 24, 2022 15:39
Samsung EPIC Decryptor
#!/usr/bin/env python3
HELP="""
Samsung EPIC Decrypter
by @Digital_Cold, Aug 2022
Samsung EPIC is a power management daemon for Android. It stores its profiles
in AES CFB encrypted JSON files. The key is hardcoded per build in an ELF
section. By extracting the key and using the same decryption, we can recover
the JSON file.
@grant-h
grant-h / exploit.py
Last active July 30, 2023 05:27
Pwntools template
#!/usr/bin/env python
# coding: utf-8
import sys
import time
# pip install pwn
from pwn import *
# pip install ipython
from IPython import embed