diff options
Diffstat (limited to 'middlewares')
-rw-r--r-- | middlewares/index.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/middlewares/index.js b/middlewares/index.js index c8139075a..6368d791a 100644 --- a/middlewares/index.js +++ b/middlewares/index.js | |||
@@ -39,7 +39,7 @@ | |||
39 | var signature_ok = crt.hashAndVerify('sha256', new Buffer(req.body.signature.url).toString('hex'), req.body.signature.signature, 'hex') | 39 | var signature_ok = crt.hashAndVerify('sha256', new Buffer(req.body.signature.url).toString('hex'), req.body.signature.signature, 'hex') |
40 | 40 | ||
41 | if (signature_ok === true) { | 41 | if (signature_ok === true) { |
42 | var myKey = ursa.createPrivateKey(fs.readFileSync(utils.certDir + 'petube.key.pem')) | 42 | var myKey = ursa.createPrivateKey(fs.readFileSync(utils.certDir + 'peertube.key.pem')) |
43 | var decryptedKey = myKey.decrypt(req.body.key, 'hex', 'utf8') | 43 | var decryptedKey = myKey.decrypt(req.body.key, 'hex', 'utf8') |
44 | logger.debug(decryptedKey) | 44 | logger.debug(decryptedKey) |
45 | req.body.data = JSON.parse(utils.symetricDecrypt(req.body.data, decryptedKey)) | 45 | req.body.data = JSON.parse(utils.symetricDecrypt(req.body.data, decryptedKey)) |