Skip to content

Commit

Permalink
Combine CORS and CSRF into new "security" hook
Browse files Browse the repository at this point in the history
Also streamlines CSRF settings:
 * Makes the former `/csrfToken` route into an action for the user to bind themselves
 * Supports `csrf: true` and `csrf: false` on a per-route basis instead of the `routesDisabled` list
 * No longer supports CSRF-specific CORS settings
  • Loading branch information
sgress454 committed Oct 20, 2016
1 parent 9ce56ff commit 7328c05
Show file tree
Hide file tree
Showing 14 changed files with 573 additions and 935 deletions.
3 changes: 1 addition & 2 deletions lib/app/configuration/default-hooks.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ module.exports = {
'pubsub': true,
'policies': true,
'services': true,
'csrf': true,
'cors': true,
'security': true,
'i18n': true,
'userconfig': true,
'session': true,
Expand Down
16 changes: 0 additions & 16 deletions lib/hooks/cors/clear-headers.js

This file was deleted.

235 changes: 0 additions & 235 deletions lib/hooks/cors/index.js

This file was deleted.

Loading

0 comments on commit 7328c05

Please sign in to comment.