Adobe Commerce 2.3.6, 2.4.1 CAPTCHA in checkout not working

This article provides a patch for the issue where the CAPTCHA feature for checkout does not work as expected on the Place Order page when using third-party payment providers like Paypal Express, Payflow Pro, or CyberSource in Adobe Commerce.

This known issue is mentioned in our developer documentation:

For Adobe Commerce 2.3.6:

For Adobe Commerce 2.4.1:

Affected products and versions

  • Adobe Commerce (all deployment methods) 2.3.6 and 2.4.1
  • Magento Open Source 2.3.6 and 2.4.1

Issue

Steps to reproduce

  1. Setup at least one of these payment methods in Commerce: Paypal Express, Payflow Pro, or CyberSource.

  2. Go to Admin > Stores > Configuration > Customers > Customer Configuration > CAPTCHA .

    • Set Enable CAPTCHA on the Storefront = Yes .
    • Select in Forms : Checkout/Placing Order , Login , and Forgot password .
    • Set Displaying Mode = After number of attempts to login (to make the Number of Unsuccessful Attempts to Login setting appear).
    • Set Number of Unsuccessful Attempts to Login = 0 (to make captcha work all the time).
  3. On the frontend, add a product to the cart and try to checkout.

  4. On Payment information page, enter captcha and try to checkout with Paypal Express, Payflow Pro, or CyberSource.

Expected result:

The CAPTCHA feature functions as expected.

Actual result:

The error message displays: Please provide CAPTCHA code and try again.

Solution

Apply one of the patches below depending on whether you are on Adobe Commerce on-premises/Adobe Commerce on cloud infrastructure/Magento Open Source 2.3.6 or 2.4.1.

Patches

The patches are attached to this article, available for download in both .composer and .git formats.

To download a patch, scroll down to the end of the article and click the file name, or click one of the following links:

For Adobe Commerce on-premises/Adobe Commerce on cloud infrastructure/Magento Open Source 2.3.6 :

For Adobe Commerce on-premises/Adobe Commerce on cloud infrastructure/Magento Open Source 2.4.1 :

These patches are not compatible with any other Adobe Commerce or Magento Open Source versions and editions.

How to apply the patch

Composer patch

See How to apply a composer patch provided by Adobe in our support knowledge base for composer patch instructions.

Git patch

See developer documentation Applying patches: Custom patches for git patch instructions for Adobe Commerce/Magento Open Source.

recommendation-more-help
8bd06ef0-b3d5-4137-b74e-d7b00485808a