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.

readme.md 1.1 KiB

8 years ago
8 years ago
8 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. [![Build Status](https://travis-ci.org/lesspass/core.svg?branch=master)](https://travis-ci.org/lesspass/core)
  2. > core library for LessPass password manager in javascript used to generate unique password.
  3. ## Requirements
  4. - node LTS v6
  5. ## Install
  6. npm install lesspass
  7. ## Usage
  8. var LessPass = require('lesspass');
  9. var site = 'lesspass.com';
  10. var login = 'contact@lesspass.com';
  11. var masterPassword = 'password';
  12. var options = {
  13. counter: 1,
  14. length: 12,
  15. lowercase: true,
  16. uppercase: true,
  17. numbers: true,
  18. symbols: true
  19. };
  20. LessPass.encryptLogin(login, masterPassword).then(encryptedLogin => {
  21. LessPass.renderPassword(encryptedLogin, site, options).then(generatedPassword => {
  22. console.log(generatedPassword); //azYS7,olOL2]
  23. });
  24. });
  25. see [tests/api.tests.js](tests/api.tests.js) for more examples
  26. ## Tests
  27. npm test
  28. ## License
  29. MIT © [Guillaume Vincent](http://guillaumevincent.com)
  30. ## [LessPass project](https://github.com/lesspass/lesspass)