From 7bb47e178797f9e48f253239c3289991b34590c3 Mon Sep 17 00:00:00 2001 From: array-in-a-matrix Date: Fri, 25 Nov 2022 09:24:01 -0500 Subject: [PATCH] renamed captcha vars to new naming scheme --- docs/configuring-captcha.md | 22 +++++++++---------- .../custom/matrix-dendrite/defaults/main.yml | 14 ++++++------ .../templates/dendrite/dendrite.yaml.j2 | 12 +++++----- 3 files changed, 24 insertions(+), 24 deletions(-) diff --git a/docs/configuring-captcha.md b/docs/configuring-captcha.md index 741942e4b..173b34fe7 100644 --- a/docs/configuring-captcha.md +++ b/docs/configuring-captcha.md @@ -25,9 +25,9 @@ matrix_synapse_recaptcha_public_key: 'YOUR_SITE_KEY' matrix_synapse_recaptcha_private_key: 'YOUR_SECRET_KEY' # for Dendrite -matrix_dendrite_enable_registration_captcha: true -matrix_dendrite_recaptcha_public_key: 'YOUR_SITE_KEY' -matrix_dendrite_recaptcha_private_key: 'YOUR_SECRET_KEY' +matrix_dendrite_client_api_enable_registration_captcha: true +matrix_dendrite_client_api_recaptcha_public_key: 'YOUR_SITE_KEY' +matrix_dendrite_client_api_recaptcha_private_key: 'YOUR_SECRET_KEY' ``` ## hCaptcha @@ -41,12 +41,12 @@ Requires a site/secret key pair from: ### Setting hCaptcha keys ```yaml -matrix_dendrite_enable_registration_captcha: true -matrix_dendrite_recaptcha_public_key: 'YOUR_SITE_KEY' -matrix_dendrite_recaptcha_private_key: 'YOUR_SECRET_KEY' - -matrix_dendrite_recaptcha_siteverify_api: 'https://hcaptcha.com/siteverify' -matrix_dendrite_recaptcha_api_js_url: 'https://js.hcaptcha.com/1/api.js' -matrix_dendrite_recaptcha_form_field: 'h-captcha-response' -matrix_dendrite_recaptcha_sitekey_class: 'h-captcha' +matrix_dendrite_client_api_enable_registration_captcha: true +matrix_dendrite_client_api_recaptcha_public_key: 'YOUR_SITE_KEY' +matrix_dendrite_client_api_recaptcha_private_key: 'YOUR_SECRET_KEY' + +matrix_dendrite_client_api_recaptcha_siteverify_api: 'https://hcaptcha.com/siteverify' +matrix_dendrite_client_api_recaptcha_api_js_url: 'https://js.hcaptcha.com/1/api.js' +matrix_dendrite_client_api_recaptcha_form_field: 'h-captcha-response' +matrix_dendrite_client_api_recaptcha_sitekey_class: 'h-captcha' ``` diff --git a/roles/custom/matrix-dendrite/defaults/main.yml b/roles/custom/matrix-dendrite/defaults/main.yml index 484a5c9c7..f8f2dd189 100644 --- a/roles/custom/matrix-dendrite/defaults/main.yml +++ b/roles/custom/matrix-dendrite/defaults/main.yml @@ -97,13 +97,13 @@ matrix_dendrite_rate_limiting_cooloff_ms: 500 matrix_dendrite_registration_disabled: true # reCAPTCHA API for validating registration attempts -matrix_dendrite_enable_registration_captcha: false -matrix_dendrite_recaptcha_public_key: "" -matrix_dendrite_recaptcha_private_key: "" -matrix_dendrite_recaptcha_siteverify_api: "" -matrix_dendrite_recaptcha_api_js_url: "" -matrix_dendrite_recaptcha_form_field: "" -matrix_dendrite_recaptcha_sitekey_class: "" +matrix_dendrite_client_api_enable_registration_captcha: false +matrix_dendrite_client_api_recaptcha_public_key: "" +matrix_dendrite_client_api_recaptcha_private_key: "" +matrix_dendrite_client_api_recaptcha_siteverify_api: "" +matrix_dendrite_client_api_recaptcha_api_js_url: "" +matrix_dendrite_client_api_recaptcha_form_field: "" +matrix_dendrite_client_api_recaptcha_sitekey_class: "" # A list of additional "volumes" to mount in the container. # This list gets populated dynamically based on Dendrite extensions that have been enabled. diff --git a/roles/custom/matrix-dendrite/templates/dendrite/dendrite.yaml.j2 b/roles/custom/matrix-dendrite/templates/dendrite/dendrite.yaml.j2 index ca78e348a..0ee8cf514 100644 --- a/roles/custom/matrix-dendrite/templates/dendrite/dendrite.yaml.j2 +++ b/roles/custom/matrix-dendrite/templates/dendrite/dendrite.yaml.j2 @@ -189,13 +189,13 @@ client_api: enable_registration_captcha: {{ matrix_dendrite_enable_registration_captcha|to_json }} # Settings for ReCAPTCHA. - recaptcha_public_key: {{ matrix_dendrite_recaptcha_public_key|to_json }} - recaptcha_private_key: {{ matrix_dendrite_recaptcha_private_key|to_json }} + recaptcha_public_key: {{ matrix_dendrite_client_api_recaptcha_public_key|to_json }} + recaptcha_private_key: {{ matrix_dendrite_client_api_recaptcha_private_key|to_json }} recaptcha_bypass_secret: "" - recaptcha_siteverify_api: {{ matrix_dendrite_recaptcha_siteverify_api|to_json }} - recaptcha_api_js_url: {{ matrix_dendrite_recaptcha_api_js_url | to_json }} - recaptcha_form_field: {{ matrix_dendrite_recaptcha_form_field | to_json }} - recaptcha_sitekey_class: {{ matrix_dendrite_recaptcha_sitekey_class | to_json }} + recaptcha_siteverify_api: {{ matrix_dendrite_client_api_recaptcha_siteverify_api|to_json }} + recaptcha_api_js_url: {{ matrix_dendrite_client_api_recaptcha_api_js_url | to_json }} + recaptcha_form_field: {{ matrix_dendrite_client_api_recaptcha_form_field | to_json }} + recaptcha_sitekey_class: {{ matrix_dendrite_client_api_recaptcha_sitekey_class | to_json }} # TURN server information that this homeserver should send to clients. turn: