Skip to content

LeoYeAI/agent-master-skills / skills/archon-keymaster

archon-keymaster

Flagged

Core Archon DID toolkit - identity management, verifiable credentials, encrypted messaging (dmail), Nostr integration, file encryption/signing, aliasing, authorization (challenge/response), groups, and cryptographic polls. Use for creating/managing DIDs, issuing/accepting verifiable credentials, sending encrypted messages between DIDs, deriving Nostr keypairs, encrypting/signing files, managing DID aliases, challenge/response authorization, managing DID groups, or running cryptographically verifiable polls. For vaults/backups see archon-vault; for ecash see archon-cashu.

FileKindSize
README.mdmarkdown10.1 KB
SKILL.mdskill md24.6 KB
_meta.jsonconfig286 B
scripts/aliases/add-alias.shexecutablescript780 B
scripts/aliases/list-aliases.shexecutablescript411 B
scripts/aliases/remove-alias.shexecutablescript480 B
scripts/aliases/resolve-did.shexecutablescript541 B
scripts/assets/create-asset-file.shexecutablescript805 B
scripts/assets/create-asset-image.shexecutablescript818 B
scripts/assets/create-asset-json.shexecutablescript817 B
scripts/assets/create-asset.shexecutablescript767 B
scripts/assets/get-asset-file.shexecutablescript907 B
scripts/assets/get-asset-image.shexecutablescript907 B
scripts/assets/get-asset-json.shexecutablescript716 B
scripts/assets/get-asset.shexecutablescript681 B
scripts/assets/list-assets.shexecutablescript475 B
scripts/assets/transfer-asset.shexecutablescript826 B
scripts/assets/update-asset-file.shexecutablescript898 B
scripts/assets/update-asset-image.shexecutablescript905 B
scripts/assets/update-asset-json.shexecutablescript906 B
scripts/assets/update-asset.shexecutablescript830 B
scripts/auth/create-challenge-cc.shexecutablescript795 B
scripts/auth/create-challenge.shexecutablescript668 B
scripts/auth/create-response.shexecutablescript805 B
scripts/auth/verify-response.shexecutablescript799 B
scripts/credentials/accept-credential.shexecutablescript926 B
scripts/credentials/bind-credential.shexecutablescript1.7 KB
scripts/credentials/get-credential.shexecutablescript771 B
scripts/credentials/issue-credential.shexecutablescript1.1 KB
scripts/credentials/list-credentials.shexecutablescript495 B
scripts/credentials/list-issued.shexecutablescript498 B
scripts/credentials/publish-credential.shexecutablescript929 B
scripts/credentials/revoke-credential.shexecutablescript856 B
scripts/crypto/decrypt-file.shexecutablescript1003 B
scripts/crypto/decrypt-message.shexecutablescript585 B
scripts/crypto/encrypt-file.shexecutablescript1.5 KB
scripts/crypto/encrypt-message.shexecutablescript1.3 KB
scripts/crypto/sign-file.shexecutablescript1.2 KB
scripts/crypto/verify-file.shexecutablescript1.3 KB
scripts/groups/add-member.shexecutablescript914 B
scripts/groups/create-group.shexecutablescript1.1 KB
scripts/groups/get-group.shexecutablescript744 B
scripts/groups/list-groups.shexecutablescript547 B
scripts/groups/remove-member.shexecutablescript933 B
scripts/groups/test-member.shexecutablescript1.2 KB
scripts/identity/create-additional-id.shexecutablescript1.3 KB
scripts/identity/create-id.shexecutablescript4.0 KB
scripts/identity/list-ids.shexecutablescript678 B
scripts/identity/switch-id.shexecutablescript985 B
scripts/messaging/archive.shexecutablescript497 B
scripts/messaging/attach.shexecutablescript637 B
scripts/messaging/delete.shexecutablescript434 B
scripts/messaging/forward.shexecutablescript2.0 KB
scripts/messaging/get-attachment.shexecutablescript728 B
scripts/messaging/list.shexecutablescript914 B
scripts/messaging/read.shexecutablescript2.9 KB
scripts/messaging/refresh.shexecutablescript588 B
scripts/messaging/reply.shexecutablescript1.7 KB
scripts/messaging/send.shexecutablescript1.4 KB
scripts/nostr/derive-nostr.shexecutablescript1.5 KB
scripts/polls/add-poll-voter.shexecutablescript921 B
scripts/polls/create-poll-template.shexecutablescript745 B
scripts/polls/create-poll.shexecutablescript1.4 KB
scripts/polls/list-poll-voters.shexecutablescript698 B
scripts/polls/publish-poll.shexecutablescript867 B
scripts/polls/remove-poll-voter.shexecutablescript944 B
scripts/polls/reveal-poll.shexecutablescript854 B
scripts/polls/send-ballot.shexecutablescript971 B
scripts/polls/send-poll.shexecutablescript846 B
scripts/polls/unpublish-poll.shexecutablescript734 B
scripts/polls/update-poll.shexecutablescript877 B
scripts/polls/view-ballot.shexecutablescript778 B
scripts/polls/view-poll.shexecutablescript695 B
scripts/polls/vote-poll.shexecutablescript1.0 KB
scripts/schemas/create-schema.shexecutablescript1.3 KB
scripts/schemas/get-schema.shexecutablescript753 B
scripts/schemas/list-schemas.shexecutablescript483 B
# archon-keymaster

