Created
February 23, 2025 17:09
-
-
Save ciencia/8c776d095f36f7267072d8d09640020c to your computer and use it in GitHub Desktop.
MediaWiki extension ConfirmEdit log captcha challenge information (REL1_43)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/SimpleCaptcha/SimpleCaptcha.php b/SimpleCaptcha/SimpleCaptcha.php | |
index 10d42088..610a6bac 100644 | |
--- a/SimpleCaptcha/SimpleCaptcha.php | |
+++ b/SimpleCaptcha/SimpleCaptcha.php | |
@@ -1072,13 +1072,13 @@ class SimpleCaptcha { | |
$info = $this->retrieveCaptcha( $index ); | |
if ( $info ) { | |
if ( $this->keyMatch( $word, $info ) ) { | |
- $this->log( "passed" ); | |
+ $this->log( "Captcha $index passed with word $word ({$info['question']})" ); | |
$this->clearCaptcha( $index ); | |
$this->setCaptchaSolved( true ); | |
return true; | |
} else { | |
$this->clearCaptcha( $index ); | |
- $this->log( "bad form input" ); | |
+ $this->log( "Captcha $index failed: bad form input $word ({$info['question']})" ); | |
$this->setCaptchaSolved( false ); | |
return false; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment