You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

40 lines
1.2 KiB

  1. // Copyright 2015 Joyent, Inc.
  2. var Key = require('./key');
  3. var Fingerprint = require('./fingerprint');
  4. var Signature = require('./signature');
  5. var PrivateKey = require('./private-key');
  6. var Certificate = require('./certificate');
  7. var Identity = require('./identity');
  8. var errs = require('./errors');
  9. module.exports = {
  10. /* top-level classes */
  11. Key: Key,
  12. parseKey: Key.parse,
  13. Fingerprint: Fingerprint,
  14. parseFingerprint: Fingerprint.parse,
  15. Signature: Signature,
  16. parseSignature: Signature.parse,
  17. PrivateKey: PrivateKey,
  18. parsePrivateKey: PrivateKey.parse,
  19. generatePrivateKey: PrivateKey.generate,
  20. Certificate: Certificate,
  21. parseCertificate: Certificate.parse,
  22. createSelfSignedCertificate: Certificate.createSelfSigned,
  23. createCertificate: Certificate.create,
  24. Identity: Identity,
  25. identityFromDN: Identity.parseDN,
  26. identityForHost: Identity.forHost,
  27. identityForUser: Identity.forUser,
  28. identityForEmail: Identity.forEmail,
  29. identityFromArray: Identity.fromArray,
  30. /* errors */
  31. FingerprintFormatError: errs.FingerprintFormatError,
  32. InvalidAlgorithmError: errs.InvalidAlgorithmError,
  33. KeyParseError: errs.KeyParseError,
  34. SignatureParseError: errs.SignatureParseError,
  35. KeyEncryptedError: errs.KeyEncryptedError,
  36. CertificateParseError: errs.CertificateParseError
  37. };