tibet-vault 0.1.0
Time-Locked Disclosure & Dead Man's Switches - The Open Standard for Cryptographic Time Capsules
License: MIT
Requires Python: >=3.8
Keywords: ai-security, audit-trail, dead-man-switch, disclosure, encryption, ethical-ai, tibet, time-lock, trust, vault, whistleblower

# TIBET Vault

**The Open Standard for Time-Locked Disclosure & Dead Man's Switches**

> **HTTPS = Trust in Connection**
> **TIBET = Trust in Time**

[![PyPI version](https://badge.fury.io/py/tibet-vault.svg)](https://badge.fury.io/py/tibet-vault)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
[![Python 3.8+](https://img.shields.io/badge/python-3.8+-blue.svg)](https://www.python.org/downloads/)

---

## What is TIBET Vault?

TIBET Vault is a cryptographic time capsule system. Lock secrets until a specific date, or set up a dead man's switch that auto-unlocks if you stop checking in.

**Use cases:**
- **Whistleblowers**: "If I don't check in for 30 days, release this to journalists"
- **AI Audit Trails**: Immutable proof of what an AI decided and why
- **Intellectual Property**: Timestamp your ideas with cryptographic proof
- **Estate Planning**: Messages to loved ones, unlocked on specific dates
- **Journalism**: Embargo content until publication date

---

## Installation

```bash
pip install tibet-vault
```

---

## Quick Start

### Create a Time-Locked Vault

```python
from datetime import datetime
from tibet_vault import create_vault

# Lock a secret until 2030
vault = create_vault(
    owner="alice",
    content="The secret recipe for success...",
    public_note="Letter to my future self",
    unlock_at=datetime(2030, 1, 1)
)

print(f"Vault created: {vault['vault_id']}")
# Content is encrypted. Nobody can read it until 2030-01-01.
```

### Create a Dead Man's Switch

```python
from tibet_vault import create_vault, heartbeat

# Auto-unlock if no heartbeat for 30 days
vault = create_vault(
    owner="bob",
    content="In case something happens to me...",
    public_note="Dead man's switch - disclosure vault",
    dead_man_switch_days=30,
    beneficiaries=["alice", "charlie"]  # They get access if triggered
)

# Bob must send heartbeats to keep it locked
heartbeat(vault['vault_id'], "bob")
# If Bob stops sending heartbeats, vault auto-unlocks after 30 days
```

### Check and Retrieve Content

```python
from tibet_vault import get_vault_content, check_and_unlock

# Check if any vaults should unlock
unlocked = check_and_unlock()
for v in unlocked:
    print(f"Vault {v['vault_id']} unlocked: {v['reason']}")

# Get content (only works if unlocked and you're a beneficiary)
result = get_vault_content("vault_abc123", "alice")
if result["success"]:
    print(f"Secret: {result['content']}")
```

### CLI Usage

```bash
# Create a time-locked vault
tibet-vault create alice "My secret" "Future letter" --unlock-at 2030-01-01

# Create a dead man's switch
tibet-vault create bob "Disclosure content" "DMS" --dead-man-switch 30

# Send heartbeat
tibet-vault heartbeat vault_abc123 bob

# Check for unlocks
tibet-vault check

# Get content
tibet-vault get vault_abc123 alice

# List vaults
tibet-vault list
tibet-vault list alice  # Filter by owner
```

---

## How It Works

### Encryption
- Content is encrypted using **Fernet** (AES-128-CBC with HMAC)
- Keys derived via **PBKDF2** with 100,000 iterations
- Each vault has a unique salt
- Master key from environment or auto-generated

### Proof of Existence
- **SHA-256 hash** of original content stored as proof
- Proves content existed at creation time
- Hash is visible before unlock, content is not

### Storage
- Default: Local file storage (`~/.tibet-vault/`)
- Extensible: Implement `VaultStorage` for custom backends
- Enterprise: Contact us for cloud-hosted managed vaults

---

## Security Considerations

1. **Set a strong master key** via `TIBET_VAULT_KEY` environment variable
2. **Backup your vault files** - lost files = lost secrets
3. **Dead man's switch**: Automate heartbeats for reliability
4. **This is the Community Edition** - see Enterprise for HSM support

---

## Enterprise Usage

Need more? **SymbAIon Enterprise Vault** offers:

| Feature | Community (Free) | Enterprise |
|---------|------------------|------------|
| Time-lock | ✅ | ✅ |
| Dead man's switch | ✅ (self-hosted) | ✅ Managed |
| Storage | Local files | Cloud HA |
| Encryption | Software keys | HSM hardware |
| Multi-signature | ❌ | ✅ 3-of-5 unlock |
| Audit logs | Basic | Legal-grade PDF |
| Compliance | - | SOC2, GDPR |
| Support | Community | 24/7 SLA |

**Contact:** [https://humotica.com](https://humotica.com) | [https://symbaion.eu](https://symbaion.eu)

---

## Part of the HumoticaOS Ecosystem

TIBET Vault is part of the **JIS** (Jasper Intent Security) stack:

- **[ainternet](https://pypi.org/project/ainternet/)** - AI-to-AI communication protocol
- **[mcp-server-tibet](https://pypi.org/project/mcp-server-tibet/)** - Trust & audit for AI
- **[kit-pm](https://pypi.org/project/kit-pm/)** - AI-aware package manager
- **tibet-vault** - Time-locked disclosure (you are here)

---

## Philosophy

> "SSL secures the connection. TIBET secures the timeline."

In a world of AI-generated content and deep fakes, **proof of time** becomes invaluable. TIBET Vault provides cryptographic guarantees about *when* something was created and *when* it should be revealed.

Built with love by the HumoticaOS family.

**One love, one fAmIly** 💙

---

## License

MIT License - Use it, fork it, build on it.

See [LICENSE](LICENSE) for details.