wiki.techinc.nl/tests/phpunit/includes
Bartosz Dziewoński df7231ad89 preferences: Signature validation (lint errors, user links, nested subst)
Three new checks are now applied to user signatures in preferences:

* Disallow invalid HTML and lint errors (T140606)

  Since 15e0e9bb4b we can rely on Parsoid to check the signature for
  lint errors. (The old PHP Parser doesn't have this capability.)

  Most importantly, this will disallow unclosed HTML tags. Unclosed
  formatting tags like `<i>` (and also wikitext markup like `''`)
  could affect the entire page with the bad markup.

  New configuration variable $wgSignatureAllowedLintErrors is added
  to allow ignoring some errors. The default value ignores the
  'obsolete-tag' error (caused by HTML tags like `<font>` and `<tt>`.)

* Require a link to user page, talk page or contributions (T237700)

  Various tools don't work correctly when such a link is missing. For
  example, Echo notifications are not sent, DiscussionTools will not
  allow replying to these comments, English Wikipedia's SineBot treats
  these comments as unsigned.

  Such requirement has been present for a long time in many Wikimedia
  wikis' policies, but it was not enforced by software.

* Disallow "nested" substitution in signature (T230652)

  Clever abuse of "subst" markup and tildes allows users to save edits
  containing wikitext in which substitution occurs again when the page
  is next saved. Disallow this in signatures, at least.

New configuration variable $wgSignatureValidation is added to control
what we do about the result of the validation described above. The
options are:

* 'warning':
  Only displays a warning near the field on Special:Preferences if
  the current signature is invalid. Signatures can still be changed
  regardless of validity and will be used when signing comments.

* 'new':
  In addition to the above, if a user tries to change their signature,
  the new one must be valid. Existing invalid signatures are still
  used when signing comments.

* 'disallow':
  In addition to the above, existing invalid signatures are no longer
  used when signing comments.

Bug: T140606
Bug: T237700
Bug: T230652
Change-Id: I07c575c2d9d2afe7a89c4847d16ac044417297bf
2020-06-24 01:20:05 +02:00
..
actions Add getExpiryInDays function in WatchedItem 2020-06-16 19:58:34 -05:00
api Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
auth Replace all call_user_func(_array) in all tests 2020-06-06 18:41:20 +02:00
block Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
cache Hooks::run() call site migration 2020-05-30 14:23:28 +00:00
changes Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
changetags Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
collation Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
config
content Merge "Remove minor pieces of unused code from TextContentTest" 2020-06-08 16:24:13 +00:00
context
db Replace all call_user_func(_array) in all tests 2020-06-06 18:41:20 +02:00
debug Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
deferred Hard deprecate calling ParserOptions::newCanonical with no parameters 2020-06-15 23:11:45 +00:00
diff
editpage
exception Add getMockMessage to MediaWikiTestCaseTrait 2020-05-20 21:52:11 +02:00
externalstore ExternalStore: report cause of non-exception failure 2020-04-17 18:00:28 +02:00
filebackend build: Bump mediawiki-codesniffer to 31.0.0 2020-05-30 14:56:28 +00:00
filerepo filerepo: make LocalRepo::getSharedCacheKey() use makeGlobalKey() 2020-05-23 17:32:55 +00:00
GlobalFunctions Hard deprecate wfIsBadImage() 2020-06-09 19:27:16 +00:00
HookContainer HookContainer Integration Test 2020-05-11 13:45:39 -07:00
htmlform
http Respect configured default HTTP timeouts, and introduce max timeouts 2020-05-21 09:30:57 +10:00
import Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
interwiki Hooks::run() call site migration 2020-05-30 14:23:28 +00:00
jobqueue Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
language
libs Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
linkeddata
linker Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
logging Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
mail
media Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
Message
Navigation
objectcache objectcache: dependency inject LoadBalancer into SqlBagOStuff 2020-05-18 21:04:17 -07:00
page Merge "WikiPage::doEditUpdates - accept a RevisionRecord object" 2020-06-18 01:24:33 +00:00
pager
ParamValidator/TypeDef
parser Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
password Remove deprecated PasswordCannotBePopular 2020-06-15 21:57:25 +00:00
Permissions Hooks::run() call site migration 2020-05-30 14:23:28 +00:00
poolcounter Replace all call_user_func(_array) in all tests 2020-06-06 18:41:20 +02:00
preferences preferences: Signature validation (lint errors, user links, nested subst) 2020-06-24 01:20:05 +02:00
rcfeed
registration Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
resourceloader Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
Rest Hooks::run() call site migration 2020-05-30 14:23:28 +00:00
Revision Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
search Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
session Replace all call_user_func(_array) in all tests 2020-06-06 18:41:20 +02:00
shell Replace all call_user_func(_array) in all tests 2020-06-06 18:41:20 +02:00
site
skins skins: Port SkinFallback and SkinApiOutput to a generic SkinMustache class 2020-06-15 10:51:31 -07:00
sparql
specialpage Replace all call_user_func(_array) in all tests 2020-06-06 18:41:20 +02:00
specials Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
Storage Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
title Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
upload Merge "upload: Modernize callback code to make use of PHP7 syntax" 2020-06-16 19:37:15 +00:00
user Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
utils Replace all call_user_func(_array) in all tests 2020-06-06 18:41:20 +02:00
watcheditem Add getExpiryInDays function in WatchedItem 2020-06-16 19:58:34 -05:00
ActorMigrationTest.php
ActorMigrationTest.sql
AutoLoaderTest.php
AutopromoteTest.php Move autopromote groups logic into UserGroupManager 2020-06-11 22:13:48 +00:00
CategoryTest.php build: Bump mediawiki-codesniffer to 31.0.0 2020-05-30 14:56:28 +00:00
CommentStoreCommentTest.php
CommentStoreTest.php
CommentStoreTest.sql
ContentSecurityPolicyTest.php Hooks::run() call site migration 2020-05-30 14:23:28 +00:00
DeprecatedGlobalTest.php Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
DiffHistoryBlobTest.php
EditPageTest.php
ExportTest.php Work around change in SimpleXMLElement behavior introduced in PHP 7.3.17 2020-04-30 18:27:15 -04:00
ExtraParserTest.php
FauxRequestTest.php Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
GitInfoTest.php
HooksTest.php Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
HtmlTest.php
LinkerTest.php resources: Bundle ajax patrol and ajax rollback code 2020-05-28 07:22:07 +00:00
LinkFilterTest.php
ListToggleTest.php
MagicWordFactoryTest.php Hooks::run() call site migration 2020-05-30 14:23:28 +00:00
MediaWikiServicesTest.php build: Bump mediawiki-codesniffer to 31.0.0 2020-05-30 14:56:28 +00:00
MediaWikiTest.php
MediaWikiVersionFetcherTest.php
MergeHistoryTest.php Inject SpamChecker where needed, hard deprecate EditPage static methods 2020-05-26 03:17:29 -07:00
MessageTest.php Replace all call_user_func(_array) in all tests 2020-06-06 18:41:20 +02:00
MovePageTest.php Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
MultiHttpClientTest.php MultiHttpClient: Reduce the default timeout from 900 to 30 2020-06-15 15:34:13 +10:00
MWTimestampTest.php
OutputPageTest.php Fix a plethora of class and function call case mismatches 2020-05-26 14:14:46 +01:00
PagePropsTest.php
PrefixSearchTest.php Fix tests/ PSR12.Properties.ConstantVisibility.NotFound 2020-05-16 04:30:21 +01:00
ReadOnlyModeTest.php
RevisionDbTest.php Hard deprecate Revision::getTimestamp 2020-06-10 16:57:20 +00:00
RevisionTest.php Hard deprecate Revision::getTimestamp 2020-06-10 16:57:20 +00:00
RevisionTestModifyableContent.php Fix tests/ PSR12.Properties.ConstantVisibility.NotFound 2020-05-16 04:30:21 +01:00
RevisionTestModifyableContentHandler.php
SampleTest.php
SiteStatsTest.php build: Bump mediawiki-codesniffer to 31.0.0 2020-05-30 14:56:28 +00:00
StatusTest.php Add getMockMessage to MediaWikiTestCaseTrait 2020-05-20 21:52:11 +02:00
SystemBlockTest.php
TemplateCategoriesTest.php
TestLocalisationCache.php
TestLogger.php Replace all call_user_func(_array) in all tests 2020-06-06 18:41:20 +02:00
TestUser.php
TestUserRegistry.php
TimeAdjustTest.php Remove unneeded ::setUp and ::tearDown methods that only call parent 2020-06-07 10:09:32 +00:00
TitleMethodsTest.php Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
TitlePermissionTest.php
TitleTest.php Fix a plethora of class and function call case mismatches 2020-05-26 14:14:46 +01:00
WebRequestTest.php Fix misplaced expected test value in WebRequestTest 2020-05-29 08:22:51 +02:00
WikiMapTest.php Fix visibility of setUp/tearDown 2020-06-16 21:02:05 +02:00
WikiReferenceTest.php
XmlTest.php