Skip to content

Instantly share code, notes, and snippets.

@dabura667
dabura667 / fixed.sh
Last active March 14, 2018 05:13
Fixed pubkey command
curl \
--data-urlencode sig="`\
echo '{"body":{"key":{"eldest_kid":"0101a8dbef6ea8164aaa7a3616de95a1843c6e1996a5102c90200b54b41ba97de49b0a","fingerprint":"0a6a58a14b5946abde18e207a3adb67a2cdb8b35","full_hash":"99ed12fa1979ef175aecaaf3f0872f9e3ccfd30d1a8dcdf6e756ce0227ce4f80","host":"keybase.io","key_id":"a3adb67a2cdb8b35","kid":"0101a8dbef6ea8164aaa7a3616de95a1843c6e1996a5102c90200b54b41ba97de49b0a","uid":"03a69327bfbb7860c772345076484c19","username":"isislovecruft"},"type":"eldest","version":1},"ctime":1519428650,"expire_in":157680000,"prev":null,"seqno":1,"tag":"signature"}' | \
gpg -u '0a6a58a14b5946abde18e207a3adb67a2cdb8b35' -a --sign`" \
--data-urlencode type="eldest" \
--data-urlencode session="lgHZIDAzYTY5MzI3YmZiYjc4NjBjNzcyMzQ1MDc2NDg0YzE5zlqQo1vOAeEzgNkgNzBmMmUwYzk5M2FiMjNkODQ3N2E1YjE1YTFiOGIxMDLEIOVa/OtsvVcgT66tlmlrIbkALadXIktmr5D4I4HdH2cY" \
--data-urlencode csrf_token="lgHZIDAzYTY5MzI3YmZiYjc4NjBjNzcyMzQ1MDc2NDg0YzE5zlqQo1vOAAFRgMDEIIyPeDuHFq5EBgnha6MTZ8cSrgXO5XbEKP2QFOENmvD9" \

Keybase proof

I hereby claim:

  • I am dabura667 on github.
  • I am dabura667 (https://keybase.io/dabura667) on keybase.
  • I have a public key whose fingerprint is 312F AC03 70A4 F093 3CBB 8866 0DCB C05E D280 2A17

To claim this, I am signing this object:

@dabura667
dabura667 / recover.js
Last active April 11, 2017 08:54
js for recovering partially know phrases for BIP44
var Mnemonic = require('bitcore-mnemonic')
var fs = require('fs')
var insightRestClient = require('insight-cli').RestClient
var insightRest = new insightRestClient();
// put your word parts here separated by space
var wordParts = "exo dev ank rot loc arr gaz tal rea aba kid sig"
// Skip trying this many valid phrases.
var skipROWS = 378600
@dabura667
dabura667 / pbkdf2.php
Last active May 25, 2016 15:22 — forked from rsky/pbkdf2.php
A hash_pbkdf2() implementation for PHP versions 5.3 and 5.4.
<?php
/**
* Generate a PBKDF2 key derivation of a supplied password
*
* This is a hash_pbkdf2() implementation for PHP versions 5.3 and 5.4.
* @link http://www.php.net/manual/en/function.hash-pbkdf2.php
*
* @param string $algo
* @param string $password
@dabura667
dabura667 / index.js
Created September 25, 2015 16:44
index.js
#!/usr/bin/env node
'use strict';
var Bitcoin = require('bitcoinjs-lib');
Bitcoin._ = require('bitcore-mnemonic/node_modules/bitcore/node_modules/lodash')._;
Bitcoin.HD = require('bitcore-mnemonic/node_modules/bitcore').HDPrivateKey
Bitcoin.Mnemonic = require('bitcore-mnemonic');
Bitcoin.Buffer = require('Buffer');
Bitcoin.Crypto = require('crypto-browserify');
@dabura667
dabura667 / NewHDWallet.md
Last active August 29, 2015 14:15
A proposal for an improved HD wallet generation algorithm

WARNING: Current proposal does not protect against colluding of a single ancestor public node and a single descendant private node. This is still a WIP.

Abstract

The current derivation method of Hierarchical Deterministic wallets has a weakness in which any individual private key may be combined with any ancestor extended public key (as long as there are no hardened keys in between) to generate the associated extended private key.

This proposal will set out to eliminate this weakness by:

  1. Using 1 leak protection of keys
  2. Using convention to prevent multiple keys being derived from the same parent.