Skip to content

Instantly share code, notes, and snippets.

View xanoni's full-sized avatar
🐱
I'm a cat

Linus Xanoni xanoni

🐱
I'm a cat
View GitHub Profile
@philsnow
philsnow / walkthrough.md
Last active January 8, 2024 16:22
Another way to manually add another site to Firefox Multi-Account Containers

Another way to manually add another site to Firefox Multi-Account Containers

Multi-Account Containers and Temporary Containers are great extensions for a great browser. I get really frustrated when I can't make them work together the way I want, though.

The most common problem I have is when some site redirects through a bunch of subdomains (usually during login). Because of Temporary Containers, each redirect opens in a new tab+container which doesn't bring cookies from the other container, and the login flow breaks.

If the resulting page leaves you on the subdomain that broke the flow, you can use the menu to add another "always open in container" rule, but if it didn't (because on error the site redirects you to the first subdomain or somewhere else), you can't use that menu. Some people have found workarounds that work for them (like [changing `networ

@kristapsk
kristapsk / odroid-hc4-raspibolt-notes.md
Last active December 2, 2021 00:58
Odroid HC4 RaspiBolt installation notes

Odroid HC4 RaspiBolt installation notes

Upgrading

Upgrading kernel will make it unbootable.

# apt update
# apt-mark hold linux-odroid-c4
linux-odroid-c4 set on hold.
@xanoni
xanoni / rebalance-autopilot.sh
Last active November 15, 2021 03:48
lnd: rebalance channel autopilot
#! /usr/bin/env bash
PCT_INIT=100
PCT_MIN=25
PCT_DROP=25
MIN_AMOUNT=10000 # don't rebalance below this amount (def: 10k)
MIN_LOCAL=1000000 # min outbound sats per chan (def: 1M)
MIN_REMOTE=1000000 # min inbound sats per chan (def: 1M)
FEE_FACTOR=0.95 # (def: 1.0)
@xanoni
xanoni / monerod-i2p.conf
Last active August 19, 2021 08:20
monerod: configure inbound I2P tunnel
# File: ~/.bitmonero/monerod.conf
[...]
tx-proxy=i2p,127.0.0.1:4447,25 # to send transactions via I2P
pad-transactions=1 # anti traffic analysis
# Get tunnel address for below line from /var/lib/i2pd/destinations
anonymous-inbound=<TUNNEL_ADDR>.b32.i2p:18084,127.0.0.1:18084,25
[...]
@xanoni
xanoni / scp-delete-during-transfer.sh
Last active August 3, 2021 06:59
scp-delete-during-transfer.sh: for when you're running out of disk space and need to scp a file out while deleting chunks of it
#! /usr/bin/env -S bash -e
SSH_USERHOST="user@host"
REMOTE_PATH="/tmp/disk_backup.img"
OUT_PATH="./$(basename ${REMOTE_PATH})"
TMP_PATH="/tmp/ssh-big-copy"
SLICES=200
echo -e "\nGetting from ${SSH_USERHOST}: ${REMOTE_PATH}\n"
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=googlemail.com; s=20161025;
h=mime-version:in-reply-to:references:from:date:message-id:subject:to;
bh=+lkRo0xHq0A5qPt4Ud4bXvNaQX2AJTwdlR5UthC+VcY=;
b=jau+o2hGzSHgRaoPfJe9eMaxU4Lh7DsSbtV8wQehOE8xaULsl+CoYhZHxXzm8Dr0KW
H5H6up8OANeXTFyBnW35FWBqr6cdCiPbzHCKslHnurBb0/CQ4yinWjahpIbsu35gxfOM
hc1q8r02ahsVyfXrpegxHxv2TjmKEniO0WiXa5ybooZngNJEUdxLwHgPiK7Nnwm7eA8N
/hP1vCBspeaTT2muu22srZkwVygeJiuxUJTewc9bT57LRFQQQ75YELEKIbrL6wwtE7Hf
EGzqdNHJpFvAttioPpSCf54YALz2rKuvrCmEBkFXRa+gyBX2CIDIeqQdzbrRHKiZ10nM
i/Lw==
@chris-belcher
chris-belcher / coinswap-design.md
Last active March 22, 2024 04:10
Design for a CoinSwap Implementation for Massively Improving Bitcoin Privacy and Fungibility

Design for a CoinSwap Implementation for Massively Improving Bitcoin Privacy and Fungibility

25/5/2020

Abstract

Imagine a future where a user Alice has bitcoins and wants to send them with maximal privacy, so she creates a special kind of transaction. For anyone looking at the blockchain her transaction appears completely normal with her coins seemingly going from address A to address B. But in reality her coins end up in address Z which is entirely unconnected to either A or B.

Now imagine another user, Carol, who isn't too bothered by privacy and sends her bitcoin using a regular wallet which exists today. But because Carol's transaction looks exactly the same as Alice's, anybody analyzing the blockchain must now deal with the possibility that Carol's transaction actually sent her coins to a totally unconnected address. So Carol's privacy is improved even though she didn't change her behaviour, and perhaps had never even heard of this software.

@Jorijn
Jorijn / lnd-watchtower-over-tor.md
Last active July 1, 2021 07:21
Instructions to enable the LND watchtower over TOR

Create a TOR hidden service

In configuration file /etc/tor/torrc add:

HiddenServiceDir /var/lib/tor/hidden_service/lnd_watchtower
HiddenServiceVersion 3
HiddenServicePort 9911 127.0.0.1:9911

Now reload the TOR daemon with systemctl reload tor. Inspect the hostname TOR has assigned to your secret service with:

@bbqtd
bbqtd / macos-tmux-256color.md
Last active April 24, 2024 01:28
Installing tmux-256color for macOS

Installing tmux-256color for macOS

  • macOS 10.15.5
  • tmux 3.1b

macOS has ncurses version 5.7 which does not ship the terminfo description for tmux. There're two ways that can help you to solve this problem.

The Fast Blazing Solution

Instead of tmux-256color, use screen-256color which comes with system. Place this command into ~/.tmux.conf or ~/.config/tmux/tmux.conf(for version 3.1 and later):

@chris-belcher
chris-belcher / financial-mathematics-of-joinmarket-fidelity-bonds.md
Last active November 7, 2023 02:24
Financial mathematics of joinmarket fidelity bonds