Verifying that +prestwich is my blockchain ID. https://onename.com/prestwich
I hereby claim:
- I am prestwich on github.
- I am frdwrd (https://keybase.io/frdwrd) on keybase.
- I have a public key whose fingerprint is 46D3 0F12 AEF7 DB4F 306F 65DF 519E 010A 7902 8CCC
To claim this, I am signing this object:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import riemann | |
from riemann.encoding import addresses | |
# Switch to Litecoin | |
riemann.select_network('litecoin_main') | |
addresses.make_p2pkh_address(pubkey_bytes) | |
# Switch to Bitcoin Cash | |
riemann.select_network('bitcoin_cash_main') | |
addresses.make_p2pkh_address(pubkey_bytes) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from riemann.script import serialization | |
p2pkh_pk_script = 'OP_DUP OP_HASH160 {} OP_EQUALVERIFY OP_CHECKSIG' | |
script = p2pkh_script.format(pubkey_hash_hex) | |
stack_script = '{} {}'.format(sig_hex, pubkey_hex) | |
stack_script = serialization.serialize(stack_script) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import riemann | |
from riemann import networks | |
from riemann.script import examples | |
from riemann.encoding import addresses | |
pubkey_0 = '00' * 33 | |
pubkey_1 = '11' * 33 | |
msig = examples.msig_two_two | |
msig = msig.format(pk0=pubkey_0, pk1=pubkey_1) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from riemann import simple | |
outpoint = simple.outpoint(tx_id, index) | |
# Spend a P2PKH output: | |
tx_ins = [simple.unsigned_input(outpoint)] | |
# Spend a P2SH output | |
tx_ins += [simple.unsigned_input( | |
outpoint=outpoint, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This is an alpha contract designed to be proxied | |
// It is NOT production ready | |
contract Nonfungiblizer { | |
bool initDone; | |
address owner; | |
address asset; | |
uint256 value; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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 ' |
0x30217b1cff7c7a11cf1b36efdb4ab787e938619f88d975b1eef0bdabd1bf72da
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
GETH_NAME=geth | |
GETH_IMAGE=ethereum/client-go:latest | |
PRYSM_NAME=prysm | |
PRYSM_IMAGE=gcr.io/prysmaticlabs/prysm/beacon-chain:stable | |
# volumes for containers | |
STORAGE_LOCATION=~/eth/data | |
GETH_STORAGE=$STORAGE_LOCATION/geth | |
PRYSM_STORAGE=$STORAGE_LOCATION/prysm |
OlderNewer