Privacy Tools Guide

Shamir Secret Sharing (SSS) provides a mathematically elegant solution for securing cryptocurrency seed phrases across multiple parties without placing trust in a single location. Originally described by cryptographer Adi Shamir in 1979, this algorithm enables you to divide a secret into N shares where any subset of K shares can reconstruct the original secret, but fewer than K shares reveal nothing. For cryptocurrency inheritance planning, this means you can distribute seed phrase fragments among family members, attorneys, or secure locations—ensuring no single point of failure compromises your holdings while enabling recovery when needed.

Understanding the Mathematics Behind SSS

The mathematical foundation relies on polynomial interpolation over a finite field. To create K shares from a secret, you construct a random polynomial of degree K-1 where the constant term equals your seed phrase (encoded as a number). Evaluating this polynomial at K different points produces the shares. Any K points uniquely determine the polynomial, while K-1 or fewer points remain information-theoretically secure.

This property makes SSS particularly valuable for inheritance scenarios: you might create a 3-of-5 scheme where any three family members together can recover the seed, but two share holders alone cannot access the funds. The cryptographic guarantees are provable—you cannot shortcut the security without obtaining sufficient shares.

Implementing SSS with the Python SSS Library

The Python ssss library provides a straightforward implementation. Install it:

pip install sss

Create a script to split your seed phrase:

#!/usr/bin/env python3
"""
Split a cryptocurrency seed phrase into Shamir shares.
Warning: Run this on an air-gapped machine for production use.
"""

import sys
import binascii
from sss import Share, Secret

def split_seed_phrase(seed_hex, shares=3, threshold=2):
    """
    Split a hex-encoded seed phrase into shares.

    Args:
        seed_hex: The seed phrase as a hex string
        shares: Total number of shares to generate
        threshold: Minimum shares needed to reconstruct
    """
    secret = Secret.from_hex(seed_hex)
    share_objects = secret.split(threshold=threshold, shares=shares)

    return [share.to_hex() for share in share_objects]

def combine_shares(share_hex_list):
    """
    Reconstruct the original seed from shares.

    Args:
        share_hex_list: List of share hex strings
    """
    shares = [Share.from_hex(hex_str) for hex_str in share_hex_list]
    secret = Secret.combine(shares)
    return secret.to_hex()

if __name__ == "__main__":
    if len(sys.argv) < 3:
        print("Usage: python sss_split.py <seed_hex> <threshold> <shares>")
        print("Example: python sss_split.py a1b2c3d4... 3 5")
        sys.exit(1)

    seed = sys.argv[1]
    threshold = int(sys.argv[2])
    shares = int(sys.argv[3])

    result = split_seed_phrase(seed, shares, threshold)
    print(f"\nGenerated {shares} shares (threshold: {threshold}):\n")
    for i, share in enumerate(result, 1):
        print(f"Share {i}: {share}")
    print("\nStore these shares in separate, secure locations.")

Run the script:

python sss_split.py a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6 3 5

Converting BIP39 Seed Phrases to Hex

Your cryptocurrency wallet likely uses BIP39 seed phrases (12 or 24 words). Convert these to hex for SSS processing:

#!/usr/bin/env python3
"""
Convert BIP39 mnemonic to hex for SSS processing.
Uses the reference implementation from trezor/trezor-crypto.
"""

# For production, install the trezor-crypto Python bindings
# pip install mnemonic

from mnemonic import Mnemonic

def mnemonic_to_hex(mnemonic_phrase, password=""):
    """Convert BIP39 mnemonic to hex seed."""
    mnemo = Mnemonic("english")
    if not mnemo.check(mnemonic_phrase):
        raise ValueError("Invalid mnemonic phrase")

    seed = mnemo.to_seed(mnemonic_phrase, passphrase=password)
    return seed.hex()

def hex_to_mnemonic(seed_hex, password=""):
    """Convert hex seed back to BIP39 mnemonic."""
    mnemo = Mnemonic("english")
    seed = bytes.fromhex(seed_hex)
    return mnemo.to_mnemonic(seed)

if __name__ == "__main__":
    # Example usage
    mnemonic = "abandon abandon abandon abandon abandon abandon abandon abandon abandon abandon abandon about"
    hex_seed = mnemonic_to_hex(mnemonic)
    print(f"Hex seed: {hex_seed}")

Practical Inheritance Planning: The 2-of-3 Strategy

For inheritance planning, a common and secure configuration uses three shares with a two-share threshold. This provides redundancy (losing one share doesn’t lock you out) while requiring collaboration to access funds.

Configure your shares as follows:

With this setup, any two of the three parties must collaborate to reconstruct the seed. If one share is lost due to death or incapacity, the other two can still access the funds. Include clear instructions in your estate planning documents explaining which parties hold shares and the recovery process.

Air-Gapped Security Considerations

Never generate shares on a machine connected to the internet. Malware could exfiltrate your seed phrase during processing. Create a dedicated air-gapped system:

# On an air-gapped machine, generate shares from a live USB
# Boot into Tails or a dedicated security-focused distribution

# Clone this repository
git clone https://github.com/yourtrustedrepo/shamir-inheritance.git
cd shamir-inheritance

# Run the splitting script in an isolated environment
python3 sss_split.py <your-hex-seed> 2 3

Disconnect your machine from all networks before entering seed phrases. Use a hardware wallet to generate your seed initially, then export it in hex format for SSS processing. Some hardware wallets like Ledger and Trezor now include native SSS support—verify your model supports this before purchasing.

Integrating with Existing Wallets

After recovering your seed from shares, import it into your wallet software:

# Using Bitcoin Core with a newly recovered seed
# WARNING: Ensure you're on an air-gapped machine
bitcoin-cli importprivkey <private-key-from-seed> "Inheritance Recovery" true

For Ethereum and EVM-compatible chains, use Metamask or similar wallets:

  1. Select “Import Account”
  2. Choose “Private Key”
  3. Enter the derived private key

Always verify the recovered wallet shows your expected balance before transferring any significant funds.

Alternative: Multi-Sig Wallets

Shamir Secret Sharing isn’t your only option for inheritance planning. Multi-signature wallets require multiple private keys to authorize transactions—different from SSS in that the blockchain itself enforces the requirement rather than cryptographic splitting.

Consider multi-sig for larger estates where you want ongoing control requiring multiple approvals for large transactions. SSS works better when you want an one-time backup that becomes active only after triggering conditions (death, incapacity).

Security Trade-offs and Risks

Weigh these considerations before implementing SSS for inheritance:

Social engineering attacks become more probable when multiple parties hold shares. An attacker who compromises two share holders obtains full access. Vet all participants carefully and consider whether their security practices meet your standards.

Share loss during your lifetime creates complications. If you lose your primary copy, family members with shares cannot recover funds. Maintain a personal backup or choose a threshold that accounts for potential loss.

Estate coordination requires clear documentation. Your will or trust should specify which parties hold shares, how to identify legitimate recovery requests, and any time-locks that prevent premature access.

Legal frameworks vary by jurisdiction. Consult with an estate planning attorney familiar with cryptocurrency to ensure your arrangement complies with local laws and your wishes will be honored.

Built by theluckystrike — More at zovo.one