Support » Plugin: Query Monitor » Authentication cookie does not work in Pantheon hosting

  • Resolved Carl Alberto

    (@carl-alberto)


    I personally liked this plugin but it has been a mystery for me and a lot of Pantheon users that the authentication cookie is not working as it is very essential in troubleshooting logged out users.

    This issue seemed to be similar to another plugin that we were able to find out the culprit https://wordpress.org/support/topic/troubleshooting-mode-in-pantheon-hosting-do-not-work/

    It seems the cookie is being stripped by the Pantheon’s Varnish cache layer not letting it pass as per naming specifications defined in the platform’s Varnish configuration: https://pantheon.io/docs/cookies/#cache-busting-cookies, any cookie that do not have a wp- prefix is being stripped.

    I tried it in my test environment and I was able to make the authentication cookie work by replacing the code that sets the cooke from query_monitor_ to wp-query_monitor_.

    I hope renaming that cookie wont affect any install and would love to do a PR for that solution if it is ok with you or if there is any alternative solution that you can suggest to make it work in the platform.

    Thank you for making this awesome troubleshooting plugin!

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author John Blackbourn

    (@johnbillion)

    WordPress Core Developer

    Thanks for the message. I seem to recall a similar problem with my User Switching plugin, which now uses wordpress_ as a prefix for its cookie names. I’m not sure why I chose wordpress_ instead of wp- though – I’ll have a dig through the history and see what I can find.

    Using wordpress_ or wp- as a cookie prefix seems to be working in the platform.

    Thanks for checking this out.

    Plugin Author John Blackbourn

    (@johnbillion)

    WordPress Core Developer

    Fixed in version 3.3.

    Carl Alberto

    (@carl-alberto)

    Thank you very much!

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.