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
@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 August 6, 2026 11:58
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,
@RubenSomsen
RubenSomsen / SwiftSync.md
Last active June 27, 2026 19:52
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

--- a/src/script/interpreter.cpp
+++ b/src/script/interpreter.cpp
@@ -504,6 +504,14 @@ bool EvalScript(std::vector<std::vector<unsigned char> >& stack, const CScript&
return set_error(serror, SCRIPT_ERR_MINIMALDATA);
}
stack.push_back(vchPushValue);
+ if ((flags & SCRIPT_VERIFY_DISCOURAGE_UPGRADABLE_NOPS) && opcode == OP_FALSE) {
+ auto pc_tmp = pc;
+ opcodetype next_opcode;
+ valtype dummy_data;
@rot13maxi
rot13maxi / main.rs
Created June 4, 2023 20:31
adaptor fun
use rand_chacha::ChaCha20Rng;
use schnorr_fun::fun::{KeyPair, Scalar};
use schnorr_fun::{Message, nonce, Schnorr};
use schnorr_fun::adaptor::Adaptor;
use schnorr_fun::fun::marker::Public;
use schnorr_fun::musig::MuSig;
use sha2::Sha256;
fn main() {
// Little proof of concept. Doesn't actually do real transactions, but you get the idea.