Page MenuHomePhabricator

PHP Notice: Cannot access property on non-object
Closed, ResolvedPublicPRODUCTION ERROR

Description

Error
message
[XWjjbwpAMEkAABBJo88AAAAM] /wiki/Special:AbuseFilter/history/gibberish/item/5   ErrorException from line 47 of /srv/mediawiki/php-1.34.0-wmf.19/extensions/AbuseFilter/includes/Views/AbuseFilterViewEdit.php: PHP Notice: Cannot access property on non-object
Impact

We show filter 1 instead of a filter with ID = "gibberish", no other impact on the user. Definitely not blocking anything.

Notes

In the last 24 hours, 66 hits on wmf.19. No occurrencies for wmf.20, but that's just because no-one triggered it (I tried on a wmf.20 wikis and got the notice). Also, those URLs seem to be attempts of injection (?); at any rate, the nonsense and speed suggest non-human traffic.
Anyway, this creates annoying logspam, so I'm opening this task for reference even though I had already sent a patch a few days ago.

Details

Request ID
XWjjbwpAMEkAABBJo88AAAAM
Request URL
http://en.wikipedia.org/wiki/Special:AbuseFilter/history/gibberish/item/5
Stack Trace
#0 /srv/mediawiki/php-1.34.0-wmf.19/extensions/AbuseFilter/includes/Views/AbuseFilterViewEdit.php(47): MWExceptionHandler::handleError(integer, string, string, integer, array, array)
#1 /srv/mediawiki/php-1.34.0-wmf.19/extensions/AbuseFilter/includes/special/SpecialAbuseFilter.php(139): AbuseFilterViewEdit->show()
#2 /srv/mediawiki/php-1.34.0-wmf.19/includes/specialpage/SpecialPage.php(571): SpecialAbuseFilter->execute(string)
#3 /srv/mediawiki/php-1.34.0-wmf.19/includes/specialpage/SpecialPageFactory.php(582): SpecialPage->run(string)
#4 /srv/mediawiki/php-1.34.0-wmf.19/includes/MediaWiki.php(296): MediaWiki\Special\SpecialPageFactory->executePath(Title, RequestContext)
#5 /srv/mediawiki/php-1.34.0-wmf.19/includes/MediaWiki.php(892): MediaWiki->performRequest()
#6 /srv/mediawiki/php-1.34.0-wmf.19/includes/MediaWiki.php(523): MediaWiki->main()
#7 /srv/mediawiki/php-1.34.0-wmf.19/index.php(42): MediaWiki->run()
#8 /srv/mediawiki/w/index.php(3): include(string)
#9 {main}

Event Timeline

Change 533027 had a related patch set uploaded (by Daimona Eaytoy; owner: Daimona Eaytoy):
[mediawiki/extensions/AbuseFilter@master] Fix param validation in ViewEdit

https://gerrit.wikimedia.org/r/533027

To make it clear for whoever reads this, /wiki/Special:AbuseFilter/history/gibberish/item/5 is real URL, not a masking of a potentially insecure URL.

To make it clear for whoever reads this, /wiki/Special:AbuseFilter/history/gibberish/item/5 is real URL, not a masking of a potentially insecure URL.

Ah, well, it was my test URL. Basically, you can replace "gibberish" with anything that is not an integer and you'll get the same result. Thanks for pointing it out, I forgot to!

Change 533027 merged by jenkins-bot:
[mediawiki/extensions/AbuseFilter@master] Fix param validation in ViewEdit

https://gerrit.wikimedia.org/r/533027