Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.manthan.systems/llms.txt

Use this file to discover all available pages before exploring further.

Most governance and compliance tools are SaaS platforms. Your decisions go to their servers. Your data lives in their database. Your audit trail depends on their uptime, their pricing, and their continued existence as a business. Parmana is different. It is an open-source SDK - infrastructure you deploy in your own environment, with your own keys, your own store, and your own database. Nothing leaves your system.

The principle

The governance guarantee - deterministic decisions, Ed25519 signatures, replay protection, portable verification - does not require a centralized service. It requires correct cryptography and deterministic rule evaluation. Both run entirely in your process. Parmana provides the protocol. You bring the infrastructure.

What you bring

Signing keys

Parmana never generates or stores your private keys. You provide a Signer implementation. The simplest option is LocalSigner with an Ed25519 keypair you generate yourself. But the Signer interface is a single method - implement it against any key management system:
interface Signer {
  sign(payload: string): string | Promise<string>;
}
Key management systemHow to integrate
Ed25519 local keypairnew LocalSigner(privateKeyPem) - built-in
AWS KMSImplement Signer using KMSClient.SignCommand
HashiCorp Vault TransitImplement Signer using /v1/transit/sign/{key}
Azure Key VaultImplement Signer using CryptographyClient.sign
Google Cloud KMSImplement Signer using KeyManagementServiceClient.asymmetricSign
Hardware Security ModuleImplement Signer against your HSM’s signing API
The cryptographic guarantee is preserved regardless of which backend signs. The attestation is portable - any party with the corresponding public key can verify it.

Replay store

Replay protection requires persistent state - a record of which execution fingerprints have been consumed. You choose the backend by implementing ReplayStore:
interface ReplayStore {
  reserve(fingerprint: string): Promise<void>;   // atomic claim - throw if already exists
  confirm(fingerprint: string): Promise<void>;   // mark as confirmed
  hasExecuted(fingerprint: string): Promise<boolean>;
  markExecuted(fingerprint: string): Promise<void>;
}
BackendBuilt-inNotes
In-process memoryMemoryReplayStoreDev only - lost on restart
RedisRedisReplayStoreBuilt-in production option
DynamoDBImplement ReplayStoreAtomic via ConditionExpression
PostgreSQLImplement ReplayStoreAtomic via INSERT ... ON CONFLICT DO NOTHING
CustomImplement ReplayStoreAny store with conditional write semantics
The only requirement: reserve() must be atomic and reject if the fingerprint already exists. Anything with a conditional write primitive works.

Audit database

Attestations are plain JSON. They are self-verifying - you don’t need Parmana’s database to verify them later. Store them anywhere that fits your compliance requirements:
StorageNotes
PostgreSQL via @parmanasystems/audit-dbBuilt-in - structured schema, query support
Amazon S3Store as JSON objects, query with Athena
MongoDBStore as documents, query by field
Your existing audit systemAttestations are plain JSON - import them anywhere
Your SIEM platformForward attestation events to your security tooling
The only requirement for long-term auditability: keep the public key alongside the attestations. You need it to verify them. The governance runtime is not required - just the key.

Framework

Parmana has no framework dependency. executeFromSignals is a plain async function. Use it in:
  • Express
  • Fastify
  • Next.js API routes
  • Hono
  • AWS Lambda
  • Google Cloud Functions
  • Any Node.js runtime

Policy storage

Policies are JSON files. Deploy them however you deploy code:
StorageNotes
Git repositoryVersion-controlled alongside source code
Container imageBundle policies into your Docker image at build time
S3 bucketLoad policies from S3 at startup
Local filesystemSimplest option for single-node deployments
The policy compiler produces content-addressed bundles - the same policy content always produces the same bundle hash, regardless of where policies are stored or how they are delivered.

Why this matters

For regulated industries

Financial services, healthcare, and government organizations often cannot send decision data to third-party SaaS platforms. Data sovereignty requirements, security review processes, and compliance frameworks make external dependencies on governance-critical paths unacceptable. With Parmana:
  • Decisions are evaluated in your process, not a remote server
  • Keys never leave your HSM or key management system
  • Attestations are stored in your database under your retention policies
  • The compliance boundary is entirely within your control

For enterprise security teams

Your security team does not need to approve a new SaaS vendor, review a third-party’s SOC 2, or assess a new network dependency. Parmana is a library - it has the same security surface as any npm package, auditable in the same way as any open-source dependency.

For air-gapped deployments

Parmana makes no outbound network calls. It runs in any environment, including air-gapped networks with no internet access. The governance runtime requires only your policy files, your signing key, and a replay store - all of which can be fully on-premises.

For long-term auditability

Attestations signed with your keys remain verifiable as long as you keep the public key - decades later, with no dependency on Parmana Systems as a company, a service, or a product. The verification algorithm is Ed25519 over canonical JSON - a stable, standardized, widely supported specification.

The guarantee

You bring the infrastructure. Parmana brings the cryptographic guarantee. Regardless of which key management system signs the attestation, which replay store enforces single-use execution, or which database stores the audit trail - the output is always:
  • Deterministic - same inputs produce the same decision
  • Signed - Ed25519 over a canonical payload
  • Portable - verifiable by any party with the public key
  • Replay-protected - each fingerprint consumed exactly once
The governance property is in the cryptography and the protocol, not in the infrastructure. Infrastructure is yours to control.

See also