# Private Key Sharding

Mozi enhances security by implementing Private Key Sharding, a method that splits a user's private key into multiple shards. These shards are distributed across secure locations, ensuring that no single entity has access to the complete key.

#### How It Works

1. **Key Generation**:
   * When a user creates a wallet, Mozi generates a private key.
   * This key is then divided into multiple shards using Shamir's Secret Sharing algorithm.
2. **Sharding Distribution**:
   * The shards are securely distributed across multiple servers and user-controlled devices.
   * No single server or device holds the entire private key.
3. **Transaction Authorization**:
   * To authorize a transaction, Mozi retrieves the necessary shards.
   * A quorum of shards is combined to reconstruct the private key temporarily for transaction signing.
   * Once the transaction is signed, the key is immediately discarded.
4. **Security Benefits**:
   * Reduces the risk of key compromise, as an attacker would need access to multiple shards from different locations.
   * Enhances fault tolerance, allowing for recovery even if some shards are lost.
5. **User Control**:
   * Users can opt to store certain shards on their personal devices for added control.
   * Mozi provides options to manage shard recovery and backup.

### Security Features

* **Encryption**: All data transmitted and stored within Mozi is encrypted using industry-standard protocols.
* **Private Key Sharding**: Provides an additional layer of security by distributing private key shards across multiple locations.
* **Backup and Recovery**: Secure backup options to ensure you can recover your wallet in case of device loss.
