https://github.com/browserify/pseudorandombytes
pseudorandombytes for the browser
https://github.com/browserify/pseudorandombytes
Last synced: 10 months ago
JSON representation
pseudorandombytes for the browser
- Host: GitHub
- URL: https://github.com/browserify/pseudorandombytes
- Owner: browserify
- License: mit
- Created: 2015-01-19T21:01:55.000Z (about 11 years ago)
- Default Branch: master
- Last Pushed: 2024-12-21T09:52:29.000Z (about 1 year ago)
- Last Synced: 2025-03-23T06:51:09.765Z (11 months ago)
- Language: JavaScript
- Size: 13.7 KB
- Stars: 3
- Watchers: 5
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
pseudoRandomBytes
===
crypto.pseudoRandomBytes but for use with browserify. In node it just returns crypto.pseudoRandomBytes but in the browser it uses [crypto-browserify/randombytes](https://github.com/crypto-browserify/randombytes) if available else it seeds a prng based on [chacha20poly1305](https://github.com/calvinmetcalf/chacha20poly1305).
To use:
====
```js
var pseudoRandomBytes = require('pseudorandomBbytes');
var bytes = pseudoRandomBytes(34);
```
To be clear there is no legitimate reason for you ever to want to use this.
# The algorithms used in this module are **NOT** suitable for cryptographical usage.