Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/phpmyadmin/phpmyadmin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames Renken <james@renken.is>2020-10-14 00:20:39 +0300
committerWilliam Desportes <williamdes@wdes.fr>2020-10-23 11:55:00 +0300
commitecbe0dd6d35a53583cdab8a9ecddc59d926e9759 (patch)
tree5d788774eacd4a9b80e0e750e0848f97988d1ff8 /libraries/config.default.php
parent31dddc7fb9125052c1bf190da4605d7448e2ef5f (diff)
Add config parameters to support third-party reCAPTCHA v2 compatible APIs
Signed-off-by: James Renken <james@renken.is>
Diffstat (limited to 'libraries/config.default.php')
-rw-r--r--libraries/config.default.php29
1 files changed, 29 insertions, 0 deletions
diff --git a/libraries/config.default.php b/libraries/config.default.php
index 2ee0c71a9b..db9b426276 100644
--- a/libraries/config.default.php
+++ b/libraries/config.default.php
@@ -843,6 +843,35 @@ $cfg['ArbitraryServerRegexp'] = '';
$cfg['CaptchaMethod'] = 'invisible';
/**
+ * URL for the reCaptcha v2 compatible API to use
+ *
+ * @global string $cfg['CaptchaApi']
+ */
+$cfg['CaptchaApi'] = 'https://www.google.com/recaptcha/api.js';
+
+/**
+ * Content-Security-Policy snippet for the reCaptcha v2 compatible API
+ *
+ * @global string $cfg['CaptchaCsp']
+ */
+$cfg['CaptchaCsp'] = 'https://apis.google.com https://www.google.com/recaptcha/'
+ . ' https://www.gstatic.com/recaptcha/ https://ssl.gstatic.com/';
+
+/**
+ * reCaptcha API's request parameter name
+ *
+ * @global string $cfg['CaptchaRequestParam']
+ */
+$cfg['CaptchaRequestParam'] = 'g-recaptcha';
+
+/**
+ * reCaptcha API's response parameter name
+ *
+ * @global string $cfg['CaptchaResponseParam']
+ */
+$cfg['CaptchaResponseParam'] = 'g-recaptcha-response';
+
+/**
* if reCaptcha is enabled it needs public key to connect with the service
*
* @global string $cfg['CaptchaLoginPublicKey']