npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@parmanasystems/crypto

v1.98.56

Published

Deterministic cryptographic infrastructure for canonical payload signing, trust-root continuity, reproducible verification, and independently verifiable governance trust chains.

Downloads

762

Readme

@parmanasystems/crypto

Ed25519 signing and verification utilities for Parmana governance artifacts. Provides key loading from PEM files, signature persistence, manifest signing, and bundle signing. All payloads are first canonicalized via @parmanasystems/canonical before signing so signatures are byte-stable across platforms.


Public API

/**
 * Load an Ed25519 private key from a PEM file path (PKCS8 format).
 * Returns a Node.js KeyObject.
 */
function loadPrivateKey(path: string): crypto.KeyObject

/**
 * Load an Ed25519 public key from a PEM file path (SPKI format).
 * Returns a Node.js KeyObject.
 */
function loadPublicKey(path: string): crypto.KeyObject

/**
 * Sign a governance manifest object. The manifest is canonicalized before signing.
 * Returns the base64-encoded Ed25519 signature string.
 */
function signManifest(manifest: unknown, privateKey: crypto.KeyObject): string

/**
 * Verify a base64-encoded Ed25519 signature against a payload string.
 * Returns true if valid, false otherwise.
 */
function verifySignature(payload: string, signature: string, publicKey: crypto.KeyObject | string): boolean

/**
 * Verify the signature of a governance manifest object.
 * Canonicalizes the manifest, then calls verifySignature.
 */
function verifyManifestSignature(
  manifest: unknown,
  signature: string,
  publicKey: crypto.KeyObject | string
): boolean

/**
 * Sign a policy bundle. Canonicalizes the bundle manifest and writes a .sig file.
 */
function signBundle(bundlePath: string, privateKey: crypto.KeyObject): Promise<void>

/** Write a base64 signature string to a file. */
function writeSignature(path: string, signature: string): void

/** Read a base64 signature string from a file. */
function readSignature(path: string): string

Environment variables

None. Key material is loaded by callers (e.g. @parmanasystems/signing) who pass key objects to these functions.


Package wiring

@parmanasystems/crypto depends on @parmanasystems/canonical for deterministic serialization before signing. It is used by the release pipeline scripts (scripts/release/sign-release-manifest.ts), @parmanasystems/core (which re-exports signBundle), and the build tooling. The server runtime uses @parmanasystems/signing for runtime key management, which wraps the lower-level crypto operations.