Go to file
Bartosz Dziewoński 069e0c89a5 Provide page text and edit summary when filtering file uploads
This allows filters using `action='upload'` to use the variables
`summary`, `new_wikitext` and several others that previously were only
provided when editing pages (`action='edit'`).

This is achieved using the new UploadVerifyUpload hook, introduced in
MediaWiki core in change Ie68801b307de8456e1753ba54a29c34c8063bc36.

`action='upload'` is now only used when publishing an upload, and not
for uploads to stash. A new `action='stashupload'` is introduced,
which is used for all uploads, including uploads to stash. This
behaves like `action='upload'` used to, and only provides file
metadata variables.

Filter authors should use `action='stashupload'` when a file can be
checked based only on the file contents, and `action='upload'` only
when the wikitext edit needs to be examined too.

Bug: T87381
Bug: T89252
Bug: T139848
Change-Id: I9654f82ecda82e4917fd0ac6b364b947a1434c73
2016-07-09 13:31:15 +00:00
api Remove executable bit from files 2016-04-08 14:00:52 +00:00
db_patches abuse_filter_log table only uses tinyint not int for namespace ID 2014-03-04 02:24:27 +00:00
i18n Localisation updates from https://translatewiki.net. 2016-06-15 22:31:41 +02:00
maintenance Add support for PHP CodeSniffer checks 2016-01-06 09:59:47 -08:00
modules Compress PNGs with zopflipng 2016-02-21 00:51:11 +00:00
special Merge "Use msg() from Context instead of wfMessage() where possible" 2016-06-12 02:06:47 +00:00
tests Optimize 'count()' function 2016-04-17 08:32:27 +02:00
Views Change some globals to work better with extension registration 2016-06-06 19:53:53 +00:00
.gitignore Add support for PHP CodeSniffer checks 2016-01-06 09:59:47 -08:00
.gitreview Add .gitreview file 2012-03-22 13:55:41 -07:00
.jshintignore Add npm entry point 2016-02-29 19:52:23 +00:00
.jshintrc Add npm entry point 2016-02-29 19:52:23 +00:00
AbuseFilter.alias.php Localisation updates from https://translatewiki.net. 2015-06-14 21:00:08 +02:00
AbuseFilter.class.php Cache AbuseFilter::checkAllFilters during edit stashing 2016-06-14 04:26:14 -07:00
AbuseFilter.hooks.php Provide page text and edit summary when filtering file uploads 2016-07-09 13:31:15 +00:00
AbuseFilter.parser.php Optimize 'rcount()' function 2016-04-27 18:01:56 +02:00
AbuseFilter.php Change some globals to work better with extension registration 2016-06-06 19:53:53 +00:00
abusefilter.tables.pg.sql abuse_filter_log table only uses tinyint not int for namespace ID 2014-03-04 02:24:27 +00:00
abusefilter.tables.sql abuse_filter_log table only uses tinyint not int for namespace ID 2014-03-04 02:24:27 +00:00
abusefilter.tables.sqlite.sql abuse_filter_log table only uses tinyint not int for namespace ID 2014-03-04 02:24:27 +00:00
AbuseFilterPreAuthenticationProvider.php Update for AuthManager 2016-06-06 19:54:26 +00:00
AbuseFilterTokenizer.php Remove unnecessary phpcs overrides 2016-04-12 12:36:06 +00:00
AbuseFilterVariableHolder.php Save upload related title vars in ARTICLE prefix not FILE 2016-04-02 23:13:38 +01:00
AbuseLogHitFormatter.php Add support for PHP CodeSniffer checks 2016-01-06 09:59:47 -08:00
composer.json Add extension.json, empty php entry point 2016-06-03 19:16:26 +00:00
COPYING Add COPYING 2014-01-22 21:21:10 +00:00
extension.json Provide page text and edit summary when filtering file uploads 2016-07-09 13:31:15 +00:00
Gruntfile.js Add npm entry point 2016-02-29 19:52:23 +00:00
hooks.txt (bug 42064) AbuseFilter + EditFilterMergedContent 2013-01-17 11:18:28 +01:00
package.json Add npm entry point 2016-02-29 19:52:23 +00:00
phpcs.xml Add support for PHP CodeSniffer checks 2016-01-06 09:59:47 -08:00