mirror of
https://github.com/lkddi/Xboard.git
synced 2026-04-28 06:47:24 +08:00
eat: add reCAPTCHA v3 and Cloudflare Turnstile verification support
- Implement reCAPTCHA v3 with score-based validation - Add Cloudflare Turnstile as captcha alternative - Create reusable CaptchaService for unified validation - Support switching between recaptcha, recaptcha-v3, and turnstile - Maintain backward compatibility with existing configurations
This commit is contained in:
Vendored
+14
-14
File diff suppressed because one or more lines are too long
@@ -16,7 +16,7 @@
|
||||
title: 'Xboard',
|
||||
version: '1.0.0',
|
||||
logo: 'https://xboard.io/i6mages/logo.png',
|
||||
secure_path: '/6a416b7a',
|
||||
secure_path: '/22aba88a',
|
||||
}
|
||||
</script>
|
||||
<script src="./locales/en-US.js"></script>
|
||||
|
||||
Vendored
+51
-11
@@ -416,20 +416,60 @@ window.XBOARD_TRANSLATIONS['en-US'] = {
|
||||
"description": "Enter the allowed email suffixes, one per line"
|
||||
}
|
||||
},
|
||||
"recaptcha": {
|
||||
"captcha": {
|
||||
"enable": {
|
||||
"label": "Enable reCAPTCHA",
|
||||
"description": "When enabled, users will need to pass reCAPTCHA verification when registering."
|
||||
"label": "Enable Captcha",
|
||||
"description": "When enabled, users will need to pass captcha verification when registering."
|
||||
},
|
||||
"key": {
|
||||
"label": "reCAPTCHA Key",
|
||||
"placeholder": "Enter reCAPTCHA key",
|
||||
"description": "Enter your reCAPTCHA key"
|
||||
"type": {
|
||||
"label": "Captcha Type",
|
||||
"description": "Select the captcha service type to use",
|
||||
"options": {
|
||||
"recaptcha": "Google reCAPTCHA v2",
|
||||
"recaptcha-v3": "Google reCAPTCHA v3",
|
||||
"turnstile": "Cloudflare Turnstile"
|
||||
}
|
||||
},
|
||||
"siteKey": {
|
||||
"label": "reCAPTCHA Site Key",
|
||||
"placeholder": "Enter reCAPTCHA site key",
|
||||
"description": "Enter your reCAPTCHA site key"
|
||||
"recaptcha": {
|
||||
"key": {
|
||||
"label": "reCAPTCHA Key",
|
||||
"placeholder": "Enter reCAPTCHA key",
|
||||
"description": "Enter your reCAPTCHA key"
|
||||
},
|
||||
"siteKey": {
|
||||
"label": "reCAPTCHA Site Key",
|
||||
"placeholder": "Enter reCAPTCHA site key",
|
||||
"description": "Enter your reCAPTCHA site key"
|
||||
}
|
||||
},
|
||||
"recaptcha_v3": {
|
||||
"secretKey": {
|
||||
"label": "reCAPTCHA v3 Key",
|
||||
"placeholder": "Enter reCAPTCHA v3 key",
|
||||
"description": "Enter your reCAPTCHA v3 server key"
|
||||
},
|
||||
"siteKey": {
|
||||
"label": "reCAPTCHA v3 Site Key",
|
||||
"placeholder": "Enter reCAPTCHA v3 site key",
|
||||
"description": "Enter your reCAPTCHA v3 site key"
|
||||
},
|
||||
"scoreThreshold": {
|
||||
"label": "Score Threshold",
|
||||
"placeholder": "0.5",
|
||||
"description": "Set verification score threshold (0-1), higher scores indicate more likely human behavior"
|
||||
}
|
||||
},
|
||||
"turnstile": {
|
||||
"secretKey": {
|
||||
"label": "Turnstile Key",
|
||||
"placeholder": "Enter Turnstile key",
|
||||
"description": "Enter your Cloudflare Turnstile key"
|
||||
},
|
||||
"siteKey": {
|
||||
"label": "Turnstile Site Key",
|
||||
"placeholder": "Enter Turnstile site key",
|
||||
"description": "Enter your Cloudflare Turnstile site key"
|
||||
}
|
||||
}
|
||||
},
|
||||
"registerLimit": {
|
||||
|
||||
Vendored
+33
-11
@@ -414,20 +414,42 @@ window.XBOARD_TRANSLATIONS['ko-KR'] = {
|
||||
"description": "허용된 이메일 접미사를 한 줄에 하나씩 입력하세요"
|
||||
}
|
||||
},
|
||||
"recaptcha": {
|
||||
"captcha": {
|
||||
"enable": {
|
||||
"label": "reCAPTCHA 활성화",
|
||||
"description": "활성화하면 사용자는 등록 시 reCAPTCHA 인증을 통과해야 합니다."
|
||||
"label": "캡차 활성화",
|
||||
"description": "활성화하면 사용자는 등록 시 캡차 인증을 통과해야 합니다."
|
||||
},
|
||||
"key": {
|
||||
"label": "reCAPTCHA 키",
|
||||
"placeholder": "reCAPTCHA 키 입력",
|
||||
"description": "reCAPTCHA 키를 입력하세요"
|
||||
"type": {
|
||||
"label": "캡차 유형",
|
||||
"description": "사용할 캡차 서비스 유형을 선택하세요",
|
||||
"options": {
|
||||
"recaptcha": "Google reCAPTCHA v2",
|
||||
"turnstile": "Cloudflare Turnstile"
|
||||
}
|
||||
},
|
||||
"siteKey": {
|
||||
"label": "reCAPTCHA 사이트 키",
|
||||
"placeholder": "reCAPTCHA 사이트 키 입력",
|
||||
"description": "reCAPTCHA 사이트 키를 입력하세요"
|
||||
"recaptcha": {
|
||||
"key": {
|
||||
"label": "reCAPTCHA 키",
|
||||
"placeholder": "reCAPTCHA 키 입력",
|
||||
"description": "reCAPTCHA 키를 입력하세요"
|
||||
},
|
||||
"siteKey": {
|
||||
"label": "reCAPTCHA 사이트 키",
|
||||
"placeholder": "reCAPTCHA 사이트 키 입력",
|
||||
"description": "reCAPTCHA 사이트 키를 입력하세요"
|
||||
}
|
||||
},
|
||||
"turnstile": {
|
||||
"secretKey": {
|
||||
"label": "Turnstile 키",
|
||||
"placeholder": "Turnstile 키 입력",
|
||||
"description": "Cloudflare Turnstile 키를 입력하세요"
|
||||
},
|
||||
"siteKey": {
|
||||
"label": "Turnstile 사이트 키",
|
||||
"placeholder": "Turnstile 사이트 키 입력",
|
||||
"description": "Cloudflare Turnstile 사이트 키를 입력하세요"
|
||||
}
|
||||
}
|
||||
},
|
||||
"registerLimit": {
|
||||
|
||||
Vendored
+51
-11
@@ -336,20 +336,60 @@ window.XBOARD_TRANSLATIONS['zh-CN'] = {
|
||||
"description": "输入允许的邮箱后缀,每行一个"
|
||||
}
|
||||
},
|
||||
"recaptcha": {
|
||||
"captcha": {
|
||||
"enable": {
|
||||
"label": "启用reCAPTCHA",
|
||||
"description": "开启后用户注册时需要通过reCAPTCHA验证。"
|
||||
"label": "启用验证码",
|
||||
"description": "开启后用户注册时需要通过验证码验证。"
|
||||
},
|
||||
"key": {
|
||||
"label": "reCAPTCHA密钥",
|
||||
"placeholder": "输入reCAPTCHA密钥",
|
||||
"description": "输入您的reCAPTCHA密钥"
|
||||
"type": {
|
||||
"label": "验证码类型",
|
||||
"description": "选择要使用的验证码服务类型",
|
||||
"options": {
|
||||
"recaptcha": "Google reCAPTCHA v2",
|
||||
"recaptcha-v3": "Google reCAPTCHA v3",
|
||||
"turnstile": "Cloudflare Turnstile"
|
||||
}
|
||||
},
|
||||
"siteKey": {
|
||||
"label": "reCAPTCHA站点密钥",
|
||||
"placeholder": "输入reCAPTCHA站点密钥",
|
||||
"description": "输入您的reCAPTCHA站点密钥"
|
||||
"recaptcha": {
|
||||
"key": {
|
||||
"label": "reCAPTCHA密钥",
|
||||
"placeholder": "输入reCAPTCHA密钥",
|
||||
"description": "输入您的reCAPTCHA密钥"
|
||||
},
|
||||
"siteKey": {
|
||||
"label": "reCAPTCHA站点密钥",
|
||||
"placeholder": "输入reCAPTCHA站点密钥",
|
||||
"description": "输入您的reCAPTCHA站点密钥"
|
||||
}
|
||||
},
|
||||
"recaptcha_v3": {
|
||||
"secretKey": {
|
||||
"label": "reCAPTCHA v3密钥",
|
||||
"placeholder": "输入reCAPTCHA v3密钥",
|
||||
"description": "输入您的reCAPTCHA v3服务器密钥"
|
||||
},
|
||||
"siteKey": {
|
||||
"label": "reCAPTCHA v3站点密钥",
|
||||
"placeholder": "输入reCAPTCHA v3站点密钥",
|
||||
"description": "输入您的reCAPTCHA v3站点密钥"
|
||||
},
|
||||
"scoreThreshold": {
|
||||
"label": "分数阈值",
|
||||
"placeholder": "0.5",
|
||||
"description": "设置验证分数阈值(0-1),分数越高表示越可能是真人操作"
|
||||
}
|
||||
},
|
||||
"turnstile": {
|
||||
"secretKey": {
|
||||
"label": "Turnstile密钥",
|
||||
"placeholder": "输入Turnstile密钥",
|
||||
"description": "输入您的Cloudflare Turnstile密钥"
|
||||
},
|
||||
"siteKey": {
|
||||
"label": "Turnstile站点密钥",
|
||||
"placeholder": "输入Turnstile站点密钥",
|
||||
"description": "输入您的Cloudflare Turnstile站点密钥"
|
||||
}
|
||||
}
|
||||
},
|
||||
"registerLimit": {
|
||||
|
||||
Reference in New Issue
Block a user