npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

keysplitter

v0.4.0

Published

Splits a crypto private key into 3 redundant, equally safe keys

Downloads

3

Readme

installation

npm install keysplitter

This tool lets you split up your crypto private key into 3 separate keys, each with equal cryptographic strength.

Here's how you would use this:

  1. Create your 3 split keys and store them in 3 different physical places (preferably in a paper wallet or other offline storage)
  2. Destroy the original private key. (yes, this is safer than keeping it)
  3. Later, when you need to access your crypto account again, you can restore your private key with any 2 out of the 3 split keys.

Why is this better than pretty much all other methods out there?

  • storing your private keys on your computer makes it susceptible to theft by a hacker.
  • if you encrypt your private keys using some password, you now need to worry about finding a safe place to keep your password. If you don't write it down anywhere, and you forget it, or something was to happen to you, you and/or your family will lose it all.
  • if you store your private key on a paper wallet in your safe, you can lose everything through theft or if your house burns down.
  • if you keep your private key in multiple places (for redundancy), it will make it less likely that you will lose it, but it will also make it more likely to get stolen.
  • if you cut up your private key into 2 or more pieces and store it in multiple places, you can lose access to all your crypto funds if you lose just one piece.

The split keys that this script generates eliminates all of the above risks in an elegant and ultra-secure way.

If any of your 3 keys get stolen, nothing is lost. It's useless to a thief, and you can still access your account using the other 2 keys.

That said, use this tool at your own risk. I accept no responsibility if you lose your private key or crypto while using this tool. Always make sure your system isn't compromised. Also test restoring your private key from the split keys before destroying the original private key.

using this library

const assert = require('assert');
const Splitter = require('splitter');
const splitter = new Splitter();

const originalKey = '3a1076bf45ab87712ad64ccb3b10217737f7faacbf2872e88fdd9a537d8fe266';
let keys = splitter.splitPrivateKey(originalKey);
console.dir(keys);
//[ '010b5701057440e7740c9628a00ba62a63ea727b04871041c40b1168e6b2a5963e158dd64c1588c8714efcf8885ebc50',
//  '020bda53f693d2a1c9ef2169640a6380696f3fc5439a6fb00b6d1173cb054cf37dbcfeec1588c8714efcf8885ebc50',
//  '030b2f98bece0b577ff9746a1c0a676047acd4af8507bcda0b6d1173cb054cf37dbcfeec1168e6b2a5963e158dd64c' ]

// We can restore the private key with split key 0 and key 1
assert(splitter.restorePrivateKey(keys[0], keys[1]) === originalKey);  // true

// or we can restore it using key 0 and key 2
assert(splitter.restorePrivateKey(keys[0], keys[2]) === originalKey);  // true

// or we can restore it using key 1 and key 2
assert(splitter.restorePrivateKey(keys[1], keys[2]) === originalKey);  // true

Command line tool

To create split keys:

keysplitter split 3a1076bf45ab87712ad64ccb3b10217737f7faacbf2872e88fdd9a537d8fe266

(add the -b or --barcode option to have it also generate barcode PNG images)

To restore private key from any 2 split keys:

keysplitter restore 120bc4f5f571d3b89ececb47770a7d266a8d3edc14bb859e0b1b9e7951556ca8aa51958e0ba8e574e2d501c562f6ed \
020b31b893cba77e86b44820a10a79406aa978867c4a80900b1b9e7951556ca8aa51958e0fcee550a48f693467f85f

A tool to restore a private key directly from barcode images is in the works.