CyTube/package.json
Calvin Montgomery 6043647cb7 Skip full user auth for most page renders
Previously, the user's session cookie was being checked against the
database for all non-static requests.  However, this is not really
needed and wastes resources (and is slow).

For most page views (e.g. index, channel page), just parsing the value
of the cookie is sufficient:

  * The cookies are already HMAC signed, so tampering with them ought to
    be for all reasonable purposes, impossible.
  * Assuming the worst case, all a nefarious user could manage to do is
    change the text of the "Welcome, {user}" and cause a (non-functional)
    ACP link to appear clientside, both of which are already possible by
    using the Inspect Element tool.

For authenticated pages (currently, the ACP, and anything under
/account/), the full database check is still performed (for now).
2017-08-01 21:40:26 -07:00

87 lines
2.5 KiB
JSON

{
"author": "Calvin Montgomery",
"name": "CyTube",
"description": "Online media synchronizer and chat",
"version": "3.44.0",
"repository": {
"url": "http://github.com/calzoneman/sync"
},
"license": "MIT",
"dependencies": {
"@calzoneman/jsli": "^2.0.1",
"bcrypt": "^0.8.5",
"bluebird": "^2.10.1",
"body-parser": "^1.14.0",
"cheerio": "^0.19.0",
"clone": "^1.0.2",
"compression": "^1.5.2",
"cookie-parser": "^1.4.0",
"create-error": "^0.3.1",
"csrf": "^3.0.0",
"cytube-mediaquery": "git://github.com/CyTube/mediaquery",
"cytubefilters": "git://github.com/calzoneman/cytubefilters#67c7c69a",
"express": "^4.13.3",
"express-minify": "^0.1.6",
"graceful-fs": "^4.1.2",
"http-errors": "^1.3.1",
"json-typecheck": "^0.1.3",
"knex": "^0.13.0",
"lodash": "^4.13.1",
"morgan": "^1.6.1",
"mysql": "^2.9.0",
"nodemailer": "^1.4.0",
"prom-client": "^10.0.2",
"proxy-addr": "^1.1.4",
"pug": "^2.0.0-beta3",
"q": "^1.4.1",
"redis": "^2.4.2",
"sanitize-html": "^1.14.1",
"serve-static": "^1.10.0",
"socket.io": "^2.0.3",
"source-map-support": "^0.4.0",
"sprintf-js": "^1.0.3",
"toml": "^2.3.0",
"uuid": "^2.0.1",
"yamljs": "^0.2.8"
},
"scripts": {
"build-player": "$npm_node_execpath build-player.js",
"build-server": "babel -D --source-maps --loose es6.destructuring,es6.forOf --out-dir lib/ src/",
"flow": "flow",
"postinstall": "./postinstall.sh",
"server-dev": "babel -D --watch --source-maps --loose es6.destructuring,es6.forOf --out-dir lib/ src/",
"generate-userscript": "$npm_node_execpath gdrive-userscript/generate-userscript $@ > www/js/cytube-google-drive.user.js",
"test": "mocha --recursive test",
"integration-test": "mocha --recursive integration_test"
},
"devDependencies": {
"babel-cli": "^6.24.1",
"babel-core": "^6.25.0",
"babel-plugin-add-module-exports": "^0.2.1",
"babel-plugin-transform-async-to-generator": "^6.24.1",
"babel-plugin-transform-flow-strip-types": "^6.22.0",
"babel-preset-env": "^1.5.2",
"coffee-script": "^1.9.2",
"flow-bin": "^0.43.0",
"mocha": "^3.2.0",
"sinon": "^2.3.2"
},
"babel": {
"presets": [
[
"env",
{
"targets": {
"node": "6"
}
}
]
],
"plugins": [
"transform-async-to-generator",
"add-module-exports",
"transform-flow-strip-types"
]
}
}