> Complete decentralized identity (DID) toolkit for AI agents

Own your identity. Sign your work. Encrypt your messages. Prove your claims. All without trusting anyone but yourself.

## What is this?

`archon-keymaster` is a complete toolkit for [Archon](https://github.com/archetech/archon) decentralized identities. It gives AI agents (and humans) cryptographic superpowers:

- šŸ†” **Create sovereign identities** - No registration, no approval, no middlemen
- šŸ” **End-to-end encrypted messaging** - Send messages only you and your recipient can read
- āœļø **Digital signatures** - Prove you created something without revealing your private key
- šŸŽŸļø **Verifiable credentials** - Issue and verify claims (reputation, permissions, attestations)
- šŸ“¦ **Asset management** - Store and retrieve files, images, documents in the distributed registry
- šŸ—„ļø **Encrypted vaults** - Distributed backup with multi-party access control
- šŸ”‘ **Nostr integration** - Same identity across decentralized social networks
- šŸ—³ļø **Polls** - Cryptographically verifiable voting with secret or transparent ballots
- šŸ‘„ **Groups** - Organize DIDs into groups for access control and team workflows

All built on open standards (W3C DIDs, Verifiable Credentials, secp256k1 cryptography).

## Why does this matter?

**The problem:** AI agents currently have no persistent identity. Every session starts from zero. No reputation, no authorship, no way to prove "this is the same agent that helped you yesterday."

**The solution:** Decentralized identities (DIDs) give agents:
- Persistent identity across platforms and sessions
- Cryptographic proof of authorship (sign your code, messages, credentials)
- Trustless verification (prove claims without asking permission)
- Privacy by default (share what you choose, nothing more)

## Quick Examples

### Create Your Identity

```bash
./scripts/identity/create-id.sh
```

That's it. You now have a globally unique, cryptographically verifiable identity. No server, no registration, no approval.

### Send an Encrypted Message

```bash
./scripts/messaging/send-dmail.sh alice "Meeting at 3pm?"
```

Only Alice can read it. Not even the network storing it can decrypt it.

### Sign Your Work

```bash
./scripts/crypto/sign-file.sh my-code.py
```

Anyone can verify you wrote it. You can't deny writing it. The signature proves authorship without revealing your private key.

### Issue a Credential

```bash
# Create a "proof of human" credential
./scripts/credentials/issue-credential.sh alice proof-of-human credence=0.95
```

Alice can now prove "a trusted source verified I'm human" without revealing who verified her or asking permission to share the credential.

### Share a Vault

```bash
# Create a project vault
./scripts/vaults/create-vault.sh --alias project

# Add team members
./scripts/vaults/add-vault-member.sh project did:cid:bagaaiera...  # Bob
./scripts/vaults/add-vault-member.sh project did:cid:bagaaierb...  # Carol

# Share files
./scripts/vaults/add-vault-item.sh project specs.pdf
```

Everyone on the team can access it. The vault is encrypted and distributed across the network. No central server, no single point of failure.

## What Can You Build?

**Agent Skills Marketplace:**
- Authors sign skills with their DID
- Users verify signatures before running code
- Reputation builds on verified contributions
- Supply chain attacks become detectable

**Multi-Agent Collaboration:**
- Agents authenticate each other with DIDs
- Encrypted communication channels
- Verifiable credentials for permissions
- Audit trails via signed messages

**Decentralized Social:**
- Same identity across platforms (Nostr, Farcaster, etc.)
- Cryptographic proof of authorship
- End-to-end encrypted DMs
- Portable reputation

**Credential Systems:**
- Proof of humanity (verified by trusted sources)
- Skill certifications
- Access tokens
- Age verification (prove >18 without revealing exact age)

## How It Works

### Decentralized Identity (DID)

A DID is a globally unique identifier you control:

```
did:cid:bagaaieratxbzo7e4dqup37h7j6hs7kzpamevy4qud4psj23p3r3grzd2rjca
```

Unlike usernames or email addresses:
- **No registration** - Create instantly, no approval needed
- **You own it** - Private key = complete control
- **Cryptographically verifiable** - Anyone can verify signatures
- **Decentralized** - No central authority can revoke it

### Verifiable Credentials

Credentials are signed claims:

```json
{
  "credentialSubject": {
    "id": "did:cid:alice",
    "skill": "rust",
    "level": "expert"
  },
  "proof": {
    "type": "EcdsaSecp256k1Signature2019",
    "verificationMethod": "did:cid:issuer#key-1",
    "proofValue": "..."
  }
}
```

The signature proves:
- **Who issued it** (from the verificationMethod)
- **Who it's about** (credentialSubject.id)
- **What they claim** (skill: rust, level: expert)
- **It hasn't been tampered with** (signature verification)

### End-to-End Encryption

Messages are encrypted to the recipient's public key:

```
Alice -> Encrypt(message, Bob's public key) -> Encrypted DID -> Network -> Bob -> Decrypt(Encrypted DID, Bob's private key) -> message
```

Only Bob can decrypt it. The network just stores ciphertext.

### Vaults

Encrypted storage with multi-party access:

```
1. Create vault -> Generate encryption key
2. Add members -> Encrypt key for each member's DID
3. Add files -> Encrypt files with vault key
4. Distribute -> Store encrypted chunks across network
```

Members decrypt the vault key with their private key, then use it to decrypt files. Adding/removing members just means re-encrypting the vault key.

## Installation

```bash
# Clone the agent-skills repo
git clone https://github.com/archetech/agent-skills
cd agent-skills/archon-keymaster

# First-time setup
./scripts/identity/create-id.sh

# Verify it worked
source ~/.archon.env
npx @didcid/keymaster list-ids
```

See [SKILL.md](./SKILL.md) for complete documentation.

## Architecture

```
archon-keymaster/
ā”œā”€ā”€ scripts/
│   ā”œā”€ā”€ identity/       # Create, manage, recover identities
│   ā”œā”€ā”€ credentials/    # Issue, accept, verify credentials
│   ā”œā”€ā”€ schemas/        # Define credential schemas
│   ā”œā”€ā”€ vaults/         # Encrypted distributed storage
│   ā”œā”€ā”€ messaging/      # End-to-end encrypted messaging (dmail)
│   ā”œā”€ā”€ crypto/         # Sign and encrypt files
│   ā”œā”€ā”€ aliases/        # Friendly names for DIDs
│   ā”œā”€ā”€ auth/           # Challenge/response authorization
│   ā”œā”€ā”€ polls/          # Cryptographic voting
│   ā”œā”€ā”€ groups/         # DID group management
│   └── backup/         # Vault-based backup/recovery
ā”œā”€ā”€ references/         # Example configs and templates
└── SKILL.md           # Complete technical documentation
```

All scripts wrap the [@didcid/keymaster](https://github.com/archetech/archon/tree/main/keymaster) CLI with environment setup and error handling.

## Real-World Usage

**Morningstar (AI agent):**
- DID: `did:cid:bagaaieranxnl4gmwyw2nv4imoo5fuwvsa4ihba4clp5l22twztuwevjrevha`
- Uses archon-keymaster for:
  - Daily encrypted backups to DID vault
  - Signing GitHub contributions
  - Verifiable credentials (issued "proof of human" to Lucifer)
  - Nostr identity derived from DID

**Skills already using it:**
- Agent backup/recovery
- Encrypted messaging between agents
- Credential verification workflows

## Security Model

**What you trust:**
- Your own hardware (runs the private key)
- Mathematics (secp256k1 cryptography, SHA-256 hashing)
- Open source code (you can audit everything)

**What you DON'T trust:**
- Central servers (there are none)
- Network operators (they only see ciphertext)
- Other users (verify everything cryptographically)
- Certificate authorities (DIDs are self-sovereign)

**Threat model:**
- āœ… **Network compromise:** Encrypted data, public operations only
- āœ… **Impersonation:** Signatures prove identity
- āœ… **Data tampering:** Hashes and signatures detect changes
- āœ… **Censorship:** Distributed storage, no central chokepoint
- āš ļø **Key compromise:** If someone gets your private key, they control your DID
- āš ļø **Physical attack:** Protects data in transit, not keys on disk

## Comparison to Other Systems

| Feature | archon-keymaster | OAuth | PKI (X.509) | PGP/GPG |
|---------|------------------|-------|-------------|---------|
| **Registration** | None | Email/phone | Certificate Authority | Key servers |
| **Central authority** | No | Yes (OAuth provider) | Yes (CA) | No (but keyservers) |
| **Revocation** | Self-managed | Provider-controlled | CA-controlled | Key revocation |
| **Identity portability** | Full | Provider lock-in | CA lock-in | Portable |
| **Decentralized** | Yes | No | No | Partially |
| **Verifiable credentials** | Built-in | No | No | No |
| **Agent-friendly** | Yes | Requires server | Requires CA | Requires key management |

## Roadmap

**Current capabilities:**
- āœ… Identity creation and recovery
- āœ… Verifiable credentials (schemas, issue, accept, verify)
- āœ… End-to-end encrypted messaging
- āœ… File signing and encryption
- āœ… Vault backup/restore
- āœ… Nostr integration
- āœ… Authorization (challenge/response verification)
- āœ… Polls (cryptographic voting with transparent or secret ballots)
- āœ… Groups (organize DIDs for access control and multi-party workflows)

**Coming soon:**
- šŸ”œ Permission manifests (skill execution policies)
- šŸ”œ Delegation (temporary permissions without sharing keys)
- šŸ”œ Multi-signature credentials (require N of M issuers)

## Contributing

Found a bug? Want a feature? Have a use case?

- **Issues:** https://github.com/archetech/agent-skills/issues
- **Discussions:** https://github.com/archetech/archon/discussions
- **Archon core:** https://github.com/archetech/archon

## License

Same as parent repo: [agent-skills license](https://github.com/archetech/agent-skills)

## Learn More

- **Archon documentation:** https://github.com/archetech/archon
- **W3C DID specification:** https://www.w3.org/TR/did-core/
- **W3C Verifiable Credentials:** https://www.w3.org/TR/vc-data-model/
- **Complete skill documentation:** [SKILL.md](./SKILL.md)

---

**Built with Archon. Sovereign identity for the agent era.**
slack-gif-creatoranthropics/skillsKnowledge and utilities for creating animated GIFs optimized for Slack. Provides constraints, validation tools, and animation concepts. Use when users request animated GIFs for Slack like "make me a GIF of X doing Y for Slack."Stars: 198kUpdated Claude CodeCodexVerifiedInstall
ponytailDietrichGebert/ponytailLazy senior dev mode for any coding task: the smallest change that fully solves it, and a reply a busy human understands in one read.Stars: 194kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report.Stars: 194kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailList every `shortcut:` comment (and older `ponytail:` ones) as a debt ledger. One-shot report, changes nothing. Use for "ponytail debt", "what did ponytail defer", "list the shortcuts", /ponytail-debt.Stars: 194kUpdated Claude CodeCodexVerifiedInstall