Merge pull request #204 from mozilla/hsts

added HSTS header
This commit is contained in:
Danny Coates 2017-07-17 16:15:32 -07:00 committed by GitHub
commit 9735aa62bd

View file

@ -32,6 +32,10 @@ app.engine(
app.set('view engine', 'handlebars'); app.set('view engine', 'handlebars');
app.use(helmet()); app.use(helmet());
app.use(helmet.hsts({
maxAge: 31536000,
force: conf.env === 'production'
}));
app.use( app.use(
helmet.contentSecurityPolicy({ helmet.contentSecurityPolicy({
directives: { directives: {