Options
All
  • Public
  • Public/Protected
  • All
Menu

Key object contains RSA private and public key pair.

This class also offers convinience methods for converting between file formats. (wrappers for node-forge and nodejs crypto modules)

Hierarchy

  • Key

Index

Constructors

constructor

  • new Key(key: string, cert: string): Key
  • Parameters

    • key: string
    • cert: string

    Returns Key

Properties

certificate

certificate: Certificate

privateKey

privateKey: string

Methods

expires

  • expires(): Date
  • Return certificate expiration date

    Returns Date

getBase64Certificate

  • getBase64Certificate(): string

getCertificate

  • getCertificate(): string
  • Get PEM encoded certificate

    Returns string

getPrivateKey

  • getPrivateKey(): string
  • Get PEM encoded private key

    Returns string

isAboutToExpire

  • isAboutToExpire(): boolean
  • Return true if certificate is about to expire (less than a month remaining).

    Returns boolean

Static generateKey

  • generateKey(): Promise<any>
  • Generate new rsa private key.

    Returns Promise<any>

Legend

  • Module
  • Object literal
  • Variable
  • Function
  • Function with type parameter
  • Index signature
  • Type alias
  • Enumeration
  • Enumeration member
  • Property
  • Method
  • Interface
  • Interface with type parameter
  • Constructor
  • Property
  • Method
  • Index signature
  • Class
  • Class with type parameter
  • Constructor
  • Property
  • Method
  • Accessor
  • Index signature
  • Inherited constructor
  • Inherited property
  • Inherited method
  • Inherited accessor
  • Protected property
  • Protected method
  • Protected accessor
  • Private property
  • Private method
  • Private accessor
  • Static property
  • Static method

Generated using TypeDoc