Skip to content

Instantly share code, notes, and snippets.

View watbulb's full-sized avatar
:shipit:

Dayton watbulb

:shipit:
  • Calgary, Canada
  • 03:37 (UTC -06:00)
View GitHub Profile
@watbulb
watbulb / arm64_msr.py
Created November 6, 2023 00:57
arm64_msr.py
import struct
Op0_shift = 19
Op1_shift = 16
CRn_shift = 12
CRm_shift = 8
Op2_shift = 5
MAX_OP0 = 3
MAX_OP1 = 7
@watbulb
watbulb / git-recover-reset-hard.txt
Created November 22, 2020 04:15
recovering uncommitted changes from a git reset --hard (godbless)
for blob in $(git fsck --lost-found | cut -d' ' -f3); do
git cat-file -p $blob > $blob.txt
done
@watbulb
watbulb / get-ps5-stock.sh
Created November 15, 2020 08:09
Simple posix shell script to check PS5 availability against multiple stores (curl & pup). Extend as appropriate.
#!/bin/bash
# Simple script to check PS5 availability against multiple stores
# @watbulb
[[ -n $DEBUG ]] && set -x || :
set -e -o posix
AGENT="Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:59.0) Gecko/20100101 Firefox/59.0"
declare -a STORES=(
# Bestbuy (bestbuy.html)
https://www.bestbuy.ca/en-ca/product/playstation-5-digital-edition-console-online-only/14962184
@watbulb
watbulb / Dockerfile.libelfmaster
Created May 18, 2020 21:01
libelfmaster docker image
### libelfmaster docker based image ###
# Build: docker build -t "libelfmaster:latest" -f Dockerfile.libelfmaster .
# Run: docker run --rm -it -v ${PWD}/data:/tmp/data "libelfmaster:latest"
#
# Maintainer: https://github.com/watbulb
###
FROM ubuntu:latest
# Environment
ENV INSTALL_PREFIX=/opt/elfmaster
@watbulb
watbulb / Dockerfile.elfutils
Last active May 17, 2020 04:22
elfutils docker based image (0.179)
# elfutils docker based image
# Maintainer: https://github.com/watbulb
FROM ubuntu:latest
ENV LD_LIBRARY_PATH=/usr/local/lib
# Working directory and root
ENV BASE=/root
WORKDIR ${BASE}
@watbulb
watbulb / gist:b3a731bd1b325046c40351d62c94c68c
Created November 12, 2019 22:03
Catalina (10.15.1) apple root sandboxed processes during idle
[+] Sandboxed Root Processes:
80:/usr/sbin/systemstats
82:endpointsecurityd
89:/usr/libexec/logd
98:/System/Library/Frameworks/CoreServices.framework/Frameworks/Metadata.framework/Support/mds
104:/usr/libexec/coreduetd
107:/usr/libexec/opendirectoryd
108:/System/Library/PrivateFrameworks/ApplePushService.framework/apsd
114:/usr/sbin/securityd
@watbulb
watbulb / dib2bmp.py
Last active December 10, 2020 22:43
Universal Device Independant Bitmap (DIB) to BMP Converter
#!/usr/bin/env python3
'''
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. You just DO WHAT THE FUCK YOU WANT TO.
Universal DIB to BMP converter. <d$pid>
'''
import sys