From 9188cf251b80098192e9fbc31ea70c874080e3a6 Mon Sep 17 00:00:00 2001 From: SlushUwU <105487011+SlushUwU@users.noreply.github.com> Date: Wed, 22 Feb 2023 13:14:10 +0100 Subject: [PATCH] Add CloudFlare Turnstile captcha example (#18098) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Added reCaptcha example for CloudFlare Turnstile Cloudflare Developer Page for Turnstile: https://developers.cloudflare.com/turnstile/get-started/ Pull-Request: #18098 Cherry-picked-from: d10b5d9e4ea119e9e2ff19f8747a8ef342e5c09a Signed-off-by: SlushUwU Co-authored-by: MaurĂ­cio Meneghini Fauth Co-authored-by: William Desportes --- doc/config.rst | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/doc/config.rst b/doc/config.rst index 1d94c70722..0f0350ab6d 100644 --- a/doc/config.rst +++ b/doc/config.rst @@ -4071,3 +4071,20 @@ reCaptcha using hCaptcha .. seealso:: `hCaptcha website `_ .. seealso:: `hCaptcha Developer Guide `_ + +reCaptcha using Turnstile ++++++++++++++++++++++++++ + +.. code-block:: php + + $cfg['CaptchaMethod'] = 'checkbox'; + $cfg['CaptchaApi'] = 'https://challenges.cloudflare.com/turnstile/v0/api.js'; + $cfg['CaptchaCsp'] = 'https://challenges.cloudflare.com https://static.cloudflareinsights.com'; + $cfg['CaptchaRequestParam'] = 'cf-turnstile'; + $cfg['CaptchaResponseParam'] = 'cf-turnstile-response'; + $cfg['CaptchaLoginPublicKey'] = '0xxxxxxxxxxxxxxxxxxxxxx'; + $cfg['CaptchaLoginPrivateKey'] = '0x4AAAAAAAA_xx_xxxxxxxxxxxxxxxxxxxx'; + $cfg['CaptchaSiteVerifyURL'] = 'https://challenges.cloudflare.com/turnstile/v0/siteverify'; + +.. seealso:: `Cloudflare Dashboard `_ +.. seealso:: `Turnstile Developer Guide `_