Skip to content

Instantly share code, notes, and snippets.

View radix42's full-sized avatar

Jane Mercer radix42

View GitHub Profile
@radix42
radix42 / sapling_htlc_example.py
Created March 1, 2019 04:18 — forked from prestwich/sapling_htlc_example.py
Making and spending an HTLC in riemann
import riemann
from riemann import simple, utils
from riemann.encoding import addresses as addr
riemann.select_network('zcash_sapling_main')
# Needs a 32 byte hash, alice's pubkey, a timeout, and bob's pubkey
htlc_redeem_script = (
'OP_IF '
#include <linux/hrtimer.h>
#include <linux/module.h>
#include <linux/kernel.h>
static struct hrtimer timer;
enum hrtimer_restart yell_rick( struct hrtimer *timer )
{
ktime_t time;
printk(KERN_INFO "I turned myself into a logger morty! I'm dmesg RIIIICK!\n");
@radix42
radix42 / tweetdeck-limit-override.js
Created September 27, 2017 07:00 — forked from Zemnmez/tweetdeck-limit-override-dm-rt-fix.js
tweetdeck-limit-override.js
TD.services.TwitterClient.prototype.makeTwitterCall=function(b,e,f,g,c,d,h){c=c||function(){};d=d||function(){};b=this.request(b,{method:f,params:Object.assign(e,{weighted_character_count:!0}),processor:g,feedType:h});return b.addCallbacks(function(a){c(a.data)},function(a){d(a.req,"",a.msg,a.req.errors)}),b};
twttrTxt=Object.assign({},twttr.txt,{isInvalidTweet:function(){return!1},getTweetLength:function(){return twttr.txt.getTweetLength.apply(this,arguments)-140}});
@radix42
radix42 / hush-setup.sh
Created June 22, 2017 16:14
bash script to install and run HUSH on Debian or Ubuntu
#!/bin/bash
cd ~ && \
sudo apt-get update && \
sudo apt-get --yes --force-yes install \
build-essential pkg-config libc6-dev m4 g++-multilib \
autoconf libtool ncurses-dev unzip git python \
zlib1g-dev wget bsdmainutils automake supervisor iptables-persistent && \
sudo iptables -A INPUT -p tcp --dport 8888 -j ACCEPT && \
sudo netfilter-persistent save && \
mkdir -p ~/.hush && \
@radix42
radix42 / zbalance.sh
Created March 31, 2017 22:53 — forked from lorepozo/zbalance.sh
zbalance: quickly get your zcash addresses (taddr and zaddr) and their balances
#!/bin/sh
# zbalance: quickly get your zcash addresses (taddr and zaddr) and their balances.
# REQUIRES zcash-cli (https://z.cash) AND jq (https://stedolan.github.io/jq)
zaddr_withbalance () {
while read a
do echo $(zcash-cli z_getbalance $a) $a
done
}

Keybase proof

I hereby claim:

  • I am radix42 on github.
  • I am dmercer (https://keybase.io/dmercer) on keybase.
  • I have a public key whose fingerprint is 1118 A61B 6AE7 CFCF DB29 C59F 154F 37D2 E85E 6CB8

To claim this, I am signing this object: