{"_id":"random-token","_rev":"2922696","name":"random-token","description":"Random token generation of given size","dist-tags":{"latest":"0.0.8"},"maintainers":[{"name":"ashnur","email":""}],"time":{"modified":"2023-02-14T06:12:01.000Z","created":"2013-11-03T00:32:43.121Z","0.0.8":"2014-04-02T16:04:27.724Z","0.0.7":"2014-04-02T15:53:37.852Z","0.0.6":"2014-03-24T09:07:16.200Z","0.0.5":"2014-02-26T14:58:31.169Z","0.0.4":"2014-01-26T13:16:05.961Z","0.0.3":"2013-11-03T10:26:15.218Z","0.0.2":"2013-11-03T10:19:30.070Z","0.0.1":"2013-11-03T00:32:43.121Z"},"users":{},"author":{"name":"ashnur"},"repository":{"type":"git","url":"git://github.com/ashnur/random-token.git"},"versions":{"0.0.8":{"name":"random-token","description":"Random token generation of given size","version":"0.0.8","main":"index.js","scripts":{"test":"node test/test.js","prepublish":"npm test"},"repository":{"type":"git","url":"git://github.com/ashnur/random-token.git"},"bugs":{"url":"https://github.com/ashnur/random-token/issues"},"keywords":["token","token-generator","key","keygen","random-token"],"author":{"name":"ashnur"},"license":"BSD-2-Clause","homepage":"https://github.com/ashnur/random-token","_id":"random-token@0.0.8","dist":{"shasum":"1cf845af3fb31e57f7caa4b9a173478c46483b61","size":2981,"noattachment":false,"key":"/random-token/-/random-token-0.0.8.tgz","tarball":"http://registry.cnpm.dingdandao.com/random-token/download/random-token-0.0.8.tgz"},"_from":".","_npmVersion":"1.4.6","_npmUser":{"name":"ashnur","email":"ashnur@gmail.com"},"maintainers":[{"name":"ashnur","email":""}],"directories":{},"_cnpmcore_publish_time":"2021-12-19T21:15:03.997Z","publish_time":1396454667724,"_cnpm_publish_time":1396454667724},"0.0.7":{"name":"random-token","description":"Random token generation of given size","version":"0.0.7","main":"index.js","scripts":{"test":"node test/test.js","prepublish":"npm test"},"repository":{"type":"git","url":"git://github.com/ashnur/random-token.git"},"bugs":{"url":"https://github.com/ashnur/random-token/issues"},"keywords":["token","token-generator","key","keygen","random-token"],"author":{"name":"ashnur"},"license":"BSD-2-Clause","homepage":"https://github.com/ashnur/random-token","_id":"random-token@0.0.7","dist":{"shasum":"319fbbe126a1a1976f86846a23ae8e98da383d3f","size":2979,"noattachment":false,"key":"/random-token/-/random-token-0.0.7.tgz","tarball":"http://registry.cnpm.dingdandao.com/random-token/download/random-token-0.0.7.tgz"},"_from":".","_npmVersion":"1.4.4","_npmUser":{"name":"ashnur","email":"ashnur@gmail.com"},"maintainers":[{"name":"ashnur","email":""}],"directories":{},"_cnpmcore_publish_time":"2021-12-19T21:15:03.915Z","publish_time":1396454017852,"_cnpm_publish_time":1396454017852},"0.0.6":{"name":"random-token","description":"Random token generation of given size","version":"0.0.6","main":"index.js","scripts":{"test":"node test/test.js","prepublish":"npm test"},"repository":{"type":"git","url":"git://github.com/ashnur/random-token.git"},"bugs":{"url":"https://github.com/ashnur/random-token/issues"},"keywords":["token","token-generator","key","keygen","random-token"],"author":{"name":"ashnur"},"license":"BSD-2-Clause","homepage":"https://github.com/ashnur/random-token","_id":"random-token@0.0.6","dist":{"shasum":"9567c006c652ddf6cb6fa19117bf8d9ec6b8a3f1","size":2981,"noattachment":false,"key":"/random-token/-/random-token-0.0.6.tgz","tarball":"http://registry.cnpm.dingdandao.com/random-token/download/random-token-0.0.6.tgz"},"_from":".","_npmVersion":"1.4.4","_npmUser":{"name":"ashnur","email":"ashnur@gmail.com"},"maintainers":[{"name":"ashnur","email":""}],"directories":{},"_cnpmcore_publish_time":"2021-12-19T21:15:03.033Z","publish_time":1395652036200,"_cnpm_publish_time":1395652036200},"0.0.5":{"name":"random-token","description":"Random token generation of given size","version":"0.0.5","main":"index.js","scripts":{"test":"node test/test.js","prepublish":"npm test"},"repository":{"type":"git","url":"git://github.com/ashnur/random-token.git"},"bugs":{"url":"https://github.com/ashnur/random-token/issues"},"keywords":["token","token-generator","key","keygen","random-token"],"author":{"name":"ashnur"},"license":"BSD-2-Clause","homepage":"https://github.com/ashnur/random-token","_id":"random-token@0.0.5","dist":{"shasum":"2badc3d9997829a40af7f0bbe4407a85259f14eb","size":2979,"noattachment":false,"key":"/random-token/-/random-token-0.0.5.tgz","tarball":"http://registry.cnpm.dingdandao.com/random-token/download/random-token-0.0.5.tgz"},"_from":".","_npmVersion":"1.4.4","_npmUser":{"name":"ashnur","email":"ashnur@gmail.com"},"maintainers":[{"name":"ashnur","email":""}],"directories":{},"_cnpmcore_publish_time":"2021-12-19T21:15:02.160Z","publish_time":1393426711169,"_cnpm_publish_time":1393426711169},"0.0.4":{"name":"random-token","description":"Random token generation of given size","version":"0.0.4","main":"index.js","scripts":{"test":"node test/test.js","prepublish":"npm test"},"repository":{"type":"git","url":"git://github.com/ashnur/random-token.git"},"bugs":{"url":"https://github.com/ashnur/random-token/issues"},"keywords":["token","token-generator","key","keygen","random-token"],"author":{"name":"ashnur"},"license":"BSD-2-Clause","homepage":"https://github.com/ashnur/random-token","_id":"random-token@0.0.4","dist":{"shasum":"a5ec0a2fde1f93376ee569d3b431ea80302c636a","size":2897,"noattachment":false,"key":"/random-token/-/random-token-0.0.4.tgz","tarball":"http://registry.cnpm.dingdandao.com/random-token/download/random-token-0.0.4.tgz"},"_from":".","_npmVersion":"1.3.21","_npmUser":{"name":"ashnur","email":"ashnur@gmail.com"},"maintainers":[{"name":"ashnur","email":""}],"directories":{},"_cnpmcore_publish_time":"2021-12-19T21:15:01.261Z","publish_time":1390742165961,"_cnpm_publish_time":1390742165961},"0.0.3":{"name":"random-token","description":"Random token generation of given size","version":"0.0.3","main":"index.js","scripts":{"test":"node test/test.js","prepublish":"npm test"},"repository":{"type":"git","url":"git://github.com/ashnur/random-token.git"},"bugs":{"url":"https://github.com/ashnur/random-token/issues"},"keywords":["token","token-generator","key","keygen","random-token"],"author":{"name":"ashnur"},"license":"DAFUQ","_id":"random-token@0.0.3","dist":{"shasum":"ab4c162f317ea3a001b102dd7c9dd13adb1e232b","size":2154,"noattachment":false,"key":"/random-token/-/random-token-0.0.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/random-token/download/random-token-0.0.3.tgz"},"_from":".","_npmVersion":"1.3.11","_npmUser":{"name":"ashnur","email":"ashnur@gmail.com"},"maintainers":[{"name":"ashnur","email":""}],"directories":{},"_cnpmcore_publish_time":"2021-12-19T21:15:00.402Z","publish_time":1383474375218,"_cnpm_publish_time":1383474375218},"0.0.2":{"name":"random-token","description":"Random token generation of given size","version":"0.0.2","main":"index.js","scripts":{"test":"node test/test.js","prepublish":"npm test"},"repository":{"type":"git","url":"git://github.com/ashnur/random-token.git"},"bugs":{"url":"https://github.com/ashnur/random-token/issues"},"keywords":["token","token-generator","key","keygen","random-token"],"author":{"name":"ashnur"},"license":"DAFUQ","_id":"random-token@0.0.2","dist":{"shasum":"ea30f0669dd8d3b20f09f75e953195d10774246c","size":2153,"noattachment":false,"key":"/random-token/-/random-token-0.0.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/random-token/download/random-token-0.0.2.tgz"},"_from":".","_npmVersion":"1.3.11","_npmUser":{"name":"ashnur","email":"ashnur@gmail.com"},"maintainers":[{"name":"ashnur","email":""}],"directories":{},"_cnpmcore_publish_time":"2021-12-19T21:14:59.522Z","publish_time":1383473970070,"_cnpm_publish_time":1383473970070},"0.0.1":{"name":"random-token","description":"Random token generation of given size","version":"0.0.1","main":"index.js","scripts":{"test":"node test/test.js","prepublish":"npm test"},"repository":{"type":"git","url":"git://github.com/ashnur/random-token.git"},"bugs":{"url":"https://github.com/ashnur/random-token/issues"},"author":{"name":"ashnur"},"license":"DAFUQ","_id":"random-token@0.0.1","dist":{"shasum":"63247157abe34adbc04556695f15554851473fdd","size":1230,"noattachment":false,"key":"/random-token/-/random-token-0.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/random-token/download/random-token-0.0.1.tgz"},"_from":".","_npmVersion":"1.3.11","_npmUser":{"name":"ashnur","email":"ashnur@gmail.com"},"maintainers":[{"name":"ashnur","email":""}],"directories":{},"_cnpmcore_publish_time":"2021-12-19T21:14:58.681Z","publish_time":1383438763121,"_cnpm_publish_time":1383438763121}},"readme":"# random-token\ngenerate a (pseudo-)random string of given length composed from alphanumeric characters\n\n# install\n`npm install random-token`\n\n# usage\n## initiate\n``` javascript\nvar randomToken = require('random-token');\n```\n\n\n## default salt is \"abcdefghijklmnopqrstuvwxzy0123456789\"\n``` javascript\nvar token = randomToken(16); // example output → 'xg8250nbg4klq5b3'\n```\n\n## different salt\n``` javascript\nvar randomToken = require('random-token').create('abcdefghijklmnopqrstuvwxzyABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789');\nvar token = randomToken(16); // example output → '3ZGErMDCwxTOZYFp'\n```\n\n**Note: valid salts are strings with length > 0**\n*if an invalid salt is given to `.create`, the returned generator will use the default salt*\n\n## convenience methods\n#### .create\ncreate a different generator\n``` javascript\nvar randomToken = require('random-token').create('Aa0');\nvar rt = randomToken.gen('Aa0');\nvar token = rt(16); // example output → 'A0aAAaA0AA0Aa0AA'\n```\n\n#### .salt\nyou can check a generators salt by calling `.salt()` on it\n``` javascript\nvar randomToken = require('random-token').gen('abcdefghijklmnopqrstuvwxzyABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789');\nrandomToken.salt(); // output → 'abcdefghijklmnopqrstuvwxzyABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'\n```\n\n","_attachments":{},"homepage":"https://github.com/ashnur/random-token","bugs":{"url":"https://github.com/ashnur/random-token/issues"},"license":"BSD-2-Clause"}