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 🙏

© 2024 – Pkg Stats / Ryan Hefner

@trust/webcrypto

v0.9.2

Published

WebCrypto API for Node.js

Downloads

48,994

Readme

W3C Web Cryptography API (@trust/webcrypto)

standard-readme compliant Build Status

W3C Web Cryptography API for Node.js

W3C's Web Cryptography API defines a standard interface for performing cryptographic operations in JavaScript, such as key generation, hashing, signing, and encryption. This package implements the API for Node.js, in order to support universal crypto-dependent code required by protocols such as JOSE and OpenID Connect.

Table of Contents

Security

TBD

Background

The purpose of this package is to enable development of universal JavaScript libraries that depend on the availability of cryptographic primitives in order to implement cryptographic protocols. The long term goal of the project is to encourage or provide a native, if not core Web Cryptography module.

Install

@trust/webcrypto requires recent versions of node and npm to run. For key generation operations, it also requires OpenSSL to be installed on the system.

$ npm install @trust/webcrypto --save

Usage

const crypto = require('@trust/webcrypto')

Develop

Install

$ git clone [email protected]:anvilresearch/webcrypto.git
$ cd webcrypto
$ npm install

Test

$ npm test

Supported Algorithms

| Algorithm name | encrypt | decrypt | sign | verify | digest | generateKey | deriveKey | deriveBits | importKey | exportKey | wrapKey | unwrapKey | |------------------|---|---|---|---|---|---|---|---|---|---|---|---| |RSASSA-PKCS1-v1_5 | | | ✔ | ✔ | | ✔ | | | ✔ | ✔ | | | |RSA-PSS | | | ✔ | ✔ | | ✔ | | | ✔ | ✔ | | | |RSA-OAEP | ✔ | ✔ | | | | ✔ | | | ✔ | ✔ | ✔ | ✔ | |ECDSA | | | ⚐ | ⚐ | | ⚐ | | | ✔ | ✔ | | | |EDDSA | | | ⚐ | ⚐ | | ⚐ | | | ✔ | ✔ | | | |ECDH | | | | | | _ | _ | _ | _ | _ | | | |AES-CTR | ⚐ | ⚐ | | | | ✔ | | | ✔ | ✔ | ✔ | ✔ | |AES-CBC | ✔ | ✔ | | | | ✔ | | | ✔ | ✔ | ✔ | ✔ | |AES-GCM | ✔ | ✔ | | | | ✔ | | | ✔ | ✔ | ✔ | ✔ | |AES-KW | | | | | | ✔ | | | ✔ | ✔ | ✔ | ✔ | |HMAC | | | ✔ | ✔ | | ✔ | | | ✔ | ✔ | | | |SHA-1 | | | | | ✔ | | | | | | | | |SHA-256 | | | | | ✔ | | | | | | | | |SHA-384 | | | | | ✔ | | | | | | | | |SHA-512 | | | | | ✔ | | | | | | | | |HKDF | | | | | | | _ | _ | _ | | | | |PBKDF2 | | | | | | | _ | _ | _ | | | |

Key:

Implemented _ Currently not implemented Partially implemented, only certain paramaters supported.

Partial Support

Only the following paramaters are supported for the corresponding algorithm.

| Algorithm name | Supported paramater | | -------------- | ------------------- | | ECDSA | K-256 (secp256k1), P-256, P-384, P-512 | | EDDSA | ed25519 | | AES-CTR | sha-1 |

API

See W3C Web Cryptography API specification and diafygi's webcrypto-examples.

Contribute

Issues

  • Please file issues :)
  • When writing a bug report, include relevant details such as platform, version, relevant data, and stack traces
  • Ensure to check for existing issues before opening new ones
  • Read the documentation before asking questions
  • It is strongly recommended to open an issue before hacking and submitting a PR
  • We reserve the right to close an issue for excessive bikeshedding

Pull requests

Policy

  • We're not presently accepting unsolicited pull requests
  • Create an issue to discuss proposed features before submitting a pull request
  • Create an issue to propose changes of code style or introduce new tooling
  • Ensure your work is harmonious with the overall direction of the project
  • Ensure your work does not duplicate existing effort
  • Keep the scope compact; avoid PRs with more than one feature or fix
  • Code review with maintainers is required before any merging of pull requests
  • New code must respect the style guide and overall architecture of the project
  • Be prepared to defend your work

Style guide

  • ES6
  • Standard JavaScript
  • jsdocs

Code reviews

  • required before merging PRs
  • reviewers MUST run and test the code under review

Collaborating

Weekly project meeting

  • Thursdays from 1:00 PM to 2:00 Eastern US time at [TBD]
  • Join remotely with Google Hangouts

Pair programming

  • Required for new contributors
  • Work directly with one or more members of the core development team

Code of conduct

Contributors

MIT License

Copyright (c) 2016 Anvil Research, Inc.