diff --git a/package.json b/package.json index 001866a..def49ee 100644 --- a/package.json +++ b/package.json @@ -22,7 +22,8 @@ "dependencies": { "compression": "=1.6.2", "connect-static-file": "=1.1.2", - "express": "=4.14.0" + "express": "=4.14.0", + "helmet": "=2.3.0" }, "devDependencies": { "eslint": "=1.9.0", diff --git a/server.js b/server.js index 2a728cc..a04ed7d 100644 --- a/server.js +++ b/server.js @@ -1,6 +1,7 @@ const express = require('express'); const staticFile = require('connect-static-file'); const compression = require('compression'); +const helmet = require('helmet'); const path = require('path'); const PORT = process.env.PORT || 5000; @@ -18,6 +19,7 @@ const expressConfig = { const app = express(); app.use(compression({ level: 9 })); +app.use(helmet()); app.use(function (request, response, next) {