Gergő Tisza has uploaded a new change for review. https://gerrit.wikimedia.org/r/303966
Change subject: Rename 'authmanager' log channel to 'authevents' ...................................................................... Rename 'authmanager' log channel to 'authevents' Change-Id: I86f54474714fee19e18dabe7c523ebe1901e51a5 --- M SimpleCaptcha/Captcha.php M includes/auth/CaptchaPreAuthenticationProvider.php 2 files changed, 13 insertions(+), 16 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ConfirmEdit refs/changes/66/303966/1 diff --git a/SimpleCaptcha/Captcha.php b/SimpleCaptcha/Captcha.php index 28debde..532092f 100644 --- a/SimpleCaptcha/Captcha.php +++ b/SimpleCaptcha/Captcha.php @@ -205,7 +205,7 @@ wfDebug( "ConfirmEdit: user group allows skipping captcha on account creation\n" ); return true; } - LoggerFactory::getInstance( 'authmanager' )->info( 'Captcha shown on account creation', [ + LoggerFactory::getInstance( 'authevents' )->info( 'Captcha shown on account creation', [ 'event' => 'captcha.display', 'type' => 'accountcreation', ] ); @@ -251,7 +251,7 @@ if ( $perIPTriggered || $perUserTriggered ) { global $wgOut; - LoggerFactory::getInstance( 'authmanager' )->info( 'Captcha shown on login', [ + LoggerFactory::getInstance( 'authevents' )->info( 'Captcha shown on login', [ 'event' => 'captcha.display', 'type' => 'login', 'perIp' => $perIPTriggered, @@ -868,9 +868,7 @@ if ( $this->needCreateAccountCaptcha() ) { $this->trigger = "new account '" . $u->getName() . "'"; $success = $this->passCaptchaLimitedFromRequest( $wgRequest, $wgUser ); - LoggerFactory::getInstance( - 'authmanager' - )->info( 'Captcha submitted on account creation', [ + LoggerFactory::getInstance( 'authevents' )->info( 'Captcha submitted on account creation', [ 'event' => 'captcha.submit', 'type' => 'accountcreation', 'successful' => $success, @@ -933,7 +931,7 @@ $this->trigger = "post-badlogin login '" . $u->getName() . "'"; $success = $this->passCaptchaLimitedFromRequest( $wgRequest, $wgUser ); - LoggerFactory::getInstance( 'authmanager' )->info( 'Captcha submitted on login', [ + LoggerFactory::getInstance( 'authevents' )->info( 'Captcha submitted on login', [ 'event' => 'captcha.submit', 'type' => 'login', 'successful' => $success, @@ -1274,12 +1272,11 @@ $this->addCaptchaAPI( $result ); $result['result'] = 'NeedCaptcha'; - LoggerFactory::getInstance( - 'authmanager' - )->info( 'Captcha data added in account creation API', [ - 'event' => 'captcha.display', - 'type' => 'accountcreation', - ] ); + LoggerFactory::getInstance( 'authevents' ) + ->info( 'Captcha data added in account creation API', [ + 'event' => 'captcha.display', + 'type' => 'accountcreation', + ] ); break; } diff --git a/includes/auth/CaptchaPreAuthenticationProvider.php b/includes/auth/CaptchaPreAuthenticationProvider.php index 9095368..d877854 100644 --- a/includes/auth/CaptchaPreAuthenticationProvider.php +++ b/includes/auth/CaptchaPreAuthenticationProvider.php @@ -17,7 +17,7 @@ $needed = $captcha->needCreateAccountCaptcha( $user ?: new User() ); if ( $needed ) { $captcha->setAction( 'accountcreate' ); - LoggerFactory::getInstance( 'authmanager' ) + LoggerFactory::getInstance( 'authevents' ) ->info( 'Captcha shown on account creation', [ 'event' => 'captcha.display', 'type' => 'accountcreation', @@ -46,7 +46,7 @@ ) { $needed = true; $captcha->setAction( 'badlogin' ); - LoggerFactory::getInstance( 'authmanager' ) + LoggerFactory::getInstance( 'authevents' ) ->info( 'Captcha shown on account creation', [ 'event' => 'captcha.display', 'type' => 'accountcreation', @@ -74,7 +74,7 @@ $captcha->setAction( 'badlogin' ); $captcha->setTrigger( "post-badlogin login '$username'" ); $success = $this->verifyCaptcha( $captcha, $reqs, new User() ); - LoggerFactory::getInstance( 'authmanager' )->info( 'Captcha submitted on login', [ + LoggerFactory::getInstance( 'authevents' )->info( 'Captcha submitted on login', [ 'event' => 'captcha.submit', 'type' => 'login', 'successful' => $success, @@ -99,7 +99,7 @@ $captcha->setAction( 'accountcreate' ); $captcha->setTrigger( "new account '$username'" ); $success = $this->verifyCaptcha( $captcha, $reqs, $user ); - LoggerFactory::getInstance( 'authmanager' )->info( 'Captcha submitted on account creation', [ + LoggerFactory::getInstance( 'authevents' )->info( 'Captcha submitted on account creation', [ 'event' => 'captcha.submit', 'type' => 'accountcreation', 'successful' => $success, -- To view, visit https://gerrit.wikimedia.org/r/303966 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I86f54474714fee19e18dabe7c523ebe1901e51a5 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/ConfirmEdit Gerrit-Branch: master Gerrit-Owner: Gergő Tisza <gti...@wikimedia.org> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits