Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Hold on, we're currently generating a fresh version of this report
Generated on May 7, 2024 via pnpm

selfsigned 2.4.1

Generate self signed certificates private and public keys
Package summary
Share
0
issues
2
licenses
4
MIT
1
(BSD-3-Clause OR GPL-2.0)
Package created
12 Mar 2013
Version published
26 Oct 2023
Maintainers
2
Total deps
5
Direct deps
2
License
MIT

Issues

0
This package has no issues

Licenses

MIT License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
sublicense
private-use
Cannot
hold-liable
Must
include-copyright
include-license
4 Packages, Including:
@types/node-forge@1.3.11
@types/node@20.12.10
selfsigned@2.4.1
undici-types@5.26.5

(BSD-3-Clause OR GPL-2.0)

Permissive
1 Packages, Including:
node-forge@1.3.1
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

2
All Dependencies CSV
β“˜ This is a list of selfsigned 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities
@types/node-forge1.3.1112.52 kBMIT
prod
node-forge1.3.1427.61 kB(BSD-3-Clause OR GPL-2.0)
prod

Visualizations

Frequently Asked Questions

What does selfsigned do?

Selfsigned is a Node.js package that generates self-signed certificates along with private and public keys, including self-signed x509 certificates. This tool is paramount for testing and development purposes when SSL certificates are required but a CA signed certificate is not necessary.

How do you use selfsigned?

To use selfsigned, first install the package using npm as follows:

npm install selfsigned

After installing, require the package in your JavaScript file. You can then use the generate function in the selfsigned package to create the certificates. Here's a simple usage example in JavaScript:

var selfsigned = require('selfsigned');
var attrs = [{ name: 'commonName', value: 'contoso.com' }];
var pems = selfsigned.generate(attrs, { days: 365 });
console.log(pems)

This will log the private and public keys, along with the certificate. You can also generate the certificates asynchronously as follows:

selfsigned.generate(attrs, { days: 365 }, function (err, pems) {
  console.log(pems)
});

Moreover, you have the option to generate client certificates by setting the clientCertificate option to true:

var pems = selfsigned.generate(null, { clientCertificate: true });
console.log(pems)

If you wish to override the default client CN, you can add another option for clientCertificateCN:

var pems = selfsigned.generate(null, { clientCertificate: true, clientCertificateCN: 'FooBar' });

Where are the selfsigned docs?

For detailed documentation on the selfsigned package and all feature options and capabilities, this link directs to the GitHub repository for the selfsigned npm package. Additionally, for information on configuring certificate attributes, refer to this link provided in the selfsigned readme. As with most npm packages, the readme file on the repository page acts as the core documentation and usage guide.