Uploaded image for project: 'eZ Platform Enterprise Edition'
  1. eZ Platform Enterprise Edition
  2. EZEE-2028

eZ Form captcha image is corrupted behind Varnish

    XMLWordPrintable

Details

    Description

      Currently, eZ Form captcha field doesn't work properly when Varnish is enabled. Captcha reload image request ends up with 428 Precondition Required response and an empty graphic (without any characters).

      Steps to reproduce:
      1. Create a clean eZ Platform EE installation.
      2. Create simple eZ Form using Page Builder with captcha field.
      3. Configure Varnish to work with your installation.
      4. Make sure you are not authorized by testing it e.g. using incognitto mode.
      5. Visit the front site of your installation.
      6. Hit formcaptcha.reload_image button.

      The result:
      You can see an empty captcha image and a request with the mentioned status code 428 Precondition Required

      Problem is caused by empty value of $keys variable which causes displaying of an empty captcha image.
      Ref: https://github.com/ezsystems/ezstudio-form-builder/blob/master/bundle/Controller/CaptchaController.php#L62-L65

      Attachments

        Activity

          People

            Unassigned Unassigned
            konrad.oboza@ibexa.co Konrad Oboza
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: