summaryrefslogtreecommitdiffstats
path: root/node_modules/browserify-rsa
diff options
context:
space:
mode:
authorGravatar Piotr Russ <mail@pruss.it> 2020-11-18 23:26:45 +0100
committerGravatar Piotr Russ <mail@pruss.it> 2020-11-18 23:26:45 +0100
commit81ddf9b700bc48a1f8e472209f080f9c1d9a9b09 (patch)
tree8b959d50c5a614cbf9fcb346ed556140374d4b6d /node_modules/browserify-rsa
parent1870f3fdf43707a15fda0f609a021f516f45eb63 (diff)
downloadwebsite_creator-81ddf9b700bc48a1f8e472209f080f9c1d9a9b09.tar.gz
website_creator-81ddf9b700bc48a1f8e472209f080f9c1d9a9b09.tar.bz2
website_creator-81ddf9b700bc48a1f8e472209f080f9c1d9a9b09.zip
rm node_modules
Diffstat (limited to 'node_modules/browserify-rsa')
-rw-r--r--node_modules/browserify-rsa/LICENSE21
-rw-r--r--node_modules/browserify-rsa/README.md17
-rw-r--r--node_modules/browserify-rsa/index.js35
-rw-r--r--node_modules/browserify-rsa/package.json58
4 files changed, 0 insertions, 131 deletions
diff --git a/node_modules/browserify-rsa/LICENSE b/node_modules/browserify-rsa/LICENSE
deleted file mode 100644
index c1dd3c5..0000000
--- a/node_modules/browserify-rsa/LICENSE
+++ /dev/null
@@ -1,21 +0,0 @@
-The MIT License (MIT)
-
-Copyright (c) 2014-2016 Calvin Metcalf & contributors
-
-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.
diff --git a/node_modules/browserify-rsa/README.md b/node_modules/browserify-rsa/README.md
deleted file mode 100644
index 70e3c02..0000000
--- a/node_modules/browserify-rsa/README.md
+++ /dev/null
@@ -1,17 +0,0 @@
-# browserify-rsa
-
-[![NPM Package](https://img.shields.io/npm/v/browserify-rsa.svg?style=flat-square)](https://www.npmjs.org/package/browserify-rsa)
-[![Build Status](https://img.shields.io/travis/crypto-browserify/browserify-rsa.svg?branch=master&style=flat-square)](https://travis-ci.org/crypto-browserify/browserify-rsa)
-[![Dependency status](https://img.shields.io/david/crypto-browserify/browserify-rsa.svg?style=flat-square)](https://david-dm.org/crypto-browserify/browserify-rsa#info=dependencies)
-
-[![js-standard-style](https://cdn.rawgit.com/feross/standard/master/badge.svg)](https://github.com/feross/standard)
-
-RSA private decryption/signing using chinese remainder and blinding.
-
-## API
-
-Give it a message as a Buffer and a private key (as decoded by `ASN.1`) and it returns encrypted data as a Buffer.
-
-## LICENSE
-
-MIT
diff --git a/node_modules/browserify-rsa/index.js b/node_modules/browserify-rsa/index.js
deleted file mode 100644
index c3ff8e9..0000000
--- a/node_modules/browserify-rsa/index.js
+++ /dev/null
@@ -1,35 +0,0 @@
-var BN = require('bn.js')
-var randomBytes = require('randombytes')
-
-function blind (priv) {
- var r = getr(priv)
- var blinder = r.toRed(BN.mont(priv.modulus)).redPow(new BN(priv.publicExponent)).fromRed()
- return { blinder: blinder, unblinder: r.invm(priv.modulus) }
-}
-
-function getr (priv) {
- var len = priv.modulus.byteLength()
- var r
- do {
- r = new BN(randomBytes(len))
- } while (r.cmp(priv.modulus) >= 0 || !r.umod(priv.prime1) || !r.umod(priv.prime2))
- return r
-}
-
-function crt (msg, priv) {
- var blinds = blind(priv)
- var len = priv.modulus.byteLength()
- var blinded = new BN(msg).mul(blinds.blinder).umod(priv.modulus)
- var c1 = blinded.toRed(BN.mont(priv.prime1))
- var c2 = blinded.toRed(BN.mont(priv.prime2))
- var qinv = priv.coefficient
- var p = priv.prime1
- var q = priv.prime2
- var m1 = c1.redPow(priv.exponent1).fromRed()
- var m2 = c2.redPow(priv.exponent2).fromRed()
- var h = m1.isub(m2).imul(qinv).umod(p).imul(q)
- return m2.iadd(h).imul(blinds.unblinder).umod(priv.modulus).toArrayLike(Buffer, 'be', len)
-}
-crt.getr = getr
-
-module.exports = crt
diff --git a/node_modules/browserify-rsa/package.json b/node_modules/browserify-rsa/package.json
deleted file mode 100644
index 679331d..0000000
--- a/node_modules/browserify-rsa/package.json
+++ /dev/null
@@ -1,58 +0,0 @@
-{
- "_from": "browserify-rsa@^4.0.1",
- "_id": "browserify-rsa@4.1.0",
- "_inBundle": false,
- "_integrity": "sha512-AdEER0Hkspgno2aR97SAf6vi0y0k8NuOpGnVH3O99rcA5Q6sh8QxcngtHuJ6uXwnfAXNM4Gn1Gb7/MV1+Ymbog==",
- "_location": "/browserify-rsa",
- "_phantomChildren": {},
- "_requested": {
- "type": "range",
- "registry": true,
- "raw": "browserify-rsa@^4.0.1",
- "name": "browserify-rsa",
- "escapedName": "browserify-rsa",
- "rawSpec": "^4.0.1",
- "saveSpec": null,
- "fetchSpec": "^4.0.1"
- },
- "_requiredBy": [
- "/browserify-sign",
- "/public-encrypt"
- ],
- "_resolved": "https://registry.npmjs.org/browserify-rsa/-/browserify-rsa-4.1.0.tgz",
- "_shasum": "b2fd06b5b75ae297f7ce2dc651f918f5be158c8d",
- "_spec": "browserify-rsa@^4.0.1",
- "_where": "/home/pruss/Dev/3-minute-website/node_modules/browserify-sign",
- "bugs": {
- "url": "https://github.com/crypto-browserify/browserify-rsa/issues"
- },
- "bundleDependencies": false,
- "dependencies": {
- "bn.js": "^5.0.0",
- "randombytes": "^2.0.1"
- },
- "deprecated": false,
- "description": "RSA for browserify",
- "devDependencies": {
- "parse-asn1": "^5.0.0",
- "standard": "^6.0.8",
- "tape": "^4.5.1"
- },
- "files": [
- "index.js"
- ],
- "homepage": "https://github.com/crypto-browserify/browserify-rsa#readme",
- "license": "MIT",
- "main": "index.js",
- "name": "browserify-rsa",
- "repository": {
- "type": "git",
- "url": "git+https://github.com/crypto-browserify/browserify-rsa.git"
- },
- "scripts": {
- "lint": "standard",
- "test": "npm run lint && npm run unit",
- "unit": "tape test/*.js"
- },
- "version": "4.1.0"
-}