Legoktm has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/371698 )
Change subject: Archive ...................................................................... Archive Change-Id: I5e852e73e3712ad7e2e4fca38c9fbf0271096b79 --- D AccountAudit.body.php D AccountAudit.hooks.php D AccountAudit.php D COPYING D Gruntfile.js A OBSOLETE D accountaudit.sql D composer.json D extension.json D i18n/af.json D i18n/ar.json D i18n/ast.json D i18n/ba.json D i18n/bcl.json D i18n/be-tarask.json D i18n/br.json D i18n/ca.json D i18n/ce.json D i18n/cs.json D i18n/cy.json D i18n/da.json D i18n/de.json D i18n/diq.json D i18n/dsb.json D i18n/en-gb.json D i18n/en.json D i18n/eo.json D i18n/es.json D i18n/eu.json D i18n/fa.json D i18n/fi.json D i18n/fo.json D i18n/fr.json D i18n/frr.json D i18n/fur.json D i18n/gl.json D i18n/haw.json D i18n/he.json D i18n/hi.json D i18n/hrx.json D i18n/hsb.json D i18n/ia.json D i18n/id.json D i18n/ilo.json D i18n/it.json D i18n/ja.json D i18n/ka.json D i18n/ko.json D i18n/ksh.json D i18n/lb.json D i18n/lt.json D i18n/lv.json D i18n/mai.json D i18n/map-bms.json D i18n/mk.json D i18n/ml.json D i18n/mr.json D i18n/ms.json D i18n/nap.json D i18n/nb.json D i18n/ne.json D i18n/nl.json D i18n/oc.json D i18n/or.json D i18n/pl.json D i18n/pms.json D i18n/pt-br.json D i18n/pt.json D i18n/qqq.json D i18n/roa-tara.json D i18n/ru.json D i18n/sah.json D i18n/sco.json D i18n/sh.json D i18n/sk.json D i18n/sv.json D i18n/te.json D i18n/tr.json D i18n/uk.json D i18n/vi.json D i18n/yi.json D i18n/zh-hans.json D i18n/zh-hant.json D package.json D patches/add_method.sql D phpcs.xml D scripts/sul-audit.py 87 files changed, 1 insertion(+), 1,630 deletions(-) Approvals: Legoktm: Verified; Looks good to me, approved diff --git a/AccountAudit.body.php b/AccountAudit.body.php deleted file mode 100644 index fa964d9..0000000 --- a/AccountAudit.body.php +++ /dev/null @@ -1,66 +0,0 @@ -<?php - -class AccountAudit { - - const ACCESS_METHOD_DEFAULT = 0; - const ACCESS_METHOD_MOBILE = 1; - - /** - * Updates the aa_lastlogin value for the specified user - * - * @param User $user the user that just logged in - * @param int $time timestamp, 0 for current time - * - * @return bool return True to continue processing hooks - */ - static function updateLastLogin( User $user, $time = 0 ) { - - if ( wfReadOnly() ) { - return true; - } - - $db = wfGetDB( DB_MASTER ); - $method = __METHOD__; - - $requestMethod = self::ACCESS_METHOD_DEFAULT; - if ( class_exists( "MobileContext" ) && MobileContext::singleton()->shouldDisplayMobileView() ) { - $requestMethod = self::ACCESS_METHOD_MOBILE; - } - - $db->onTransactionIdle( function() use ( $user, $requestMethod, $time, $db, $method ) { - if ( $db->getType() === 'mysql' ) { // MySQL-specific implementation - $db->query( - "INSERT INTO " . $db->tableName( 'accountaudit_login' ) . - "( aa_user, aa_method, aa_lastlogin ) VALUES (" . - $db->addQuotes( $user->getId() ) . ", " . - $db->addQuotes( $requestMethod ) . ", " . - $db->addQuotes( $db->timestamp( $time ) ) . - ") ON DUPLICATE KEY UPDATE aa_lastlogin = " . - $db->addQuotes( $db->timestamp( $time ) ), - $method - ); - } else { - $db->update( - 'accountaudit_login', - [ 'aa_lastlogin' => $db->timestamp( $time ) ], - [ 'aa_user' => $user->getId(), 'aa_method' => $requestMethod ], - $method - ); - if ( $db->affectedRows() == 0 ) { // no row existed for that user, method - $db->insert( - 'accountaudit_login', - [ - 'aa_user' => $user->getId(), - 'aa_method' => $requestMethod, - 'aa_lastlogin' => $db->timestamp( $time ) - ], - $method, - [ 'IGNORE', ] - ); - } - } - } ); - // always return true, this should be a non-blocking hook on failure - return true; - } -} diff --git a/AccountAudit.hooks.php b/AccountAudit.hooks.php deleted file mode 100644 index bceaeea..0000000 --- a/AccountAudit.hooks.php +++ /dev/null @@ -1,90 +0,0 @@ -<?php - -class AccountAuditHooks { - - /** - * Implementation of the hook for onUserLoginComplete. - * - * Calls AccountAudit::updateLastLogin to update the timestamp of the last - * login for the user - * - * @param User $user - * @param $inject_html - * - * @return bool - */ - static function onUserLoginComplete( User &$user, &$inject_html ) { - - AccountAudit::updateLastLogin( $user ); - - // Always return true, we should never block execution on failure - return true; - } - - /** - * Implementation of the hook for loadExtensionSchemaUpdates - * - * Installs the requisite tables for this extension - * - * @param DatabaseUpdater $updater - * - * @return bool - */ - static function loadExtensionSchemaUpdates( DatabaseUpdater $updater ) { - $updater->addExtensionTable( 'accountaudit_login', __DIR__ . '/accountaudit.sql' ); - $updater->addExtensionField( 'accountaudit_login', 'aa_method', - __DIR__ . '/patches/add_method.sql' ); - return true; - } - - /** - * @param User $oldUser - * @param User $newUser - * @return bool - */ - public static function onMergeAccountFromTo( User &$oldUser, User &$newUser ) { - $dbr = wfGetDB( DB_SLAVE ); - // Get the last login for both old and new - $res = $dbr->select( - 'accountaudit_login', - [ 'aa_user', 'aa_lastlogin' ], - [ $dbr->makeList( [ - 'aa_user=' . $dbr->addQuotes( $oldUser->getId() ), - 'aa_user=' . $dbr->addQuotes( $newUser->getId() ), - ], LIST_OR ) ] - ); - - $greatest = 0; - foreach ( $res as $row ) { - if ( $row->aa_lastlogin > $greatest ) { - $greatest = $row->aa_lastlogin; - } - } - - if ( $greatest !== 0 ) { - // Set the last login for the new account to most recent - // of both accounts - AccountAudit::updateLastLogin( $newUser, $greatest ); - } - - return true; - } - - public static function onDeleteAccount( User &$oldUser ) { - $dbw = wfGetDB( DB_MASTER ); // Use master to be up to date - $row = $dbw->selectRow( - 'accountaudit_login', - [ 'aa_user' ], - [ 'aa_user' => $oldUser->getId() ] - ); - if ( $row !== false ) { - $dbw->onTransactionIdle( function() use ( $dbw, $oldUser ) { - $dbw->delete( - 'accountaudit_login', - [ 'aa_user' => $oldUser->getId() ], - 'AccountAuditHooks::onDeleteAccount' - ); - } ); - } - } -} diff --git a/AccountAudit.php b/AccountAudit.php deleted file mode 100644 index 1123246..0000000 --- a/AccountAudit.php +++ /dev/null @@ -1,15 +0,0 @@ -<?php -if ( function_exists( 'wfLoadExtension' ) ) { - wfLoadExtension( 'AccountAudit' ); - // Keep i18n globals so mergeMessageFileList.php doesn't break - $wgMessagesDirs['AccountAudit'] = __DIR__ . '/i18n'; - /* wfWarn( - 'Deprecated PHP entry point used for AccountAudit extension. ' . - 'Please use wfLoadExtension instead, see ' . - 'https://www.mediawiki.org/wiki/Extension_registration for more details.' - ); */ - - return; -} else { - die( 'This version of the AccountAudit extension requires MediaWiki 1.25+' ); -} diff --git a/COPYING b/COPYING deleted file mode 100644 index d159169..0000000 --- a/COPYING +++ /dev/null @@ -1,339 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - - Copyright (C) 1989, 1991 Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - - To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - - We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - - Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - - Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - - The precise terms and conditions for copying, distribution and -modification follow. - - GNU GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - - 1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - - 2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) You must cause the modified files to carry prominent notices - stating that you changed the files and the date of any change. - - b) You must cause any work that you distribute or publish, that in - whole or in part contains or is derived from the Program or any - part thereof, to be licensed as a whole at no charge to all third - parties under the terms of this License. - - c) If the modified program normally reads commands interactively - when run, you must cause it, when started running for such - interactive use in the most ordinary way, to print or display an - announcement including an appropriate copyright notice and a - notice that there is no warranty (or else, saying that you provide - a warranty) and that users may redistribute the program under - these conditions, and telling the user how to view a copy of this - License. (Exception: if the Program itself is interactive but - does not normally print such an announcement, your work based on - the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - - a) Accompany it with the complete corresponding machine-readable - source code, which must be distributed under the terms of Sections - 1 and 2 above on a medium customarily used for software interchange; or, - - b) Accompany it with a written offer, valid for at least three - years, to give any third party, for a charge no more than your - cost of physically performing source distribution, a complete - machine-readable copy of the corresponding source code, to be - distributed under the terms of Sections 1 and 2 above on a medium - customarily used for software interchange; or, - - c) Accompany it with the information you received as to the offer - to distribute corresponding source code. (This alternative is - allowed only for noncommercial distribution and only if you - received the program in object code or executable form with such - an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - - 4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - - 5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - - 6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - - 7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - - 9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - - 10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - - 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - - 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - <one line to give the program's name and a brief idea of what it does.> - Copyright (C) <year> <name of author> - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License along - with this program; if not, write to the Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - - Gnomovision version 69, Copyright (C) year name of author - Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - - Yoyodyne, Inc., hereby disclaims all copyright interest in the program - `Gnomovision' (which makes passes at compilers) written by James Hacker. - - <signature of Ty Coon>, 1 April 1989 - Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/Gruntfile.js b/Gruntfile.js deleted file mode 100644 index 1097a6c..0000000 --- a/Gruntfile.js +++ /dev/null @@ -1,32 +0,0 @@ -/*! - * Grunt file - * - * @package AccountAudit - */ - -/*jshint node:true */ -module.exports = function ( grunt ) { - grunt.loadNpmTasks( 'grunt-banana-checker' ); - grunt.loadNpmTasks( 'grunt-jsonlint' ); - grunt.loadNpmTasks( 'grunt-contrib-jshint' ); - - var conf = grunt.file.readJSON( 'extension.json' ); - grunt.initConfig( { - banana: conf.MessagesDirs, - jshint: { - all: [ - '**/*.js', - '!node_modules/**' - ] - }, - jsonlint: { - all: [ - '**/*.json', - '!node_modules/**' - ] - } - } ); - - grunt.registerTask( 'test', [ 'jsonlint', 'banana', 'jshint' ] ); - grunt.registerTask( 'default', 'test' ); -}; diff --git a/OBSOLETE b/OBSOLETE new file mode 100644 index 0000000..7dbfa40 --- /dev/null +++ b/OBSOLETE @@ -0,0 +1 @@ +This extension is OBSOLETE and shouldn't be used. diff --git a/accountaudit.sql b/accountaudit.sql deleted file mode 100644 index e3de6d7..0000000 --- a/accountaudit.sql +++ /dev/null @@ -1,15 +0,0 @@ --- --- This tables tracks the most recent login action for a user --- user_id is an effective foreign key to the user table --- -CREATE TABLE /*$wgDBprefix*/accountaudit_login ( - -- Key to user_id - aa_user int unsigned NOT NULL, - aa_method tinyint unsigned NOT NULL DEFAULT 0, - - -- This is a timestamp which is updated when a user logs in - aa_lastlogin varbinary(14) default null, - - PRIMARY KEY (aa_user, aa_method) -) /*$wgDBTableOptions*/; -CREATE INDEX /*i*/aa_lastlogin ON /*$wgDBprefix*/accountaudit_login(aa_lastlogin); diff --git a/composer.json b/composer.json deleted file mode 100644 index 3e676f3..0000000 --- a/composer.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "require-dev": { - "jakub-onderka/php-parallel-lint": "0.9.2", - "mediawiki/mediawiki-codesniffer": "0.7.2", - "jakub-onderka/php-console-highlighter": "0.3.2" - }, - "scripts": { - "test": [ - "parallel-lint . --exclude vendor", - "phpcs -p -s" - ], - "fix": [ - "phpcbf" - ] - } -} diff --git a/extension.json b/extension.json deleted file mode 100644 index be0eaef..0000000 --- a/extension.json +++ /dev/null @@ -1,35 +0,0 @@ -{ - "name": "AccountAudit", - "version": "1.0.0", - "author": [ - "Peter Gehres" - ], - "url": "https://www.mediawiki.org/wiki/Extension:AccountAudit", - "descriptionmsg": "accountaudit-desc", - "license-name": "GPL-2.0+", - "type": "other", - "Hooks": { - "UserLoginComplete": [ - "AccountAuditHooks::onUserLoginComplete" - ], - "MergeAccountFromTo": [ - "AccountAuditHooks::onMergeAccountFromTo" - ], - "DeleteAccount": [ - "AccountAuditHooks::onDeleteAccount" - ], - "LoadExtensionSchemaUpdates": [ - "AccountAuditHooks::loadExtensionSchemaUpdates" - ] - }, - "MessagesDirs": { - "AccountAudit": [ - "i18n" - ] - }, - "AutoloadClasses": { - "AccountAudit": "AccountAudit.body.php", - "AccountAuditHooks": "AccountAudit.hooks.php" - }, - "manifest_version": 1 -} diff --git a/i18n/af.json b/i18n/af.json deleted file mode 100644 index 32bebf9..0000000 --- a/i18n/af.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Naudefj" - ] - }, - "accountaudit-desc": "Kontroleer (in)aktiewe gebruikers" -} diff --git a/i18n/ar.json b/i18n/ar.json deleted file mode 100644 index 19c4f8e..0000000 --- a/i18n/ar.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Ibrahim.ID" - ] - }, - "accountaudit-desc": "مراجعة حسابات مستخدم نشط/غير نشط" -} diff --git a/i18n/ast.json b/i18n/ast.json deleted file mode 100644 index b110293..0000000 --- a/i18n/ast.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Xuacu" - ] - }, - "accountaudit-desc": "Controla les cuentes d'usuariu actives/inactives" -} diff --git a/i18n/ba.json b/i18n/ba.json deleted file mode 100644 index 4eea259..0000000 --- a/i18n/ba.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Alfiya55" - ] - }, - "accountaudit-desc": "Файҙаланыусыларҙың әүҙем/әүҙем булмаған иҫәп яҙмаларына аудит" -} diff --git a/i18n/bcl.json b/i18n/bcl.json deleted file mode 100644 index 9387df9..0000000 --- a/i18n/bcl.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Geopoet" - ] - }, - "accountaudit-desc": "Mga awdit aktibo/bakong aktibo na mga panindog nin paragamit" -} diff --git a/i18n/be-tarask.json b/i18n/be-tarask.json deleted file mode 100644 index 13ff17e..0000000 --- a/i18n/be-tarask.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Wizardist" - ] - }, - "accountaudit-desc": "Аўдыт актыўных/неактыўных рахункаў удзельнікаў" -} diff --git a/i18n/br.json b/i18n/br.json deleted file mode 100644 index 986d153..0000000 --- a/i18n/br.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Y-M D" - ] - }, - "accountaudit-desc": "Kontroliñ kontoù implijer oberiant/anoberiat" -} diff --git a/i18n/ca.json b/i18n/ca.json deleted file mode 100644 index cbafbdc..0000000 --- a/i18n/ca.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Alvaro Vidal-Abarca" - ] - }, - "accountaudit-desc": "Audita comptes d'usuari actius/inactius" -} diff --git a/i18n/ce.json b/i18n/ce.json deleted file mode 100644 index f54f3f0..0000000 --- a/i18n/ce.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Умар" - ] - }, - "accountaudit-desc": "Жигара/жигара боцу а декъашхойн дӀаяздарийн аудит" -} diff --git a/i18n/cs.json b/i18n/cs.json deleted file mode 100644 index fdd07a8..0000000 --- a/i18n/cs.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Lahwaacz", - "Mormegil" - ] - }, - "accountaudit-desc": "Audituje aktivní/neaktivní uživatelské účty" -} diff --git a/i18n/cy.json b/i18n/cy.json deleted file mode 100644 index b786d01..0000000 --- a/i18n/cy.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Lloffiwr" - ] - }, - "accountaudit-desc": "Yn archwilio cyfrifon defnyddwyr gweithgar ynteu segur" -} diff --git a/i18n/da.json b/i18n/da.json deleted file mode 100644 index ff0e485..0000000 --- a/i18n/da.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Christian List" - ] - }, - "accountaudit-desc": "Eftersyn af aktive/inaktive brugerkonti" -} diff --git a/i18n/de.json b/i18n/de.json deleted file mode 100644 index 3037ca7..0000000 --- a/i18n/de.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Kghbln", - "Metalhead64" - ] - }, - "accountaudit-desc": "Ermöglicht das Überprüfen aktiver wie inaktiver Benutzerkonten" -} diff --git a/i18n/diq.json b/i18n/diq.json deleted file mode 100644 index f0e30be..0000000 --- a/i18n/diq.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Gorizon" - ] - }, - "accountaudit-desc": "Cernabyışé aktiv yana de aktiv hesabé karberi" -} diff --git a/i18n/dsb.json b/i18n/dsb.json deleted file mode 100644 index d825cdf..0000000 --- a/i18n/dsb.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Michawiki" - ] - }, - "accountaudit-desc": "Pśepytujo aktiwne/inaktiwne wužywarske konta" -} diff --git a/i18n/en-gb.json b/i18n/en-gb.json deleted file mode 100644 index 19e2b10..0000000 --- a/i18n/en-gb.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Chase me ladies, I'm the Cavalry" - ] - }, - "accountaudit-desc": "Audits active and inactive user accounts" -} diff --git a/i18n/en.json b/i18n/en.json deleted file mode 100644 index 1b9202f..0000000 --- a/i18n/en.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "@metadata": { - "authors": [] - }, - "accountaudit-desc": "Audits active/inactive user accounts" -} \ No newline at end of file diff --git a/i18n/eo.json b/i18n/eo.json deleted file mode 100644 index e5510ab..0000000 --- a/i18n/eo.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "KuboF" - ] - }, - "accountaudit-desc": "Revizias aktivajn/neaktivajn uzanto-kontojn" -} diff --git a/i18n/es.json b/i18n/es.json deleted file mode 100644 index b4a8fc5..0000000 --- a/i18n/es.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Fitoschido", - "Miguel2706" - ] - }, - "accountaudit-desc": "Audita cuentas de usuario activos/inactivos" -} diff --git a/i18n/eu.json b/i18n/eu.json deleted file mode 100644 index e0aff3d..0000000 --- a/i18n/eu.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Theklan" - ] - }, - "accountaudit-desc": "Lankideen kontu aktibo/inaktiboak auditatzen ditu" -} diff --git a/i18n/fa.json b/i18n/fa.json deleted file mode 100644 index 1fc0720..0000000 --- a/i18n/fa.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Dalba" - ] - }, - "accountaudit-desc": "ممیزی حسابهای کاربری فعال/غیرفعال" -} diff --git a/i18n/fi.json b/i18n/fi.json deleted file mode 100644 index a77215d..0000000 --- a/i18n/fi.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Crt", - "Snidata" - ] - }, - "accountaudit-desc": "Etsii aktiiviset tai passiiviset käyttäjätunnukset." -} diff --git a/i18n/fo.json b/i18n/fo.json deleted file mode 100644 index 38dccc7..0000000 --- a/i18n/fo.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "EileenSanda" - ] - }, - "accountaudit-desc": "Endurskoðan av aktivum/inaktivum brúkarakontum" -} diff --git a/i18n/fr.json b/i18n/fr.json deleted file mode 100644 index 6ee61d4..0000000 --- a/i18n/fr.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Boniface", - "Gomoko", - "Ltrlg" - ] - }, - "accountaudit-desc": "Contrôler des comptes utilisateur actifs/inactifs" -} diff --git a/i18n/frr.json b/i18n/frr.json deleted file mode 100644 index dfa1900..0000000 --- a/i18n/frr.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Murma174" - ] - }, - "accountaudit-desc": "Onerschükt aktiif an ünaktiif brükerkontos" -} diff --git a/i18n/fur.json b/i18n/fur.json deleted file mode 100644 index 912252c..0000000 --- a/i18n/fur.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Tocaibon" - ] - }, - "accountaudit-desc": "Revision des utencis ativis/no ativis" -} diff --git a/i18n/gl.json b/i18n/gl.json deleted file mode 100644 index 3fc6374..0000000 --- a/i18n/gl.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Toliño" - ] - }, - "accountaudit-desc": "Controla as contas de usuario activas/inactivas" -} diff --git a/i18n/haw.json b/i18n/haw.json deleted file mode 100644 index d45fac0..0000000 --- a/i18n/haw.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Kolonahe" - ] - }, - "accountaudit-desc": "Hōʻoia ia i nā moʻokāki mea hoʻohana hīʻō/moe" -} diff --git a/i18n/he.json b/i18n/he.json deleted file mode 100644 index 453b934..0000000 --- a/i18n/he.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Amire80" - ] - }, - "accountaudit-desc": "ביקורת על חשבונות פעילים ובלתי־פעילים" -} diff --git a/i18n/hi.json b/i18n/hi.json deleted file mode 100644 index f925bfd..0000000 --- a/i18n/hi.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Hindustanilanguage" - ] - }, - "accountaudit-desc": "सक्रिय/असक्रिय सदस्य खातों के ऑडिट" -} diff --git a/i18n/hrx.json b/i18n/hrx.json deleted file mode 100644 index 3bf92a5..0000000 --- a/i18n/hrx.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Paul Beppler" - ] - }, - "accountaudit-desc": "Unnersucht aktive und inaktive Benutzerkonte" -} diff --git a/i18n/hsb.json b/i18n/hsb.json deleted file mode 100644 index 3ff34a0..0000000 --- a/i18n/hsb.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Michawiki" - ] - }, - "accountaudit-desc": "Přespytuje aktiwne a inaktiwne wužiwarske konta" -} diff --git a/i18n/ia.json b/i18n/ia.json deleted file mode 100644 index 1344a3b..0000000 --- a/i18n/ia.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "McDutchie" - ] - }, - "accountaudit-desc": "Controla le contos de usator active e inactive" -} diff --git a/i18n/id.json b/i18n/id.json deleted file mode 100644 index 5954731..0000000 --- a/i18n/id.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Rv77ax" - ] - }, - "accountaudit-desc": "Audit akun pengguna aktif/tidak aktif" -} diff --git a/i18n/ilo.json b/i18n/ilo.json deleted file mode 100644 index 01e3edc..0000000 --- a/i18n/ilo.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Lam-ang" - ] - }, - "accountaudit-desc": "Ammirisenna ti kuenta dagiti aktibo/inaktibo a pakabilangan ti agar-aramat" -} diff --git a/i18n/it.json b/i18n/it.json deleted file mode 100644 index f6c4e57..0000000 --- a/i18n/it.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Beta16", - "Nemo bis" - ] - }, - "accountaudit-desc": "Versione delle utenze attive/inattive" -} diff --git a/i18n/ja.json b/i18n/ja.json deleted file mode 100644 index e3ad94d..0000000 --- a/i18n/ja.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Shirayuki" - ] - }, - "accountaudit-desc": "利用者アカウントがアクティブか非アクティブか監査する" -} diff --git a/i18n/ka.json b/i18n/ka.json deleted file mode 100644 index a497069..0000000 --- a/i18n/ka.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Otogi" - ] - }, - "accountaudit-desc": "აქტიური/არააქტიური მომხმარებელთა ანგარიშის აუდიტი" -} diff --git a/i18n/ko.json b/i18n/ko.json deleted file mode 100644 index 6ed1cec..0000000 --- a/i18n/ko.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Kwj2772", - "아라" - ] - }, - "accountaudit-desc": "활동하는 사용자와 활동하지 않는 사용자 계정에 대해 검사합니다" -} diff --git a/i18n/ksh.json b/i18n/ksh.json deleted file mode 100644 index ad7a007..0000000 --- a/i18n/ksh.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Purodha" - ] - }, - "accountaudit-desc": "Zeisch de Aktiive un de Metmaacher, di heh nix donn." -} diff --git a/i18n/lb.json b/i18n/lb.json deleted file mode 100644 index a026227..0000000 --- a/i18n/lb.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Robby" - ] - }, - "accountaudit-desc": "Auditéiert aktiv resp. inaktiv Benotzerkonten." -} diff --git a/i18n/lt.json b/i18n/lt.json deleted file mode 100644 index 3840231..0000000 --- a/i18n/lt.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Mantak111" - ] - }, - "accountaudit-desc": "Aktyvūs auditai/neaktyvios narių paskyros" -} diff --git a/i18n/lv.json b/i18n/lv.json deleted file mode 100644 index eab41ca..0000000 --- a/i18n/lv.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Papuass" - ] - }, - "accountaudit-desc": "Auditē aktīvos/neaktīvos lietotāju kontus" -} diff --git a/i18n/mai.json b/i18n/mai.json deleted file mode 100644 index 814ae5f..0000000 --- a/i18n/mai.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "बिप्लब आनन्द" - ] - }, - "accountaudit-desc": "सक्रिय/निष्क्रिय प्रयोगकर्ताको खाताहरू लेखा परिक्षण गर्ने" -} diff --git a/i18n/map-bms.json b/i18n/map-bms.json deleted file mode 100644 index 041c8e9..0000000 --- a/i18n/map-bms.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "StefanusRA" - ] - }, - "accountaudit-desc": "Audit akun panganggo aktif/ora aktif" -} diff --git a/i18n/mk.json b/i18n/mk.json deleted file mode 100644 index dbd3933..0000000 --- a/i18n/mk.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Bjankuloski06" - ] - }, - "accountaudit-desc": "Проверка на активни/неактивни кориснички сметки" -} diff --git a/i18n/ml.json b/i18n/ml.json deleted file mode 100644 index 955473e..0000000 --- a/i18n/ml.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Praveenp" - ] - }, - "accountaudit-desc": "സജീവ/നിർജ്ജീവ അംഗത്വങ്ങൾ പരിശോധിക്കുക" -} diff --git a/i18n/mr.json b/i18n/mr.json deleted file mode 100644 index 9bbc0e8..0000000 --- a/i18n/mr.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "V.narsikar" - ] - }, - "accountaudit-desc": "क्रियाशील व अक्रियाशील सदस्यखात्याचे लेखापरिक्षण करते" -} diff --git a/i18n/ms.json b/i18n/ms.json deleted file mode 100644 index e14653b..0000000 --- a/i18n/ms.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Anakmalaysia" - ] - }, - "accountaudit-desc": "Mengaudit akaun pengguna yang aktif/tidak aktif" -} diff --git a/i18n/nap.json b/i18n/nap.json deleted file mode 100644 index 63721d6..0000000 --- a/i18n/nap.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "C.R." - ] - }, - "accountaudit-desc": "Versione 'e ll'utenze attive/inattive" -} diff --git a/i18n/nb.json b/i18n/nb.json deleted file mode 100644 index dca491b..0000000 --- a/i18n/nb.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Jeblad" - ] - }, - "accountaudit-desc": "Ettersyn av aktive/inaktive brukerkontoer" -} diff --git a/i18n/ne.json b/i18n/ne.json deleted file mode 100644 index 02674d1..0000000 --- a/i18n/ne.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "सरोज कुमार ढकाल" - ] - }, - "accountaudit-desc": "सक्रिय तथा निस्कृय प्रयोगकर्ताहरूको लेखा" -} diff --git a/i18n/nl.json b/i18n/nl.json deleted file mode 100644 index ad531a2..0000000 --- a/i18n/nl.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Siebrand" - ] - }, - "accountaudit-desc": "Controleert (in)actieve gebruikers" -} diff --git a/i18n/oc.json b/i18n/oc.json deleted file mode 100644 index 128edc1..0000000 --- a/i18n/oc.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Cedric31" - ] - }, - "accountaudit-desc": "Contrarotlar de comptes d'utilizaire actius/inactius" -} diff --git a/i18n/or.json b/i18n/or.json deleted file mode 100644 index a136e7c..0000000 --- a/i18n/or.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Psubhashish" - ] - }, - "accountaudit-desc": "ସକ୍ରିୟ/ନିଷ୍କ୍ରିୟ ସଭ୍ୟ ଖାତାର ତଦାରଖ" -} diff --git a/i18n/pl.json b/i18n/pl.json deleted file mode 100644 index 46d87da..0000000 --- a/i18n/pl.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "WTM" - ] - }, - "accountaudit-desc": "Audyt aktywnych/nieaktywnych kont" -} diff --git a/i18n/pms.json b/i18n/pms.json deleted file mode 100644 index 1788f7e..0000000 --- a/i18n/pms.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Dragonòt" - ] - }, - "accountaudit-desc": "A revision-a ij cont utent ativ/inativ" -} diff --git a/i18n/pt-br.json b/i18n/pt-br.json deleted file mode 100644 index 1514ded..0000000 --- a/i18n/pt-br.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Fúlvio" - ] - }, - "accountaudit-desc": "Audita contas de usuário ativas/inativas" -} diff --git a/i18n/pt.json b/i18n/pt.json deleted file mode 100644 index a3aedea..0000000 --- a/i18n/pt.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Malafaya" - ] - }, - "accountaudit-desc": "Auditar contas de utilizador ativas/inativas" -} diff --git a/i18n/qqq.json b/i18n/qqq.json deleted file mode 100644 index fa70d39..0000000 --- a/i18n/qqq.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Shirayuki", - "Umherirrender" - ] - }, - "accountaudit-desc": "{{desc|name=Account Audit|url=https://www.mediawiki.org/wiki/Extension:AccountAudit}}" -} diff --git a/i18n/roa-tara.json b/i18n/roa-tara.json deleted file mode 100644 index 10cb206..0000000 --- a/i18n/roa-tara.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Joetaras" - ] - }, - "accountaudit-desc": "Condrolle le cunde utinde attive/inattive" -} diff --git a/i18n/ru.json b/i18n/ru.json deleted file mode 100644 index f85e6f4..0000000 --- a/i18n/ru.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Putnik" - ] - }, - "accountaudit-desc": "Аудит активных/неактивных учётных записей пользователей" -} diff --git a/i18n/sah.json b/i18n/sah.json deleted file mode 100644 index 3104d19..0000000 --- a/i18n/sah.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "HalanTul" - ] - }, - "accountaudit-desc": "Кыттааччылар ааттарын туттуллуутун аудита" -} diff --git a/i18n/sco.json b/i18n/sco.json deleted file mode 100644 index 2fa58f9..0000000 --- a/i18n/sco.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "John Reid" - ] - }, - "accountaudit-desc": "Audits active/inactive uiser accoonts" -} diff --git a/i18n/sh.json b/i18n/sh.json deleted file mode 100644 index 6b279ea..0000000 --- a/i18n/sh.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "OC Ripper" - ] - }, - "accountaudit-desc": "Revidira/provjerava aktivne/neaktivne korisničke račune" -} diff --git a/i18n/sk.json b/i18n/sk.json deleted file mode 100644 index 443d7dc..0000000 --- a/i18n/sk.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Sudo77(new)" - ] - }, - "accountaudit-desc": "Audity aktívnych/neaktívnych používateľských účtov" -} diff --git a/i18n/sv.json b/i18n/sv.json deleted file mode 100644 index e866f40..0000000 --- a/i18n/sv.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Jopparn" - ] - }, - "accountaudit-desc": "Revision av aktiva/inaktiva användarkonton" -} diff --git a/i18n/te.json b/i18n/te.json deleted file mode 100644 index 66e44aa..0000000 --- a/i18n/te.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Chaduvari" - ] - }, - "accountaudit-desc": "చేతన/అచేతన వాడుకరి ఖాతాలను ఆడిట్ చేస్తుంది" -} diff --git a/i18n/tr.json b/i18n/tr.json deleted file mode 100644 index eb40e70..0000000 --- a/i18n/tr.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Joseph" - ] - }, - "accountaudit-desc": "Etkin/etkin olmayan kullanıcı hesaplarını denetimler" -} diff --git a/i18n/uk.json b/i18n/uk.json deleted file mode 100644 index 1825019..0000000 --- a/i18n/uk.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Base" - ] - }, - "accountaudit-desc": "Аудит активних/неактивних облікових записів користувачів" -} diff --git a/i18n/vi.json b/i18n/vi.json deleted file mode 100644 index 310e1cb..0000000 --- a/i18n/vi.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Minh Nguyen" - ] - }, - "accountaudit-desc": "Phần mở rộng này được sử dụng để xem mỗi tài khoản người dùng có tích cực hay không tích cực." -} diff --git a/i18n/yi.json b/i18n/yi.json deleted file mode 100644 index 6604590..0000000 --- a/i18n/yi.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "@metadata": { - "authors": [ - "פוילישער" - ] - }, - "accountaudit-desc": "אונטערזוכט אקטיווע/אומאקטיווע באניצער־קאנטעס" -} diff --git a/i18n/zh-hans.json b/i18n/zh-hans.json deleted file mode 100644 index 6928726..0000000 --- a/i18n/zh-hans.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Xiaomingyan", - "Yfdyh000" - ] - }, - "accountaudit-desc": "审核活跃/不活跃用户账户" -} diff --git a/i18n/zh-hant.json b/i18n/zh-hant.json deleted file mode 100644 index 89322e1..0000000 --- a/i18n/zh-hant.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "@metadata": { - "authors": [ - "Danny0838", - "Simon Shek", - "Cwlin0416" - ] - }, - "accountaudit-desc": "審核使用中/停止使用的使用者帳號" -} diff --git a/package.json b/package.json deleted file mode 100644 index 77e7c2f..0000000 --- a/package.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "name": "accountaudit", - "version": "0.0.0", - "private": true, - "description": "Build tools for the AccountAudit extension.", - "scripts": { - "test": "grunt test" - }, - "devDependencies": { - "grunt": "0.4.5", - "grunt-banana-checker": "0.4.0", - "grunt-cli": "0.1.13", - "grunt-contrib-jshint": "1.1.0", - "grunt-jsonlint": "1.0.7" - } -} diff --git a/patches/add_method.sql b/patches/add_method.sql deleted file mode 100644 index bd40b73..0000000 --- a/patches/add_method.sql +++ /dev/null @@ -1,5 +0,0 @@ -ALTER TABLE /*$wgDBprefix*/accountaudit_login - ADD COLUMN aa_method tinyint unsigned NOT NULL DEFAULT 0 AFTER aa_user, - DROP PRIMARY KEY, - ADD PRIMARY KEY (aa_user, aa_method) -; \ No newline at end of file diff --git a/phpcs.xml b/phpcs.xml deleted file mode 100644 index d81a292..0000000 --- a/phpcs.xml +++ /dev/null @@ -1,8 +0,0 @@ -<?xml version="1.0"?> -<ruleset> - <rule ref="vendor/mediawiki/mediawiki-codesniffer/MediaWiki"/> - <file>.</file> - <arg name="extensions" value="php,php5,inc"/> - <arg name="encoding" value="utf8"/> - <exclude-pattern>vendor</exclude-pattern> -</ruleset> diff --git a/scripts/sul-audit.py b/scripts/sul-audit.py deleted file mode 100644 index 382a0e8..0000000 --- a/scripts/sul-audit.py +++ /dev/null @@ -1,391 +0,0 @@ -#!/usr/bin/env python -# -*- coding: utf-8 -*- -# SUL audit statistics script -# Released under GPL v2 / MIT License -# -# By Legoktm, with contributions from Roan Kattouw, wctaiwan and Earwig -# -# Creates a table for usage on -# <https://www.mediawiki.org/wiki/Admin_tools_development/SUL_Audit> -# -# Dependencies: python-mysqldb package -# -# Setup: -# 1. Create a ~/sul.my.cnf with username/password/hostname of a database -# server which has a copy of all SUL databases on it -# 2. Create a file named "wikis.csv" which is a list of all database names -# that are SUL connected. - -import bisect -import calendar -import datetime -from collections import defaultdict, OrderedDict -import os -import time -import MySQLdb -import MySQLdb.cursors - - -# Taken from pywikibot -class Timestamp(datetime.datetime): - - """Class for handling Mediawiki timestamps. - - This inherits from datetime.datetime, so it can use all of the methods - and operations of a datetime object. To ensure that the results of any - operation are also a Timestamp object, be sure to use only Timestamp - objects (and datetime.timedeltas) in any operation. - - Use Timestamp.fromISOformat() and Timestamp.fromtimestampformat() to - create Timestamp objects from Mediawiki string formats. - - Use Site.getcurrenttime() for the current time; this is more reliable - than using Timestamp.utcnow(). - - """ - mediawikiTSFormat = "%Y%m%d%H%M%S" - ISO8601Format = "%Y-%m-%dT%H:%M:%SZ" - - @classmethod - def fromISOformat(cls, ts): - """Convert an ISO 8601 timestamp to a Timestamp object.""" - return cls.strptime(ts, cls.ISO8601Format) - - @classmethod - def fromtimestampformat(cls, ts): - """Convert the internal MediaWiki timestamp format to a Timestamp object.""" - return cls.strptime(ts, cls.mediawikiTSFormat) - - def toISOformat(self): - """Convert the Timestamp object to an ISO 8601 timestamp""" - return self.strftime(self.ISO8601Format) - - def totimestampformat(self): - """Convert the Timestamp object to the internal MediaWiki timestamp format.""" - return self.strftime(self.mediawikiTSFormat) - - def __str__(self): - """Return a string format recognized by the API""" - return self.toISOformat() - - # This function I didn't steal from pywikibot, it's from - # http://ruslanspivak.com/2011/07/20/how-to-convert-python-utc-datetime-object-to-unix-timestamp/ - def to_unix(self): - return calendar.timegm(self.utctimetuple()) - - def __add__(self, other): - newdt = datetime.datetime.__add__(self, other) - if isinstance(newdt, datetime.datetime): - return Timestamp(newdt.year, newdt.month, newdt.day, newdt.hour, - newdt.minute, newdt.second, newdt.microsecond, - newdt.tzinfo) - else: - return newdt - - def __sub__(self, other): - newdt = datetime.datetime.__sub__(self, other) - if isinstance(newdt, datetime.datetime): - return Timestamp(newdt.year, newdt.month, newdt.day, newdt.hour, - newdt.minute, newdt.second, newdt.microsecond, - newdt.tzinfo) - else: - return newdt - - -class SULAuditer: - def get_db(self, dbname): - """ - Get a (possibly already open) connection to a database - """ - if not dbname in self.db_cache: - self.db_cache[dbname] = MySQLdb.connect( - db=dbname, - read_default_file=os.path.expanduser('~/sul.my.cnf'), - cursorclass=MySQLdb.cursors.DictCursor - ) - return self.db_cache[dbname] - - def close_db(self, dbname): - """ - Close the connection if we already opened one - """ - if dbname in self.db_cache: - db = self.db_cache.pop(dbname) - db.close() - - def __init__(self): - self.db_cache = {} - self.local_accounts = defaultdict(int) - self.local_attached = defaultdict(int) - self.local_not_attached = defaultdict(int) - self.local_with_email = defaultdict(int) - self.local_clash_global = defaultdict(int) - self.local_clash_global_but_mergable = defaultdict(int) - self.global_accounts = 0 - self.global_clashing_accounts = 0 - - self.now_utc = Timestamp.utcnow().to_unix() - - - @property - def wikis(self): - """ - Returns a list of all wikis that are SUL enabled - """ -# return ['enwikivoyage'] # Uncomment this for fast debugging on a "medium" wiki - if not hasattr(self, '_wikis'): - with open(os.path.expanduser('~/wikis.csv')) as f: - self._wikis = f.read().splitlines() - - return self._wikis - - def round_user_ts(self, row): - """ - Given a result row with aa_lastlogin and user_touched rows, - estimate when the user was last active in months - """ - AA_DEPLOY = 20130430225551 # SELECT MIN(aa_lastlogin) on enwiki, should be a good estimate - #AA_DEPLOY = 20140702101508 # On Legoktm's local development machine - # Okay, so if a user hasn't logged in for a VERY long time, they're not in AA. - if row['aa_lastlogin']: - # Yay, they're in AA. - touched_ts = row['aa_lastlogin'] - elif row['user_touched'] and (int(row['user_touched']) < AA_DEPLOY): - # If their user_touched is before AA was deployed, use it. - touched_ts = row['user_touched'] - else: - # Their user_touched is after AA was deployed, but they've never logged in. - # So use the oldest timestamp that we know they haven't logged in since. - touched_ts = str(AA_DEPLOY) - touched = Timestamp.fromtimestampformat(touched_ts) - months = (self.now_utc - touched.to_unix()) / (60 * 60 * 24 * 30) # Okay, estimate a month is 30 days. - months += 1 # Touched in the past month (0) is "1 month" - return months - - def handle_global_user_info(self, res): - self.global_clashing_accounts += len(res) - - def handle_local_user_info(self, res): - """ - Takes a set of database results, and processes them - """ - for row in res: - months = self.round_user_ts(row) - self.local_accounts[months] += 1 - if row['lu_attached_method']: - # Linked to a global account - self.local_attached[months] += 1 - else: - self.local_not_attached[months] += 1 - if row['user_email']: - # Have an email set, but note that it might not be confirmed. - self.local_with_email[months] += 1 - if row['gu_id']: - # There is a global account, but this account is not attached. - self.local_clash_global[months] += 1 - # A local email is set AND it matches the global email - if row['user_email'] and row['gu_email_authenticated'] and (row['user_email'] == row['gu_email']): - self.local_clash_global_but_mergable[months] += 1 - - def handle_count_global_users(self, res): - self.global_accounts = res[0]['COUNT(*)'] - - def get_count_global_users(self): - cur = self.get_db('centralauth').cursor() - t = time.time() - cur.execute(""" - SELECT - COUNT(*) - FROM globaluser - """) - res = cur.fetchall() - f = time.time() - t - self.handle_count_global_users(res) - print 'centralauth: Counting all global users took %s' % f - - def get_bulk_global_user_info(self, limit=5000, last=0): - cur = self.get_db('centralauth').cursor() - t = time.time() - cur.execute(""" - SELECT - gu_id - FROM globaluser - WHERE gu_id > %s - AND ( - SELECT - COUNT(*) - FROM localuser - WHERE lu_name=gu_name - ) != ( - SELECT - COUNT(*) - FROM localnames - WHERE ln_name=gu_name - ) - LIMIT %s""", (last, limit)) - res = cur.fetchall() - f = time.time() - t - self.handle_global_user_info(res) - if res: - last_id = res[-1]['gu_id'] - else: - last_id = 0 - print 'centralauth: Fetched up til %s, took %s seconds' % (last_id, f) - return len(res), last_id - - def get_bulk_local_user_info(self, dbname, limit=5000, last=''): - """ - Does a massive SQL query to get some basic info - """ - cur = self.get_db(dbname).cursor() - t = time.time() - cur.execute(""" - SELECT - user_id, - user_name, - user_touched, - aa_lastlogin, - user_email, - lu_attached_method, - gu_id, - gu_email, - gu_email_authenticated - FROM user - LEFT JOIN centralauth.localuser AS localuser - ON user.user_name=localuser.lu_name AND lu_wiki=%s - LEFT JOIN accountaudit_login - ON user.user_id=accountaudit_login.aa_user - LEFT JOIN centralauth.globaluser AS globaluser - ON user.user_name=globaluser.gu_name - WHERE user_id > %s - ORDER BY user_id - LIMIT %s""", (dbname, last, limit)) - res = cur.fetchall() - f = time.time() - t - cur.close() - #print res - self.handle_local_user_info(res) - if res: - last_id = res[-1]['user_id'] - else: - last_id = 0 - print '%s: Fetched up til %s, took %s seconds' % (dbname, last_id, f) - return len(res), last_id - - def run_local_info(self): - limit = 5000 - for dbname in self.wikis: - print 'Starting on %s...' % dbname - count, last_id = self.get_bulk_local_user_info(dbname, limit) - while count == limit: - count, last_id = self.get_bulk_local_user_info(dbname, limit, last_id) - self.close_db(dbname) # Close our connection since we should be done here. - - def run_global_info(self): - limit = 5000 - print 'Starting to fetch global user count' - self.get_count_global_users() - print 'Starting to fetch global info' - count, last_id = self.get_bulk_global_user_info(limit) - while count == limit: - count, last_id = self.get_bulk_global_user_info(limit, last_id) - self.close_db('centralauth') - - def run(self): - self.run_local_info() - self.run_global_info() - - -class TableCreator: - - MONTHS = (1, 2, 3, 4, 5, 6, 9, 12, 18, 24, 30, 36) - - def find_adjusted_month(self, m): - if m > 36: - return 'max' - return self.MONTHS[bisect.bisect_left(self.MONTHS, m)] - - def clean_global_dict(self, data): - l = [data] - for m in self.MONTHS: - l.append('-') - return l - - def clean_dict(self, data): - l = [] - # Do a bit of rounding here... - for m in list(data): - if not m in self.MONTHS: - data[self.find_adjusted_month(m)] += data.pop(m) - for m in TableCreator.MONTHS: - l.append(data[m]) - - # Ugh hack to handle - rows - if type(l[0]) == int: - cum = sum(l) - l.insert(0, sum(l) + data['max']) - else: - cum = '-' - l.insert(0, '-') - - # Add Keegan's cumulative row - l.append(cum) - - return l - - def format_num(self, foo): - if isinstance(foo, (int, long)): - foo = '{{formatnum:%s}}' % foo - return foo - - def add_table_row(self, desc, cleaned_data): - cleaned_data.insert(0, "''%s''" % desc) - return "\n|" + ' || '.join(self.format_num(foo) for foo in cleaned_data) + '\n|-' - - def create_table(self, audit): - mapper = OrderedDict([ - ('total', audit.local_accounts), - ('attached accounts', audit.local_attached), - ('non-attached accounts', audit.local_not_attached), - ('... with e-mail', audit.local_with_email), - ('... who do not clash with another account', defaultdict(lambda: '-')), # TODO - ('... who clash with a global account', audit.local_clash_global), - ('... global clash but appear to be merge-able', audit.local_clash_global_but_mergable), - ('... who clash with 1 or more local accounts', defaultdict(lambda: '-')), # TODO - ('... local clash but appear to be merge-able', defaultdict(lambda: '-')), # TODO - ]) - - gbl_mapper = OrderedDict([ - ('total', audit.global_accounts), - ('... who clash with 1 or more local accounts', audit.global_clashing_accounts), - ('... who do not clash with local accounts', audit.global_accounts-audit.global_clashing_accounts), - ]) - - text = """ -{| class="wikitable" style="text-align: center;" -|- -! rowspan="2" colspan="2" | Group !! rowspan="2" | Total !! colspan="13" | Accounts touched in last ... !! rowspan="2" | Group name -|- -! 1mo !! 2mo !! 3mo !! 4mo !! 5mo !! 6mo !! 9mo !! 12mo !! 18mo !! 24mo !! 30mo !! 36mo !! 1-36mo -|- -! rowspan="9" | Local accounts""" - for desc in mapper: - cleaned = self.clean_dict(mapper[desc]) - text += self.add_table_row(desc, cleaned) - # Now global stuff! - text += '\n! rowspan="3" | Global accounts' - for desc in gbl_mapper: - cleaned = self.clean_global_dict(gbl_mapper[desc]) - text += self.add_table_row(desc, cleaned) - text += '|}' - return text - - -if __name__ == '__main__': - audit = SULAuditer() - audit.run() - tc = TableCreator() - table = tc.create_table(audit) - # TODO, log this to a wiki page? - with open(os.path.expanduser('~/sul/table.wikitext'), 'w') as f: - f.write(table) -- To view, visit https://gerrit.wikimedia.org/r/371698 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I5e852e73e3712ad7e2e4fca38c9fbf0271096b79 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/AccountAudit Gerrit-Branch: master Gerrit-Owner: Legoktm <lego...@member.fsf.org> Gerrit-Reviewer: Legoktm <lego...@member.fsf.org> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits