Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Invalid cookie header despite strictHeader: false, ignoreErrors: true #3516

Closed
danielb2 opened this issue Jun 7, 2017 · 0 comments
Closed
Assignees
Labels
bug Bug or defect dependency Update module dependency
Milestone

Comments

@danielb2
Copy link
Contributor

danielb2 commented Jun 7, 2017

What are you trying to achieve or the steps to reproduce?

Invalid cookie header despite strictHeader: false, ignoreErrors: true

when sending ;;

const Hapi = require('hapi');
const Hoek = require('hoek');
const server = new Hapi.Server();

server.connection({
    port: 8411,
    state: {
        strictHeader: false,
        ignoreErrors: true
    }
});

server.start((err) => {

    Hoek.assert(!err, err);
    console.log('Server started at: ' + server.info.uri);
});

const handler = function (request, reply) {

    return reply('omg');
};

server.route({ method: 'GET', path: '/', handler });

curl 'http://localhost:8411' -H 'Cookie: foo=bar;;'

What was the result you received?

{"statusCode":400,"error":"Bad Request","message":"Invalid cookie header"}

What did you expect?

omg

Context

  • node version: v6.9.1
  • hapi version: 16.4.1
  • os: Darwin nero.local 16.0.0 Darwin Kernel Version 16.0.0:
@hueniverse hueniverse self-assigned this Jul 20, 2017
@hueniverse hueniverse added bug Bug or defect dependency Update module dependency labels Jul 20, 2017
@hueniverse hueniverse added this to the 16.5.0 milestone Jul 20, 2017
@lock lock bot locked as resolved and limited conversation to collaborators Jan 9, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Bug or defect dependency Update module dependency
Projects
None yet
Development

No branches or pull requests

2 participants