Skip to content

Instantly share code, notes, and snippets.

@n-shinya
Last active December 22, 2015 17:39
Show Gist options
  • Save n-shinya/6507383 to your computer and use it in GitHub Desktop.
Save n-shinya/6507383 to your computer and use it in GitHub Desktop.
// PEM形式のファイルから証明書の情報を取得
var pem = require('pem');
var fs = require('fs');
fs.readFile('test.pem', 'utf-8', function (err, data) {
pem.readCertificateInfo(data, function (err, data) {
console.log(data);
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment