{"_id":"more-entropy","_rev":"18-76e807ba4a35f923e9c8b9e73c2b6fdb","name":"more-entropy","description":"Generate more entropy to combine with Node's crypto.rng or window.crypto","dist-tags":{"latest":"0.0.7"},"versions":{"0.0.1":{"name":"more-entropy","version":"0.0.1","description":"Generate more entropy to combine with Node's crypto.rng or window.crypto","homepage":"https://github.com/keybase/entropy","repository":{"type":"git","url":"https://github.com/keybase/entropy.git"},"devDependencies":{},"dependencies":{"iced-coffee-script":"*"},"directories":{"lib":"lib"},"scripts":{"make":"make"},"main":"lib/main.js","licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bugs":{"url":"https://github.com/keybase/entropy/issues"},"_id":"more-entropy@0.0.1","dist":{"shasum":"3825e11f920dbf4b13776cf1521fbe572b15f238","tarball":"https://registry.npmjs.org/more-entropy/-/more-entropy-0.0.1.tgz","integrity":"sha512-g06Ag6Bo+KW4EzOvcG8Oa0jpZj1mVWWFtbdRS6QRSUMld/AvSQLdgM0TfPyOjXlZ1G5+jvhKNJAQgAGPWVh2Ng==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCID6EbsoX4zh+8ZpyWZLMQvujzplUbK0SpClJF81r+Cc0AiEA1AX6BbVKWEeoQYWeWsr+nQW6mqClxuKmv8zCsFRZ6uA="}]},"_from":".","_npmVersion":"1.3.2","_npmUser":{"name":"malgorithms","email":"ccoyne77@gmail.com"},"maintainers":[{"name":"malgorithms","email":"ccoyne77@gmail.com"}]},"0.0.2":{"name":"more-entropy","version":"0.0.2","description":"Generate more entropy to combine with Node's crypto.rng or window.crypto","homepage":"https://github.com/keybase/entropy","repository":{"type":"git","url":"https://github.com/keybase/entropy.git"},"devDependencies":{},"dependencies":{"iced-coffee-script":"*"},"directories":{"lib":"lib"},"scripts":{"make":"make"},"main":"lib/main.js","licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bugs":{"url":"https://github.com/keybase/entropy/issues"},"_id":"more-entropy@0.0.2","dist":{"shasum":"1a81c7ec1842feabdc39920cfc8f537a688d3ad6","tarball":"https://registry.npmjs.org/more-entropy/-/more-entropy-0.0.2.tgz","integrity":"sha512-ZzVSu6XR/hHKw0i+aQg1ECFW8ooZKeKZQ+aTOLWFDni0mhHzyCuWWpy0EjLOiwmw26TAEKI15K5gyxlAOnM8bw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCVVfuHj5td9x4lYP/FVBskT8Yp+Ch7B5N6s9w2DuV+rQIhANLT8/x6Lm55kg+6bQBqHJGMlRq08bjZ0mXTGG3+QJQ0"}]},"_from":".","_npmVersion":"1.3.2","_npmUser":{"name":"malgorithms","email":"ccoyne77@gmail.com"},"maintainers":[{"name":"malgorithms","email":"ccoyne77@gmail.com"}]},"0.0.3":{"name":"more-entropy","version":"0.0.3","description":"Generate more entropy to combine with Node's crypto.rng or window.crypto","homepage":"https://github.com/keybase/entropy","repository":{"type":"git","url":"https://github.com/keybase/entropy.git"},"devDependencies":{"iced-coffee-script":"^1.7.1-c"},"dependencies":{"iced-runtime":"0.0.1"},"directories":{"lib":"lib"},"scripts":{"make":"make"},"main":"lib/main.js","licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"gitHead":"1c0d1582828554fe68596d157868399bb383a2c0","bugs":{"url":"https://github.com/keybase/entropy/issues"},"_id":"more-entropy@0.0.3","_shasum":"71682d913c3fa88bf231131cbfc206f177f83e04","_from":".","_npmVersion":"1.4.13","_npmUser":{"name":"maxtaco","email":"themax@gmail.com"},"maintainers":[{"name":"malgorithms","email":"ccoyne77@gmail.com"},{"name":"maxtaco","email":"themax@gmail.com"}],"dist":{"shasum":"71682d913c3fa88bf231131cbfc206f177f83e04","tarball":"https://registry.npmjs.org/more-entropy/-/more-entropy-0.0.3.tgz","integrity":"sha512-hmiOdhItFoFlAVxWBiAq+ZY3fVGPWn3ItvkTxt9Srds9UCqaDDBIfAY1cKNDtxkMsL9cC6X2KMH6o1nEsPbNnA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIC0KYx+0xxXGc2rvKTCH7AOh0uXPOGqM0mhvLESdA9tbAiAsf30WALJSPUjg3djlmDKJb8jsWAsBDdXhfSpBNBVMcA=="}]}},"0.0.4":{"name":"more-entropy","version":"0.0.4","description":"Generate more entropy to combine with Node's crypto.rng or window.crypto","homepage":"https://github.com/keybase/entropy","repository":{"type":"git","url":"https://github.com/keybase/entropy.git"},"devDependencies":{"iced-coffee-script":"^1.7.1-c"},"dependencies":{"iced-runtime":">=0.0.1"},"directories":{"lib":"lib"},"scripts":{"make":"make"},"main":"lib/main.js","licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"gitHead":"a484cbf7f5cde3bc431f31ac13ff43250e4bdfea","bugs":{"url":"https://github.com/keybase/entropy/issues"},"_id":"more-entropy@0.0.4","_shasum":"d7d3114e9f3bc9614cde4d273d381a45818816db","_from":".","_npmVersion":"1.4.13","_npmUser":{"name":"maxtaco","email":"themax@gmail.com"},"maintainers":[{"name":"malgorithms","email":"ccoyne77@gmail.com"},{"name":"maxtaco","email":"themax@gmail.com"}],"dist":{"shasum":"d7d3114e9f3bc9614cde4d273d381a45818816db","tarball":"https://registry.npmjs.org/more-entropy/-/more-entropy-0.0.4.tgz","integrity":"sha512-JdSZ7VdXmrA7oS4ylhHGvNRcxwkVIiG+l9RwnMzraKyLSfOEJbdQeS9kwH2mjaPy/TRGu1xlk/fchVHJEE8QWA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCceWiaAdtbDp+e07S/xe74PlRc8ykSc0RIkUFPYUaX6QIgJgH87fvNVWAFc1DpsqzHK7jAsSKn9Q4J93fZ1vbM4/M="}]}},"0.0.5":{"name":"more-entropy","version":"0.0.5","description":"Generate more entropy to combine with Node's crypto.rng or window.crypto","homepage":"https://github.com/keybase/entropy","repository":{"type":"git","url":"https://github.com/keybase/entropy.git"},"devDependencies":{"iced-coffee-script":"^1.7.1-c"},"dependencies":{"iced-runtime":">=0.0.1"},"directories":{"lib":"lib"},"scripts":{"make":"make"},"main":"lib/main.js","licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"gitHead":"87e349c1c3f8627cfa25084e2d231aac38df3e24","bugs":{"url":"https://github.com/keybase/entropy/issues"},"_id":"more-entropy@0.0.5","_shasum":"5966f11f19a8b75d38bcf2443da1c1d9cac8434c","_from":".","_npmVersion":"1.4.14","_npmUser":{"name":"malgorithms","email":"ccoyne77@gmail.com"},"maintainers":[{"name":"malgorithms","email":"ccoyne77@gmail.com"},{"name":"maxtaco","email":"themax@gmail.com"}],"dist":{"shasum":"5966f11f19a8b75d38bcf2443da1c1d9cac8434c","tarball":"https://registry.npmjs.org/more-entropy/-/more-entropy-0.0.5.tgz","integrity":"sha512-rhE9+YSsYN/PPNWp/uylwUW9dUG9XyOwafeEYPQR0RkZZlYTj1zVrrMb2VtYLCF1iyOwDz+359n6+GlSiBq5WA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD9exeiO/wBplfySxzKkihrUj17Gy2Pg45uefa/XDoCZAIgLsqqDM8/ATQwZl0LS4pjOCtrgcOw6jvlimr2QFmKmlw="}]}},"0.0.6":{"name":"more-entropy","version":"0.0.6","description":"Generate more entropy to combine with Node's crypto.rng or window.crypto","homepage":"https://github.com/keybase/entropy","repository":{"type":"git","url":"https://github.com/keybase/entropy.git"},"devDependencies":{"iced-coffee-script":"^1.7.1-c"},"dependencies":{"iced-runtime":">=0.0.1"},"directories":{"lib":"lib"},"scripts":{"make":"make"},"main":"lib/main.js","licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"gitHead":"c112334b9b6d8a32f6983fe412e807bc07b62966","bugs":{"url":"https://github.com/keybase/entropy/issues"},"_id":"more-entropy@0.0.6","_shasum":"950cddb1eda25dbfd83b98396e440ae802db056a","_from":".","_npmVersion":"1.4.14","_npmUser":{"name":"malgorithms","email":"ccoyne77@gmail.com"},"maintainers":[{"name":"malgorithms","email":"ccoyne77@gmail.com"},{"name":"maxtaco","email":"themax@gmail.com"}],"dist":{"shasum":"950cddb1eda25dbfd83b98396e440ae802db056a","tarball":"https://registry.npmjs.org/more-entropy/-/more-entropy-0.0.6.tgz","integrity":"sha512-gcMDqF1ee2/1sbxi5w688Wq/le+MMRuQU+KCXegAQ1ZlPmScNTsfBUdUZRg+TRt3uPciUIdEV2JoErYbFR1QRQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIE/rkWLlDHmRO5QdXNjywdrAZkCJpoaTakfkrIOClFSUAiBw0n0dKBae6Ze5L+qPjB0PymOIMZHuiHD3HnUhiN3+Aw=="}]}},"0.0.7":{"name":"more-entropy","version":"0.0.7","description":"Generate more entropy to combine with Node's crypto.rng or window.crypto","homepage":"https://github.com/keybase/entropy","repository":{"type":"git","url":"https://github.com/keybase/entropy.git"},"devDependencies":{"iced-coffee-script":"^1.7.1-c"},"dependencies":{"iced-runtime":">=0.0.1"},"directories":{"lib":"lib"},"scripts":{"make":"make"},"main":"lib/main.js","licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"gitHead":"bd265fe573078e4631ff9174ae4c937b7dbb9dd0","bugs":{"url":"https://github.com/keybase/entropy/issues"},"_id":"more-entropy@0.0.7","_shasum":"67bfc6f7a86f26fbc37aac83fd46d88c61d109b5","_from":".","_npmVersion":"1.4.14","_npmUser":{"name":"malgorithms","email":"ccoyne77@gmail.com"},"maintainers":[{"name":"malgorithms","email":"ccoyne77@gmail.com"},{"name":"maxtaco","email":"themax@gmail.com"}],"dist":{"shasum":"67bfc6f7a86f26fbc37aac83fd46d88c61d109b5","tarball":"https://registry.npmjs.org/more-entropy/-/more-entropy-0.0.7.tgz","integrity":"sha512-e0TxQtU1F6/ZA8WnEA2JLQwwDqBTtZFLJSW7rWgUsQou35wx1IOL0g2O7q7oGoMgIJto+jHMnNGHLfSiylHRrw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIE9BBSg1Glrj7HHqLhggqgzOXAnJm4UVwadUhkZKFQdjAiA34lAh2dv+8/95RaVS6iwfxROYM9jNfFpWdrZl9XAYoA=="}]}}},"readme":"more-entropy\n=======\n\nThe easiest way to generate good pseudorandom numbers in the browser is with `window.crypto.getRandomValues`, and in Node.js you can use `crypto.rng`. \nBut for the truly paranoid, getting even more entropy is a good idea. For example, one might seed their own key generator with a combination\nof `window.crypto` and a series of coordinates collected from mouse movements or key mashes.\n\nEven though the mouse movements of the user are not very random, it's extra noise, adding a layer of safety. Perhaps each [x,y] mouse\nlocation is worth a bit or two of entropy.\n\n`more-entropy` achieves similar results but without user interaction or ugly integration with your DOM. \nIt generates large numbers by counting how many operations it can perform in a unit of time, which fluctuates\nunpredictably based on other system processes and low-level architectural specifics (like cache misses and FPU pipelines).\n\nA good use of this module is to combine its output with\n`window.crypto.getRandomValue` or `crypto.rng`, and use the\nresult as a seed for a deterministic random bit generator (like \n[HMAC_DRBG](http://csrc.nist.gov/publications/nistpubs/800-90A/SP800-90A.pdf)).\nYou'll have an extra layer of protection if you're afraid that the\nstandard random number generators are compromised.\n\n\n### Installation\n\n```bash\nnpm install -g more-entropy\n```\n\n### Usage\n\n```javascript\nvar m = require('more-entropy');\n\n// create a generator, which can provide you with some entropy\nvar c = new m.Generator();\n\n// get an array of integers with at least 100 bits of combined entropy:\nc.get_entropy(100, function(vals) {\n  console.log(vals); // [-4358,543,9089,...]\n});\n\n```\n\n### What it's doing\n\nThis generator repeatedly does as many floating point operations as it can in 1ms-2ms time periods (typically many thousands), and compares this value to previous attempts.\nThe delta is then added to a collection with a very conservative estimate for bits of entropy.\n\nMuch like the mouse movement technique, we are collecting a lot of data and assuming it's just a little bit random.\n\n### Notes\n\n * entropy is calculated by changes in performance; for example, extreme high performance with no variation yields zero entropy. Only fluctuations are captured.\n * this will work even if your system is bogged down (it'll just take longer)\n * it only CPU blocks for bursts up to 2ms, so it's safe in the browser and in Node.js\n * `get_entropy` can be called as many times as you like, even concurrently; it will call back with uniquely calculated data to each request\n * return values are small integers (sometimes < 1000) and may be negative\n * entropy is collected over time, so a request for lots of bits could take a while\n\n### One Big Assumption\n\n * your CPU is not shared with an attacker; a carefully timed attack on the CPU could produce entropy less than what's requested\n\n### Options\n\n`new m.Generator()` can be called with extra options:\n\n```javascript\nvar c = new m.Generator({\n  'loop_delay':        10 // how many milliseconds to pause between each operation loop. A lower value will generate entropy faster, but will also be harder on the CPU\n  'work_min':           1 // milliseconds per loop; a higher value blocks the CPU more, so 1 is recommended\n  'auto_stop_bits':  4096 // the generator prepares entropy for you before you request it; if it reaches this much unclaimed entropy it will stop working\n  'max_bits_per_delta': 4 // a safety cap on how much entropy it can claim per value; 4 (default) is very conservative. a larger value will allow faster entropy generation\n});\n```\n","maintainers":[{"name":"malgorithms","email":"ccoyne77@gmail.com"},{"name":"maxtaco","email":"themax@gmail.com"}],"time":{"modified":"2022-06-20T09:22:57.343Z","created":"2013-09-11T18:24:55.682Z","0.0.1":"2013-09-11T18:24:57.364Z","0.0.2":"2013-09-12T15:35:57.047Z","0.0.3":"2014-06-04T15:54:58.476Z","0.0.4":"2014-06-20T19:03:02.086Z","0.0.5":"2014-08-16T11:43:48.721Z","0.0.6":"2014-08-16T12:06:44.303Z","0.0.7":"2014-08-16T12:36:43.006Z"},"repository":{"type":"git","url":"https://github.com/keybase/entropy.git"},"homepage":"https://github.com/keybase/entropy","bugs":{"url":"https://github.com/keybase/entropy/issues"},"readmeFilename":"README.md"}