Skip to content

Instantly share code, notes, and snippets.

View RandyMcMillan's full-sized avatar
🛰️
Those who know - do not speak of it.

randymcmillan RandyMcMillan

🛰️
Those who know - do not speak of it.
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;
@lukechilds
lukechilds / README.md
Last active August 20, 2026 22:10
Connector Vaults: Delegated Execution and Stateless Revocation

Connector Vaults

Connector Vaults: Delegated Execution and Stateless Revocation

Each chain of presigned vault transactions carries one tiny connector UTXO controlled by a controller wallet. Every transaction spends the current connector and creates the next, so it can execute only when the controller wallet signs at broadcast time. Spending the live connector elsewhere revokes the remaining chain without moving its funds or requiring presigned revocation transactions.

Properties:

  • Offline signatures and presigned transactions are halved. An n-step policy needs n offline-signer authorizations instead of 2n (n authorizations + n revocations). This is especially impactful when performing large signing ceremonies on low-powered devices like hardware wallets.
  • Revocation transactions do not need to be presigned. The controller wallet constructs th
@jamesob
jamesob / analysis.md
Last active September 17, 2026 04:34
switck == doc-hex

switck == doc-hex: proven by GPG commit signatures

Date: 2026-08-04 Status: verified

Question

Is the GitHub alias switck (github.com/switck/libngu) actually doc-hex (Peter D. Gray, Coinkite/Coldcard), on the basis of GPG signatures over git commits?

@RandyMcMillan
RandyMcMillan / perfect_ip.rs
Last active May 31, 2026 19:32 — forked from rust-play/playground.rs
perfect_ip.rs
#[derive(Debug, Clone)]
struct Header {
seq_num: u32,
total_packets: u32,
}
#[derive(Debug, Clone)]
struct ProtocolSlice {
id: String,
header: Header,
@tomlarkworthy
tomlarkworthy / isomorphic-git-cors-proxy.js
Last active August 28, 2026 21:22
isomorphic git proxy on Cloudflare Workers
addEventListener('fetch', e => e.respondWith(handle(e.request)))
const ok = (req,u)=>{
const q=u.searchParams
return req.method==='OPTIONS'||
(req.method==='GET' && u.pathname.endsWith('/info/refs') &&
['git-upload-pack','git-receive-pack'].includes(q.get('service')))||
(req.method==='POST'&&u.pathname.endsWith('git-upload-pack') &&
req.headers.get('content-type')==='application/x-git-upload-pack-request')||
(req.method==='POST'&&u.pathname.endsWith('git-receive-pack') &&
@RubenSomsen
RubenSomsen / SwiftSync.md
Last active November 10, 2026 22:42
SwiftSync - smarter synchronization with hints

SwiftSync

Near-stateless, fully parallelizable validation of the Bitcoin blockchain with hints about which outputs remain unspent. All other inputs/outputs are efficiently crossed off inside a single hash aggregate that only reaches zero if validation was successful and the hints were correct.

15-minute talk summarizing the protocol

Introduction

Validation is at the heart of Bitcoin. Any improvements in validation speed will have a direct impact on the scalability of the system, including everything that is built on top of it. For this reason improving validation performance may be one of the most important things we can do.

@84adam
84adam / bash_c_example.sh
Created May 9, 2024 17:12
Bash-C Hello World: Compile and run a C program from a single Bash script
#!/bin/bash
# bash_c_example.sh
# Directory to store the C source file and the executable
EXAMPLES_DIR="$HOME/bash_c_examples"
# Ensure the directory exists, create it if not
mkdir -p "$EXAMPLES_DIR"
# Check if hello_world.c and hello_world executable already exist
@riazul701
riazul701 / Embedded Python in BASH
Created October 19, 2023 20:11 — forked from welbornprod/Embedded Python in BASH
A little trick to embed python code in a BASH script.
#!/bin/bash
# Here are some embedded Python examples using Python3.
# They are put into functions for separation and clarity.
# Simple usage, only using python to print the date.
# This is not really a good example, because the `date`
# command works just as well.
function date_time {
@RandyMcMillan
RandyMcMillan / .gitignore
Last active September 7, 2023 23:14
clone gitHub organization
gnostr-org
@staab
staab / survey.md
Last active January 19, 2026 13:01
A survey of Nostr DM proposals

This is an attempt to take a step back and summarize all proposed approaches to private messages (DMs, group chats, and general-purpose nostr-within nostr, including for large groups of people) for the purpose of building a secure, feature-complete, interoperable solution.

This topic has come up repeatedly over nostr's history, and has entered the limelight again because of HRF's e2e encrypted group chats bounty. The hope here is to get everyone on the same page and hammer out one or more NIPs that can incorporate the best parts of all proposed solutions so we can finally get secure messaging on nostr.

Please comment with thoughts, criticisms, missing proposals/implmentations, and I will update the gist as we go along.

Proposals Reference