I know that cookies should always have a name, but i stumbled across an issue where something injected a nameless cookie into my code (probably a third party library). But as a result, it causes the request.state to equal null.
To test this, host a site using hapi, in Firefox console...
Then reload the page (i also set my hapi server.route's config.state.failAction to 'log'), and you get the following in the console/terminal
Internal request error { header: '1', errors: null }
Needs to be a way to tell hapi to drop any invalid cookies like these.
I'm presently using hapi version 9.0.3, so i understand it is a little out of date.
Let me know if this has been fixed in a later version. If so i will look to upgrading.
I know that cookies should always have a name, but i stumbled across an issue where something injected a nameless cookie into my code (probably a third party library). But as a result, it causes the request.state to equal null.
To test this, host a site using hapi, in Firefox console...
Then reload the page (i also set my hapi server.route's config.state.failAction to 'log'), and you get the following in the console/terminal
Internal request error { header: '1', errors: null }Needs to be a way to tell hapi to drop any invalid cookies like these.
I'm presently using hapi version 9.0.3, so i understand it is a little out of date.
Let me know if this has been fixed in a later version. If so i will look to upgrading.