Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

x509

Package Overview
Dependencies
Maintainers
2
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

x509 - npm Package Compare versions

Comparing version 0.2.0 to 0.2.1

2

package.json
{
"name": "x509",
"version": "0.2.0",
"version": "0.2.1",
"description": "Simple X509 certificate parser.",

@@ -5,0 +5,0 @@ "author": "Colton Baker",

node-x509
=========
[![Build Status](https://travis-ci.org/Southern/node-x509.svg)](https://travis-ci.org/Southern/node-x509)
Simple X509 certificate parser.
*support Node.js 4.0.0*
Simple X509 certificate parser.
## Installation

@@ -22,5 +23,4 @@

```js
var x509 = require('x509');
var issuer = x509.getIssuer(__dirname + '/certs/your.crt');
const x509 = require('x509');
const issuer = x509.getIssuer(__dirname + '/certs/your.crt');
```

@@ -30,6 +30,5 @@

```js
var fs = require('fs'),
x509 = require('x509');
var issuer = x509.getIssuer(fs.readFileSync('./certs/your.crt').toString());
const fs = require('fs');
const x509 = require('x509');
const issuer = x509.getIssuer(fs.readFileSync('./certs/your.crt').toString());
```

@@ -41,3 +40,2 @@

#### x509.getAltNames(`cert`)

@@ -47,5 +45,4 @@ Parse certificate with `x509.parseCert` and return the alternate names.

```js
var x509 = require('x509');
var altNames = x509.getAltNames(__dirname + '/certs/nodejitsu.com.crt');
const x509 = require('x509');
const altNames = x509.getAltNames(__dirname + '/certs/nodejitsu.com.crt');
/*

@@ -60,5 +57,4 @@ altNames = [ '*.nodejitsu.com', 'nodejitsu.com' ]

```js
var x509 = require('x509');
var issuer = x509.getIssuer(__dirname + '/certs/nodejitsu.com.crt');
const x509 = require('x509');
const issuer = x509.getIssuer(__dirname + '/certs/nodejitsu.com.crt');
/*

@@ -77,5 +73,4 @@ issuer = { countryName: 'GB',

```js
var x509 = require('x509');
var subject = x509.getSubject(__dirname + '/certs/nodejitsu.com.crt');
const x509 = require('x509');
const subject = x509.getSubject(__dirname + '/certs/nodejitsu.com.crt');
/*

@@ -97,5 +92,4 @@ subject = { countryName: 'US',

```js
var x509 = require('x509');
var cert = x509.parseCert(__dirname + '/certs/nodejitsu.com.crt');
const x509 = require('x509');
const cert = x509.parseCert(__dirname + '/certs/nodejitsu.com.crt');
/*

@@ -132,5 +126,5 @@ cert = { subject:

```js
var x509 = require('x509'),
cert = x509.parseCert('yourcert.crt'),
date = new Date();
const x509 = require('x509'),
const cert = x509.parseCert('yourcert.crt'),
const date = new Date();

@@ -137,0 +131,0 @@ if (cert.notBefore > date) {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc