Commit graph

2404 commits

Author SHA1 Message Date
Marius Hoch 2a7e5c8193 Make use of the user_timestamp index in ApiQueryAbuseLog
Furthermore sanitize IPs as ::01 == ::1

Change-Id: I91489d17c012004f607bbe571b9a2702afbf3d81
2013-03-26 15:16:43 +01:00
Marius Hoch 233a850a08 Make AbuseLog searchable by IPv6 IPs
Bug: 39449

Change-Id: Ie331ec7ef3b461ae10f0e28fe50cb86684c6d3a0
2013-03-26 00:30:32 +01:00
Translation updater bot 957a5690f7 Localisation updates from http://translatewiki.net.
Change-Id: If69be76e54f34fd2b01c4a9942d1b1783f6d8981
2013-03-25 19:25:21 +00:00
Marius Hoch 3010d78950 Add parser tests for bug 25373
Change-Id: I2f2524731098f323e61bbc0442e7b56b11cdea37
2013-03-23 21:49:57 +01:00
nischayn22 dd28075e46 Conditional operator with () returns false.
Directly applying the patch given in the bug report. Thanks to orlodrim.
bug: 25373

Change-Id: I72b27e3dd22416288f3113e5a7c5a21ffbac01fb
2013-03-23 11:11:25 +05:30
Translation updater bot d5f282a2dd Localisation updates from http://translatewiki.net.
Change-Id: I73087c51531b07fb6558375e428607d29511e365
2013-03-20 20:52:20 +00:00
Translation updater bot 708edc5522 Localisation updates from http://translatewiki.net.
Change-Id: I7663654ccb3fc1ca2eb9b754e3462f2988ac5509
2013-03-19 21:35:09 +00:00
Tim Starling 7450622fff Update afl_rev_id even if the edit summary changed
(bug 28633) With $wgUseAutomaticEditSummaries=true, the edit summary is
different between EditFilterMerged and ArticleSaveComplete. AbuseFilter
was using edit summary changes to attempt to detect whether the two
hooks refer to the same edit. If it really is possible for multiple
edits to be performed in the same request, with arbitrary patterns of
EditFilterMerged and ArticleSaveComplete calls, then some more robust
method would be needed to match the hook calls. But I don't think that
is necessary at present.

Change-Id: I94321905f38eafde8add00eff73745af255c1f15
2013-03-19 11:34:30 +11:00
Translation updater bot 8c94758815 Localisation updates from http://translatewiki.net.
Change-Id: I34ec82b7f15bb9ac2d1561fc4fdd49debb791504
2013-03-18 21:02:20 +00:00
Translation updater bot 2e2d7d2bf4 Localisation updates from http://translatewiki.net.
Change-Id: I6c727f809a4ec0420e031e8b4ae6c5600e5e8136
2013-03-17 20:30:45 +00:00
Translation updater bot 26747580c3 Localisation updates from http://translatewiki.net.
Change-Id: I7f264465fa2eef899bad9ca5fa8309c78b92b5d5
2013-03-16 21:22:51 +00:00
Translation updater bot dc760a3405 Localisation updates from http://translatewiki.net.
Change-Id: I6a657c6d2d1aee3ca7c29f516457506658738ff6
2013-03-15 19:58:03 +00:00
Translation updater bot 4897af331d Localisation updates from http://translatewiki.net.
Change-Id: I3c65e1abb4272011f52b71527583263300f2ae54
2013-03-13 21:08:32 +00:00
Kunal Mehta 75e3fa4b8b Change right needed to see filter id in API to hidden from private.
Currently it checks if the filter is set to hidden, and then
requires the private permission to view it, which is intended
for private data (like IP addresses), not hidden filters.

Change-Id: Iff8f9edf2466050aeadf3907dcff5464e179ff68
2013-03-13 00:41:03 -05:00
Translation updater bot 32c4d51a52 Localisation updates from http://translatewiki.net.
Change-Id: Icd8d72a59cc97093b5203f08a63a4ed39e7d2f31
2013-03-12 21:08:40 +00:00
Translation updater bot c573a0c795 Localisation updates from http://translatewiki.net.
Change-Id: I6a83803d72d905857a8777a74958dc8aaa890523
2013-03-11 20:26:20 +00:00
Translation updater bot ffb6d8ae7e Localisation updates from http://translatewiki.net.
Change-Id: Ia3636171bf2066b83b812b6ca49cb0f1ffcd52ba
2013-03-10 21:17:59 +00:00
Translation updater bot 7461a836d3 Localisation updates from http://translatewiki.net.
Change-Id: I2127c061a404e17e644b23600eca89ff88c342dc
2013-03-08 17:02:50 +00:00
CSteipp 4c2e5af737 Merge "Overhaul of the AbuseFilter JS" 2013-03-07 18:24:07 +00:00
shirayuki b460fa790f Adding trailing dot + comment for grep (24 messages)
Change-Id: I7b532028a2bdbed11f0dfe6cdf4eb4514671294c
2013-03-07 23:03:59 +09:00
Marius Hoch e3d15fe915 Overhaul of the AbuseFilter JS
I've changed the JS of the AbuseFilter extension to match our
coding conventions and made it use mediaWiki.Api(). Furthermore
I fixed several error handlers and made some things nicer in
general while trying to not change the user appearance.

I've tested the changes as good as I could (I'm pretty sure everything
works).

Change-Id: Iaa0f99367bd7e0bfaf7249dcc9ac9ce9881b46e1
2013-03-07 14:14:25 +01:00
Translation updater bot 604d0ce650 Localisation updates from http://translatewiki.net.
Change-Id: I7695871d6b637018b4fd29900daee4d3990f9708
2013-03-06 21:47:16 +00:00
shirayuki 0f0f285688 Changing position of colon + American spelling of normalize
Change-Id: If1628dc6fa524bf849a186cc1e0c7987a9761ec8
2013-03-06 19:24:21 +09:00
shirayuki 23b2857755 American spelling for "Unrecognized"
Change-Id: I9258d3229e2ecdea597fdff0f63398ecdadf6e17
2013-03-05 20:36:10 +09:00
Translation updater bot f8de0c07a5 Localisation updates from http://translatewiki.net.
Change-Id: Iee826bd1569920d44136d4069f0b5a8ea3a53f8e
2013-03-04 21:30:13 +00:00
Translation updater bot 26d01e9ef7 Localisation updates from http://translatewiki.net.
Change-Id: I7a6763c94068a364f260e5a01ea85b4161166a6c
2013-03-03 21:08:37 +00:00
Translation updater bot d6e528c5e6 Localisation updates from http://translatewiki.net.
Change-Id: I4abea5eca0459aa913988ec24f584aad2b3652ce
2013-03-02 20:32:24 +00:00
Translation updater bot 5fbae57ed1 Localisation updates from http://translatewiki.net.
Change-Id: Ibe3babff4713a6adb0b693560c25b9316765af85
2013-03-01 21:16:19 +00:00
CSteipp f6fc15fcfc Merge "AbuseFilter: Change format of database logging/ performance" 2013-02-28 21:39:46 +00:00
Marius Hoch 42bd0d84f4 AbuseFilter: Change format of database logging/ performance
AF is setting several lazy load variables for the currently editing user.
To do this it's passing along the user name extracted from a user object
and generating a new user object later from that name which is of course
pointless. With this patch I'll pass user objects directly to prevent that.
On top of that I've deprecated a method in AFComputedVariable::compute which
was redundant as there is a more generic one which can solve that task
just fine.

Furthermore I've changed the logging behaviour from serializing the whole
AbuseFilterVariableHolder object to only store the variables. That has two
major advantages:
 * The amount of data that needs to be saved on a filter hit is reduced
   to about 1/10 of what the old version needed.
 * This is much more forward compatible as the old way of saving this
   relied on the class structure to stay the same while this is a simple
   array containing the vars.

On top of that we now only log variables already set by the time
a filter is hit. On top of the obvious performance increasement
that makes it easier for the user to spot the relevant data.

Another thing this change alters is the way the AbuseFilter internally
works with AbuseFilterVariableHolder objects. Right now we use one for
testing the filter(s) and later we use another one to compute the same
data again in case a filter was hit (for logging)!

This is not thoroughly tested yet, but way more sane than what we're
currently doing!

Change-Id: Ib15e7501bff32a54afe2d103ef5aedb950e58ef6
2013-02-28 22:35:22 +01:00
Translation updater bot 974091370c Localisation updates from http://translatewiki.net.
Change-Id: I1332f23b5ecb087ab99aca773cc224a5529c7540
2013-02-28 20:36:27 +00:00
Translation updater bot 957fa41c5a Localisation updates from http://translatewiki.net.
Change-Id: I21d7512a7e7caf24e77e1cbed77bd741cb4dc6c3
2013-02-27 21:12:02 +00:00
Translation updater bot 95b672c9bf Localisation updates from http://translatewiki.net.
Change-Id: Ic33b11a2966dfbdee404dc0114074b4b764b21b8
2013-02-26 20:44:24 +00:00
Translation updater bot 9aed5e40a9 Localisation updates from http://translatewiki.net.
Change-Id: I29f1a5f4464cc8e92401669c857df6b53ff70455
2013-02-25 21:04:19 +00:00
CSteipp c35865b1ff Merge "Fix default for $wgAbuseFilterAnonBlockDuration" 2013-02-25 18:23:23 +00:00
Translation updater bot aed0c1c6ac Localisation updates from http://translatewiki.net.
Change-Id: Idf9c6499d079b0ac67110c10a7d72041b6c18b55
2013-02-23 20:32:31 +00:00
Marius Hoch fdae51ec07 Fix default for $wgAbuseFilterAnonBlockDuration
$wgAbuseFilterAnonBlockDuration didn't default to the actual
value of $wgAbuseFilterBlockDuration but to the default value
of that (which is indefinite). Fixed that (untested)

Change-Id: I26a929bfba997b80445a108e212030fe7faa6428
2013-02-23 00:20:29 +01:00
Translation updater bot b9f9eface0 Localisation updates from http://translatewiki.net.
Change-Id: I426fa94dfb209937190f4cfc4aaa5b2f8a1c5e73
2013-02-21 20:15:14 +00:00
Translation updater bot fa99fcab1d Localisation updates from http://translatewiki.net.
Change-Id: Ib4e1b97a1f80d7fa823073d3645ec75f348fa12b
2013-02-20 21:40:51 +00:00
Translation updater bot 9f5d2d6702 Localisation updates from http://translatewiki.net.
Change-Id: Ic223c22b47bbc7f0c281bb932caaf7a462f95f0d
2013-02-19 20:34:39 +00:00
Hoo man e817f73f13 Merge "Check against $wgAbuseFilterRestrictedActions instead of hardcoded list for block actions" 2013-02-19 13:09:51 +00:00
Hoo man d858cfca35 Merge "Check that $title is defined and is a Title object" 2013-02-19 12:41:39 +00:00
jeblad 53e230c5c7 Check that $title is defined and is a Title object
During testing the context does not always contain a valid
Title object. In those cases AbuseFilter will fail hard.
This changeset makes the filter survive some of those
failures.

Change-Id: I0b2247432619ddf15cc17ed41b4b7a6a11e910e0
2013-02-19 13:39:47 +01:00
Hoo man 750f594b0f Merge "Create variable to set length of IP blocks" 2013-02-19 12:30:53 +00:00
Translation updater bot 0ef28d1079 Localisation updates from http://translatewiki.net.
Change-Id: Id9702f87783f7eeaebbb633c448e2af80d093c2f
2013-02-18 20:52:34 +00:00
Translation updater bot 19b101a055 Localisation updates from http://translatewiki.net.
Change-Id: I8e8107c2dcb70c439efce44eebea2e6fd3dcddbf
2013-02-17 20:34:15 +00:00
Translation updater bot 3e81fa56d6 Localisation updates from http://translatewiki.net.
Change-Id: I434c7ff7938abd0ab110f26d8371c2389d5cdbd8
2013-02-16 23:13:06 +00:00
Translation updater bot 30833b128a Localisation updates from http://translatewiki.net.
Change-Id: I2e095e57e1e7d159af58167e086bb2f7ec22c9ce
2013-02-15 20:30:39 +00:00
Translation updater bot a9ab356fc5 Localisation updates from http://translatewiki.net.
Change-Id: Ibbe91628776e4d01352e887168abb4195a5b1f43
2013-02-14 20:26:59 +00:00
Matthias Mullie 8ffebe3502 Add composer.json
Change-Id: I63026dda084c056968c4ccb308506089a13f3f32
2013-02-14 13:41:40 +00:00