Last modified: 2010-05-15 15:54:47 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T17055, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 15055 - Tries to send e-mails to users without an e-mail address
Tries to send e-mails to users without an e-mail address
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Email (Other open bugs)
1.12.x
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2008-08-06 05:44 UTC by Lukáš Lalinský
Modified: 2010-05-15 15:54 UTC (History)
0 users

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Lukáš Lalinský 2008-08-06 05:44:04 UTC
When somebody edits a Talk page for an user, which doesn't have an e-mail address set in MediaWiki, it will try to send the notification e-mail to "UserName <>". This generates incorrect e-mail headers, so mail servers will usually return the message as undelivered. As an example:

> From: Mail Delivery System <Mailer-Daemon@musicbrainz.org>
> Date: August 5, 2008 12:54:52 PM PDT
> To: default-return-path@musicbrainz.org
> Subject: Mail failure - malformed recipient address
>
> A message that you sent contained one or more recipient addresses  
> that were
> incorrectly constructed:
>
>  Nikki <>: missing or malformed local part
>
> This address has been ignored. There were no other addresses in your
> message, and so no attempt at delivery was possible.
>
> ------ This is a copy of the headers that were received before the  
> error
>       was detected.
>
> To: Nikki <>
> Subject: MusicBrainz Wiki page User talk:Nikki has been changed by  
> CatCat
> MIME-Version: 1.0
> Content-type: text/plain; charset=UTF-8
> Content-Transfer-Encoding: 8bit
> X-Mailer: MediaWiki mailer
> From: WikiAdmin <lalinsky@gmail.com>
> Reply-To: reply@not.possible
> Message-Id: <E1KQScO-0000jg-F4@scooby.musicbrainz.org>
> Sender: ",,," <mediawiki@scooby.musicbrainz.org>
> X-rewrote-sender: mediawiki@scooby.musicbrainz.org
> Date: Tue, 05 Aug 2008 19:54:52 +0000

Ideally, MediaWiki should check if the user has an e-mail address and not try to send the e-mail if they don't.

Thanks,
Lukas
Comment 1 Brion Vibber 2008-08-06 19:28:04 UTC
UserMailer::actuallyNotifyOnPageChange() appears to be checking $watchingUser->isEmailConfirmed() which will return false if you don't have a valid email address set.

Do you perhaps have the user 'Nikki' set in $wgUsersNotifiedOnAllChanges? For this case the check appears to be bypassed.
Comment 2 Lukáš Lalinský 2008-08-06 19:43:57 UTC
As far I can see, $watchingUser->isEmailConfirmed() is called only for other users watching that specific page. If it's a talk page, and the user has enotifusertalkpages set to 1 (which seems to be the default according to includes/DefaultSettings.php), it unconditionally calls UserMailer::compose for that user:

				} elseif( $targetUser->getOption( 'enotifusertalkpages' ) ) {
					wfDebug( __METHOD__.": sending talk page update notification\n" );
					$this->compose( $targetUser );
					$userTalkId = $targetUser->getId();
				} else {

So it looks like this code block should be:

				} elseif( $targetUser->getOption( 'enotifusertalkpages' ) && $targetUser->isEmailConfirmed() ) {
					wfDebug( __METHOD__.": sending talk page update notification\n" );
					$this->compose( $targetUser );
					$userTalkId = $targetUser->getId();
				} else {

Comment 3 Brion Vibber 2008-08-06 23:43:34 UTC
Aho!

That'll do it. :)

Fixed in r38746

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links