Skip to content

Instantly share code, notes, and snippets.

View johnzweng's full-sized avatar

Johannes Zweng johnzweng

View GitHub Profile
@rockstardev
rockstardev / cve-2026-98432-fix-btcpayserver-ubuntu.txt
Created October 30, 2026 10:41
cve-2026-98432-fix-btcpayserver-ubuntu
# CVE-2026-98432 stopgap. For Ubuntu 20.04 and 24.04.
# Log in as ubuntu, copy everything in this file, paste it into the SSH session.
# Done when the last line prints: active
sudo apt-get update -qq </dev/null && sudo apt-get install -y nftables </dev/null
sudo tee /etc/nftables-cve-2026-98432.nft >/dev/null <<'EOF'
add table inet cve_2026_98432
flush table inet cve_2026_98432
table inet cve_2026_98432 {
chain pre {
type filter hook prerouting priority raw - 10; policy accept;
@GNSPS
GNSPS / ProxyFactory.sol
Last active December 11, 2024 21:58
Improved `delegatecall` proxy contract factory (Solidity) [v0.0.5]
/***
* Shoutouts:
*
* Bytecode origin https://www.reddit.com/r/ethereum/comments/6ic49q/any_assembly_programmers_willing_to_write_a/dj5ceuw/
* Modified version of Vitalik's https://www.reddit.com/r/ethereum/comments/6c1jui/delegatecall_forwarders_how_to_save_5098_on/
* Credits to Jorge Izquierdo (@izqui) for coming up with this design here: https://gist.github.com/izqui/7f904443e6d19c1ab52ec7f5ad46b3a8
* Credits to Stefan George (@Georgi87) for inspiration for many of the improvements from Gnosis Safe: https://github.com/gnosis/gnosis-safe-contracts
*
* This version has many improvements over the original @izqui's library like using REVERT instead of THROWing on failed calls.
* It also implements the awesome design pattern for initializing code as seen in Gnosis Safe Factory: https://github.com/gnosis/gnosis-safe-contracts/blob/master/contracts/ProxyFactory.sol
@ageis
ageis / openpgp-card-guide.md
Last active February 14, 2026 07:20
Quick GPG Smartcard Guide
@spicycode
spicycode / tmux.conf
Created September 20, 2011 16:43
The best and greatest tmux.conf ever
# 0 is too far from ` ;)
set -g base-index 1
# Automatically set window title
set-window-option -g automatic-rename on
set-option -g set-titles on
#set -g default-terminal screen-256color
set -g status-keys vi
set -g history-limit 10000