Shortly after applying the SUPEE-9767 patch we started to receive complaints from customers that products could not be added to cart from the product detail page.

We are sometimes able to reproduce the issue, but sometimes not.

We are on a fully patched version of EE

Disabling full page cache resolves the issue.

  • <comment moved>
    – cmtickle
    Commented Jun 8, 2017 at 8:31

2 Answers 2


The issue is caused by the Enterprise Page Cache.

The form key is created at: app/code/core/Enterprise/PageCache/Model/Processor.php:422 which ultimately calls setcookie().

Then the cookie value is retrieved at: app/code/core/Enterprise/PageCache/Model/Observer.php:1043 in the same request.

As the headers/cookies have not been sent the value returned is null. This causes the core/session cookie to not update with the value Page Cache has just created which is supposed to happen at:


The patch below will resolve this issue. https://gist.github.com/cmtickle/477aba06d8d6a69148de542bfb56ed45

  • in EE the code is correct and uses a slightly better variant than what your gist uses. also, PATCH_SUPEE-9767_EE_1.14.3.2_v1-2017-05-22-07-20-39.sh does seem to modify the observer accordingly, but might be missing the Cookie.php changes. are you sure your patch applied successfully, as the end result would look different from what the gist's initial code state is...
    – alternize
    Commented Jun 7, 2017 at 22:31
  • this is part of a cache problem we reported a few weeks ago and was partly fixed as SUPEE-9805 before it was integrated in SUPEE-9767 - at least for the 1.14.3.x version, maybe it was not properly backported.
    – alternize
    Commented Jun 7, 2017 at 22:42
  • I've confirmed that the patch was applied successfully without issue. May be an issue in 1.14.2.x
    – cmtickle
    Commented Jun 8, 2017 at 7:37
  • Once my patch for the patch is applied you may need to clear Block and FP cache for it to work as expected.
    – cmtickle
    Commented Jun 8, 2017 at 8:32
  • Any idea if v1.13.1.0 is affected by this? I have a client that is having an add to cart issue since the patch, but I can't reproduce it at all.
    – Laura
    Commented Jun 9, 2017 at 14:01

We fixed a installation by backporting the PageCache module entirely from Be careful that the local pool override doesn't work, so we had to edit the core. I hope Ben Marks won't notice what I just wrote.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.