{"_id":"@axerunners/axecore-mnemonic","_rev":"2-0cc11225f73742e08ba02efd88f3f3a2","name":"@axerunners/axecore-mnemonic","dist-tags":{"latest":"1.6.1"},"versions":{"1.6.0":{"name":"@axerunners/axecore-mnemonic","version":"1.6.0","description":"BIP39 Mnemonics for Axecore","author":{"name":"AXErunners","email":"info@axerunners.com"},"main":"index.js","scripts":{"lint":"eslint .","test":"nyc mocha","build":"webpack"},"contributors":[{"name":"Yemel Jardi","email":"angel.jardi@gmail.com"},{"name":"Matias Alejo Garcia","email":"ematiu@gmail.com"}],"repository":{"type":"git","url":"git+https://github.com/axerunners/axecore-mnemonic.git"},"keywords":["axe","bitcore","mnemonic","crypto","cryptography","encryption","axecore"],"license":"MIT","devDependencies":{"assert":"^1.4.1","chai":"^4.2.0","eslint":"^5.9.0","eslint-config-airbnb-base":"^13.1.0","eslint-plugin-import":"^2.14.0","mocha":"^5.2.0","nyc":"^13.1.0","webpack":"^4.25.1","webpack-cli":"^3.1.2"},"dependencies":{"@axerunners/axecore-lib":"^0.15.0","unorm":"^1.4.1"},"gitHead":"931b484160431ded0f5f721954a95be1ef922c8c","bugs":{"url":"https://github.com/axerunners/axecore-mnemonic/issues"},"homepage":"https://github.com/axerunners/axecore-mnemonic#readme","_id":"@axerunners/axecore-mnemonic@1.6.0","_npmVersion":"6.4.1","_nodeVersion":"8.11.3","_npmUser":{"name":"charlie137","email":"charlie@axerunners.com"},"dist":{"integrity":"sha512-bOSMaWX6s9TnS0MUp9ECwuivmLTA4W0LAsNwEJ7WFNlYLWoGv2dxeVUT7/tWe/ZClWS6cM8shSjpd5Ny06R23g==","shasum":"15a4c940cbc6de333c62cedc0da6ae380f06e23f","tarball":"https://registry.npmjs.org/@axerunners/axecore-mnemonic/-/axecore-mnemonic-1.6.0.tgz","fileCount":21,"unpackedSize":182782,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcCTn1CRA9TVsSAnZWagAA57EP/iPGXfhKbLt31qVG4tNk\nGe3OOxM0+XxXpB4bs22ff+N1i78LPxomBNpSV1yFFauwrKB9/AQdDsF+kUu9\ngpro1BfRz9bPYMLZTlotLrG+GOCI6GAqIH50yp1Ppa8CaT/hVbWEMkvafU7Q\nKtAQkRO6tmI+xZdy1iaaGO7v6UpcNRy5rmW0DFEnU0UPcWYUOkF316PidHW0\n1jxzrhH6DIyEN4d1TC1fA8lHO1oubYTbrw4S+1m8t6FDpzE+7Iy4sGkFtvgw\nueNxpFPBEEX/jE6B/PiWg33tAIzlsa3zECgvTUP/kp+t71VcWfBAfvhtXPqT\n4a0lgXZeqXC0/zIwd9e9XtnWuWpavO9ZjofHFv6AGXXXNXB2D4+X/zcR10Bv\ntWm51jQbRwW/Qg4eC54AgzPnXgqgVjJ4ib4iaZ0fcwbmk7SB6xqbKeKeYbh/\nUXRZl6Mm3UDgzhLHSaVI7D/RPdbkswbWl+o/LN/a9xlvxVB3tKuK6SR7BV8D\nT2d3lsfhhmkCSu2aspoEpKFITv4+YWdSxOsrnTj7a9cAH0gWrBzZo2po8/2V\nsgHCxig1ZGAV3pFrjTbQeK3o974k8J96duy/Uo7C0VxocAJMQctd8tK0fsvb\nwt3CsOfJfI3AfuU8Du3NvwhbeM+u9JfvMfX1MlZaKYmSbr7beFCqZMEepZKu\nX/pV\r\n=0WdZ\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCG+Vk3bH5vs84KCLfcRbNzlMcPjGlJNcQHW7sOBx7xVAIhALWSiIEtDRgTMIWc6DEniHQV+jTJPkywo2vAo+lFqTbR"}]},"maintainers":[{"name":"charlie137","email":"charlie@axerunners.com"},{"name":"ddude1","email":"bence.coronation@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/axecore-mnemonic_1.6.0_1544108533103_0.5193971971366513"},"_hasShrinkwrap":false},"1.6.1":{"name":"@axerunners/axecore-mnemonic","version":"1.6.1","description":"BIP39 Mnemonics for Axecore","author":{"name":"AXErunners","email":"info@axerunners.com"},"main":"index.js","scripts":{"lint":"eslint .","test":"nyc mocha","build":"webpack"},"contributors":[{"name":"Yemel Jardi","email":"angel.jardi@gmail.com"},{"name":"Matias Alejo Garcia","email":"ematiu@gmail.com"}],"repository":{"type":"git","url":"git+https://github.com/axerunners/axecore-mnemonic.git"},"keywords":["axe","bitcore","mnemonic","crypto","cryptography","encryption","axecore"],"license":"MIT","devDependencies":{"assert":"^1.4.1","chai":"^4.2.0","eslint":"^5.9.0","eslint-config-airbnb-base":"^13.1.0","eslint-plugin-import":"^2.14.0","mocha":"^5.2.0","nyc":"^13.1.0","webpack":"^4.25.1","webpack-cli":"^3.1.2"},"dependencies":{"@axerunners/axecore-lib":"^0.16.8"},"gitHead":"cdd37087b710ed582b22dd8b5219304c000088a6","bugs":{"url":"https://github.com/axerunners/axecore-mnemonic/issues"},"homepage":"https://github.com/axerunners/axecore-mnemonic#readme","_id":"@axerunners/axecore-mnemonic@1.6.1","_npmVersion":"6.4.1","_nodeVersion":"10.15.0","_npmUser":{"name":"charlie137","email":"charlie@axerunners.com"},"dist":{"integrity":"sha512-wFjJHF7GVqnSua6FGTrj7QchlY8Gm6t62bDP65v8E//3xXCw/Ioah8Vypw4Swt0+ItJrdfKb4ZgyxwO9KroQHw==","shasum":"5c0c733752914eef5c88146c580a09f1b19159f1","tarball":"https://registry.npmjs.org/@axerunners/axecore-mnemonic/-/axecore-mnemonic-1.6.1.tgz","fileCount":11,"unpackedSize":39242,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcT6VfCRA9TVsSAnZWagAAGGEQAJ6hAFfvTtdNOsuoRIM3\nHxsOwyirlGqUfvQ0F6/35oRa0As8MvjVL85Y13/7Zr6bSaRudtOVx0yC//Sa\np/l+BF92BSEokJRqDuWRFI6lqbpn9mutV3oBqXniGkS5WvRcQPn4VFgPSCOf\n2EM5fpi5yD4XTfDvWx37ayZy/9bAMfLi9fxHv3yWXcgiYutm16U6tj+crkBC\n6FKCeCZ38bIo2n36oZSCCYOv94kyDXD1RRQhlTDRS+D004Iyo7K4yTXF+lpW\nceCz+Tra1vLJaJaRsITt4mOiO+fIlXZJzGQNkUQcpalQELr4UNBjIZ3iHjGv\nkR2ouVpCarWkdbs6aKv/qxxyZsIK/02ur8yWkBvFSEgc+q4kh/va42+hqU2W\nqOyixB6gWpB7omC0JGVpD6mLB7JwwjtnwsPJtsf7wBdnkHSjAdfxAEYtVWBN\nAS1e3YXdPUbxh1Kq3cUsiMh70xWcNSv2G4qlwzxHcf2qZmhi9KniBfhvesUO\ntTmLqKyBD/Q5/1ezaPcyRgJYLUrZeBK77lYejV/HgKYoB1HLjqtxze1w43Rq\naEbjRxpfH3Y2ijfq6MG76gFuiF4oAx3nEWC7YQRtRezD5Sgp9Ck4/1iG4Clh\n05GwzgLalETa102ddg2Uw9UgEgsLGrenuSY5SmFdMnT+C6ebx+dpkVjd3plL\nCHiH\r\n=cnzj\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC+y969188yM5WgEZ+RHumcgsx8L9abQLCDzypGBJQDdAIgHA9VuZI6JzrRoVy35Rzk7Ro4F2rBevj01K9ugJMtn24="}]},"maintainers":[{"name":"charlie137","email":"charlie@axerunners.com"},{"name":"ddude1","email":"bence.coronation@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/axecore-mnemonic_1.6.1_1548723551143_0.103230003615838"},"_hasShrinkwrap":false}},"time":{"created":"2018-12-06T15:02:13.036Z","1.6.0":"2018-12-06T15:02:13.277Z","modified":"2022-04-04T17:09:36.337Z","1.6.1":"2019-01-29T00:59:11.323Z"},"maintainers":[{"name":"charlie137","email":"charlie@axerunners.com"},{"name":"ddude1","email":"bence.coronation@gmail.com"}],"description":"BIP39 Mnemonics for Axecore","homepage":"https://github.com/axerunners/axecore-mnemonic#readme","keywords":["axe","bitcore","mnemonic","crypto","cryptography","encryption","axecore"],"repository":{"type":"git","url":"git+https://github.com/axerunners/axecore-mnemonic.git"},"contributors":[{"name":"Yemel Jardi","email":"angel.jardi@gmail.com"},{"name":"Matias Alejo Garcia","email":"ematiu@gmail.com"}],"author":{"name":"AXErunners","email":"info@axerunners.com"},"bugs":{"url":"https://github.com/axerunners/axecore-mnemonic/issues"},"license":"MIT","readme":"# axecore-mnemonic\n\n## Note: This package has been deprecated\n\nThis module is superceded the functionality in @axerunners/axecore-lib, please use that package moving forward.\n\n[![Build Status](https://img.shields.io/travis/axerunners/axecore-mnemonic/master.svg)](https://travis-ci.org/axerunners/axecore-mnemonic)\n[![NPM Package](https://img.shields.io/npm/v/@axerunners/axecore-mnemonic.svg)](https://www.npmjs.org/package/@axerunners/axecore-mnemonic)\n\n> BIP39 Mnemonics for Axecore\n\nA module for [axecore-lib](https://github.com/axerunners/axecore-lib) that implements [Mnemonic code for generating deterministic keys](https://github.com/bitcoin/bips/blob/master/bip-0039.mediawiki).\n\n## Install\n\n```sh\nnpm install @axerunners/axecore-mnemonic\n```\n\n## Usage\n\nThe `Mnemonic` class provides an implementation of a mnemonic code or mnemonic sentence – a group of easy to remember words – for the generation of deterministic keys. The class handles code generation and its later conversion to a [HDPrivateKey](hierarchical.md). See [the official BIP-0039](https://github.com/bitcoin/bips/blob/master/bip-0039.mediawiki) for technical background information.\n\nThere are many examples of how to use it on the developer guide [section for mnemonic](https://bitcore.io/api/mnemonic/). For example, the following code would generate a new random mnemonic code and convert it to a `HDPrivateKey`.\n\n```javascript\nvar Mnemonic = require('@axerunners/axecore-mnemonic');\nvar code = new Mnemonic(Mnemonic.Words.SPANISH);\ncode.toString(); // natal hada sutil año sólido papel jamón combate aula flota ver esfera...\nvar xpriv = code.toHDPrivateKey();\n```\n\n### Mnemonic generation\n\nFor creating a new random mnemonic code you just create a new instance.\n\n```javascript\nvar Mnemonic = require('@axerunners/axecore-mnemonic');\nvar code = new Mnemonic();\n\ncode.toString(); // 'select scout crash enforce riot rival spring whale hollow radar rule sentence'\n```\n\n### Multi-language support\n\nThe `Mnemonic` class can use any list of 2048 unique words to generate the mnemonic code. For convenience the class provides default word lists for the following languages: English (default), Chinese, French, Japanese and Spanish. Those word list are published under `Mnemonic.Words.LANGUAGE`, take a look at the following example:\n\n```javascript\nvar Mnemonic = require('@axerunners/axecore-mnemonic');\nvar code = new Mnemonic(Mnemonic.Words.SPANISH);\ncode.toString(); // natal hada sutil año sólido papel jamón combate aula flota ver esfera...\n\nvar myWordList = [ 'abandon', 'ability', 'able', 'about', 'above', ... ];\nvar customCode = new Mnemonic(myWordList);\n```\n\n### Validating a mnemonic\n\nThe Mnemonic class provides a static method to check if a mnemonic string is valid. If you generated the mnemonic code using any of the default word list, the class will identify it, otherwise you must provide the word list used.\n\n```javascript\nvar Mnemonic = require('@axerunners/axecore-mnemonic');\n\nvar code = 'select scout crash enforce riot rival spring whale hollow radar rule sentence';\nvar valid = Mnemonic.isValid(code);\n\n// using a custom word list\nvar validCutom = Mnemonic.isValid(code, customWordlist);\n```\n\n### Generating a private key\n\nA mnemonic encodes entropy that can be used for creating a seed and later a [HDPrivateKey](hierarchical.md). During the seed generation process a passphrase can be used. The code for doing so looks like this:\n\n```javascript\nvar Mnemonic = require('@axerunners/axecore-mnemonic');\nvar code = new Mnemonic('select scout crash enforce riot rival spring whale hollow radar rule sentence');\n\nvar xpriv1 = code.toHDPrivateKey(); // no passphrase\nvar xpriv2 = code.toHDPrivateKey('my passphrase'); // using a passphrase\n```\n\n### Browser Usage\n\nA webpack config is included in order to build a browser bundle:\n\n```sh\nnpm run build\n```\n\nThis will generate a file `dist/axecore-mnemonic.js`, which can be included into your HTML a-like so:\n\n```html\n<html lang=\"en\">\n<head>\n  <title>Tester - AxeCore Mnemonic</title>\n  <script language=\"javascript\" src=\"dist/axecore-mnemonic.js\"></script>\n</head>\n<body>\n  <script>\n    document.addEventListener(\"DOMContentLoaded\", function() {\n      var mnemonic = new axecoreMnemonic();\n      console.log(\"MNEMONIC: \" + mnemonic.toString());\n\n      var xpriv1 = mnemonic.toHDPrivateKey(); // no passphrase\n      var xpriv2 = mnemonic.toHDPrivateKey('my passphrase'); // using a passphrase\n\n      console.log(\"xpriv1: \" + xpriv1);\n      console.log(\"xpriv2: \" + xpriv2);\n    });\n  </script>\n</body>\n</html>\n```\n\nThis test snippet is included as a file in this repo called \"example.html\", and you can test this in a browser. We'll use Docker to simplify this:\n\n```sh\ndocker run --rm --name nginx -p 127.0.0.1:80:80 -v $PWD:/usr/share/nginx/html nginx:alpine\n```\n\nNow navigate to <http://localhost/example.html> and open a console window. You should see the expected console output from the `console.log` lines in the HTML snippet above.\n\n## Contributing\n\nFeel free to dive in! [Open an issue](https://github.com/axerunners/axecore-mnemonic/issues/new) or submit PRs.\n\n## License\n\nCode released under [the MIT license](LICENSE).\n\nCopyright 2013-2015 BitPay, Inc. Bitcore is a trademark maintained by BitPay, Inc.  \nCopyright 2015-2018 Dash Core Group, Inc.   \nCopyright 2018 AXErunners.    \n","readmeFilename":"README.md"}