0.1.0 • Published 6 years ago

check-ssl-expiration v0.1.0

Weekly downloads
3
License
ISC
Repository
github
Last release
6 years ago

check-ssl-expiration

NPM package to check given domain's SSL/TLS certificate and return time left until expiration.

Install

npm install check-ssl-expiration --save

Usage

check-ssl-expiration(domain, unit, callback)

domain

www.example.com (Do not include https:// or path)

unit

years, months, weeks, days, hours, minutes, or seconds

Example

var cse = require('check-ssl-expiration');

cse('www.example.com', 'days', function(err, remaining) {
  if(err) {
    console.error(err);
  } else {
    console.log("remaining: "+remaining);
  }
});
// remaining: 837

cse('www.example.com', 'months', function(err, remaining) {
  if(err) {
    console.error(err);
  } else {
    console.log("remaining: "+remaining);
  }
});
// remaining: 27
0.1.0

6 years ago

0.0.2

8 years ago

0.0.1

8 years ago