3 use MediaWiki\Auth\AuthenticationRequest;
6 * Authentication request for ReCaptcha v2. Unlike the parent class, no session storage is used
7 * and there is no ID; Google provides a single proof string after successfully solving a captcha.
9 class ReCaptchaNoCaptchaAuthenticationRequest extends CaptchaAuthenticationRequest {
10 public function __construct() {
11 parent::__construct( null, null );
14 public function loadFromSubmission( array $data ) {
15 // unhack the hack in parent
16 return AuthenticationRequest::loadFromSubmission( $data );
19 public function getFieldInfo() {
20 $fieldInfo = parent::getFieldInfo();
25 'label' => $fieldInfo['captchaInfo']['label'],
26 'help' => wfMessage( 'renocaptcha-help' ),