Initial commit

This commit is contained in:
abrendan
2023-11-30 14:15:19 +00:00
commit e4599df811
5457 changed files with 500139 additions and 0 deletions

22
node_modules/rndm/LICENSE generated vendored Normal file
View File

@@ -0,0 +1,22 @@
The MIT License (MIT)
Copyright (c) 2014 Jonathan Ong me@jongleberry.com
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.

27
node_modules/rndm/README.md generated vendored Normal file
View File

@@ -0,0 +1,27 @@
# RNDM
Random string generator.
Basically `Math.random().toString(36).slice(2)`,
but with both upper and lower case letters and arbitrary lengths.
Useful for creating fast, not cryptographically secure salts.
## API
```js
// base62 by default
var rndm = require('rndm')
var salt = rndm(16)
```
### var salt = rndm(length)
### var salt = rndm.base62(length)
### var salt = rndm.base36(length)
### var salt = rndm.base10(length)
### var random = rndm.create(characters)
Create a new random generator with custom characters.

25
node_modules/rndm/index.js generated vendored Normal file
View File

@@ -0,0 +1,25 @@
var assert = require('assert')
var base62 = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789'
var base36 = 'abcdefghijklmnopqrstuvwxyz0123456789'
var base10 = '0123456789'
exports = module.exports = create(base62)
exports.base62 = exports
exports.base36 = create(base36)
exports.base10 = create(base10)
exports.create = create
function create(chars) {
assert(typeof chars === 'string', 'the list of characters must be a string!')
var length = Buffer.byteLength(chars)
return function rndm(len) {
len = len || 10
assert(typeof len === 'number' && len >= 0, 'the length of the random string must be a number!')
var salt = ''
for (var i = 0; i < len; i++) salt += chars[Math.floor(length * Math.random())]
return salt
}
}

63
node_modules/rndm/package.json generated vendored Normal file
View File

@@ -0,0 +1,63 @@
{
"_from": "rndm@1.2.0",
"_id": "rndm@1.2.0",
"_inBundle": false,
"_integrity": "sha1-8z/pz7Urv9UgqhgyO8ZdsRCht2w=",
"_location": "/rndm",
"_phantomChildren": {},
"_requested": {
"type": "version",
"registry": true,
"raw": "rndm@1.2.0",
"name": "rndm",
"escapedName": "rndm",
"rawSpec": "1.2.0",
"saveSpec": null,
"fetchSpec": "1.2.0"
},
"_requiredBy": [
"/csrf"
],
"_resolved": "https://registry.npmjs.org/rndm/-/rndm-1.2.0.tgz",
"_shasum": "f33fe9cfb52bbfd520aa18323bc65db110a1b76c",
"_spec": "rndm@1.2.0",
"_where": "/home/runner/Socketio-Chat-Template/node_modules/csrf",
"author": {
"name": "Jonathan Ong",
"email": "me@jongleberry.com",
"url": "http://jongleberry.com"
},
"bugs": {
"url": "https://github.com/crypto-utils/rndm/issues"
},
"bundleDependencies": false,
"deprecated": false,
"description": "random string generator",
"devDependencies": {
"istanbul": "0",
"mocha": "2"
},
"files": [
"index.js"
],
"homepage": "https://github.com/crypto-utils/rndm#readme",
"keywords": [
"random",
"number",
"generator",
"uid",
"id"
],
"license": "MIT",
"name": "rndm",
"repository": {
"type": "git",
"url": "git+https://github.com/crypto-utils/rndm.git"
},
"scripts": {
"test": "mocha",
"test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot",
"test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter dot"
},
"version": "1.2.0"
}