Multi-DID identity management with Ed25519 cryptography for the ourochronos ecosystem
Reason this release was yanked:
Not ready for use
Project description
our-identity
Decentralized multi-DID identity management with Ed25519 cryptography for the ourochronos ecosystem.
Overview
our-identity implements a decentralized identity system where each node has its own DID (Decentralized Identifier) backed by an Ed25519 keypair. Multiple DIDs can be grouped into an IdentityCluster to represent a single user across devices or contexts. There is no master key — compromising one node doesn't endanger others. Linking is proven through bilateral signatures (both parties must sign).
Install
pip install our-identity
Requires cryptography>=42.0 for Ed25519 operations.
Usage
from our_identity import DIDManager
mgr = DIDManager()
# Create node identities
laptop, laptop_key = mgr.create_node_did(label="laptop")
phone, phone_key = mgr.create_node_did(label="phone")
# Link them (requires both private keys — bilateral proof)
proof = mgr.link_dids(laptop.did, laptop_key, phone.did, phone_key)
# Verify the link proof offline
assert mgr.verify_link_proof(proof)
# Resolve identity from any member DID
cluster = mgr.resolve_identity(laptop.did)
assert len(cluster.nodes) == 2
# Revoke a compromised node (others unaffected)
mgr.revoke_did(phone.did, reason="key compromised")
cluster = mgr.resolve_identity(laptop.did)
assert len(cluster.nodes) == 1 # laptop still active
Cluster Merging
# Two separate clusters merge automatically when cross-linked
mgr.link_dids(a.did, a_key, b.did, b_key) # cluster 1
mgr.link_dids(c.did, c_key, d.did, d_key) # cluster 2
mgr.link_dids(b.did, b_key, c.did, c_key) # merges into one cluster
Pluggable Storage
# Default: in-memory (for tests)
mgr = DIDManager()
# Custom backend: implement the DIDStore protocol
mgr = DIDManager(store=MyPostgresStore())
API
| Class | Description |
|---|---|
DIDManager |
High-level service: create, link, revoke, resolve, verify |
DIDNode |
A single node identity with Ed25519 keypair and status |
IdentityCluster |
Group of linked DIDs representing one conceptual identity |
LinkProof |
Bilateral cryptographic proof that two DIDs belong together |
DIDStore |
Protocol for pluggable storage backends |
InMemoryDIDStore |
Default in-memory implementation |
DIDStatus |
Enum: ACTIVE, REVOKED, SUSPENDED |
Key Properties
- DIDs are deterministic: derived from Ed25519 public key fingerprint (
did:valence:<fingerprint>) - Bilateral linking: both parties must sign to establish a link
- Revocation isolation: revoking one DID leaves other cluster members unaffected
- Offline verification: link proofs can be verified without an external authority
Development
# Install with dev dependencies
make dev
# Run linters
make lint
# Run tests
make test
# Run tests with coverage
make test-cov
# Auto-format
make format
State Ownership
Owns DID nodes, identity clusters, and link proofs. Default storage is in-memory; persistent backends store to the injected DIDStore implementation.
Part of Valence
This brick is part of the Valence knowledge substrate. See our-infra for ourochronos conventions.
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file our_identity-0.1.0.tar.gz.
File metadata
- Download URL: our_identity-0.1.0.tar.gz
- Upload date:
- Size: 17.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8dc6e2d306622f5946bcdd82bb37ec963d36011e06cf4735c2d82f6e415143c8
|
|
| MD5 |
4458aef657cf27310c5ea8d028a2c66c
|
|
| BLAKE2b-256 |
f41578c39aec5ac02f11cebeb2501f6bd8f93d45b188d410a118c6048ba7d8d7
|
File details
Details for the file our_identity-0.1.0-py3-none-any.whl.
File metadata
- Download URL: our_identity-0.1.0-py3-none-any.whl
- Upload date:
- Size: 13.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
00b940524a397deb3a579dfbe56dcf21ad5a64a63351fcea51c73a8248b45de4
|
|
| MD5 |
083009ff8b0cabc9091d5dc73d3bdd2a
|
|
| BLAKE2b-256 |
86be235ffb6064350f22fea8939f9813d09f7ed8fc0b37b4e8cc035eca304a6e
|