Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 856757 - Wiki confirmation email never arrives
Summary: Wiki confirmation email never arrives
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Infrastructure
Classification: Unclassified
Component: Other (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Infrastructure
URL:
Whiteboard:
Keywords:
: 863602 (view as bug list)
Depends on:
Blocks:
 
Reported: 2022-07-06 21:38 UTC by Greg Kubaryk
Modified: 2023-01-09 06:29 UTC (History)
8 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Greg Kubaryk 2022-07-06 21:38:55 UTC
I created a new wiki account on 2022-06-24 and have been unable to receive a confirmation email, so the account is extremely limited in its capabilities. We had one user in #gentoo report similarly. My email is hosted by gmail and the report in #gentoo was using gmail directly.

Sam checked the logs and said the email was in fact being sent out but it was getting stuck in 'Deferred'. I have no problem receiving bugmail to the same address. (Yes, I remembered to check the spam folder! :-))

I sent myself another confirmation around 2022-07-06 21:33 UTC or thereabouts.
Comment 1 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2022-07-06 22:32:06 UTC
06-15:27:07 <+robbat2> Jul  6 22:26:42 woodpecker postfix/smtp[893]: send attr diag_text = 550-5.7.1 [2001:470:ea4a:1:5054:ff:fec7:86e4       7] Our system 
                       has detected 550-5.7.1 that this message is likely unsolicited mail. To reduce the amount of 550-5.7.1 spam sent to Gmail, this 
                       message has been blocked. Please visit 550-5.7.1  https://support.google.com/mail/?p=UnsolicitedMessageError 550 5.7.1  for more 
                       information.
Comment 2 Matthew Marchese Gentoo Infrastructure gentoo-dev 2022-07-07 09:38:59 UTC
Can you please try sending the activation email again? We'll probably need your help testing to see if any progress has been made. Thank you!
Comment 3 Greg Kubaryk 2022-07-07 17:47:37 UTC
Triggered another one at 17:47 UTC, hasn't arrived yet, will keep an eye out.
Comment 4 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2022-07-08 01:43:02 UTC
No change in error:

Jul  7 17:46:53 woodpecker postfix/smtp[2465]: send attr reason = host ASPMX.L.GOOGLE.COM[2607:f8b0:400e:c09::1a] said: 550-5.7.1 [2001:470:ea4a:1:5054:ff:fec7:86e4       7] Our system has detected 550-5.7.1 that this message is likely unsolicited mail. To reduce the amount of 550-5.7.1 spam sent to Gmail, this message has been blocked. Please visit 550-5.7.1  https://support.google.com/mail/?p=UnsolicitedMessageError 550 5.7.1  for more information. e3-20020a654783000000b00412b10397b4si1058092pgs.664 - gsmtp (in reply to end of DATA command)
Comment 5 Matthew Marchese Gentoo Infrastructure gentoo-dev 2022-07-09 03:54:03 UTC
From the best of my understanding, it appears that the email is delivered successfully (but into the Spam folder) _if_ the receiving mailbox is hosted under a Google Workspace (formerly G Suite) account. This was kindly tested for me by someone with a @wikipedia.org email address.

If the receiving mailbox is an individual (free) Gmail account, then the message apparently does not go through at all. It doesn't show up in the Spam folder. It is simply not delivered due to 550-5.7.1.
Comment 6 Matthew Marchese Gentoo Infrastructure gentoo-dev 2022-07-09 03:56:51 UTC
For the record it was an @wikimedia.org email address.
Comment 7 Greg Kubaryk 2022-07-09 04:04:49 UTC
Not sure how to describe my university's relationship with gmail, but I think there's money involved (just not mine). The email doesn't seem to show in Spam, but I'll give it another go (4:04 UTC). If I don't report back in, it didn't work. (I graduated from university quite some time ago, but I'm an "alumni for life" so it's still my email address all these years later)
Comment 8 ris gentoo-dev 2022-08-04 12:38:03 UTC
User changing email address seems to be running into similar/same issue:

https://bugs.gentoo.org/show_bug.cgi?id=863602
Comment 9 Tao Tien 2022-10-09 09:16:55 UTC
I am a Google Workspace user, and have just tried to setup a wiki accnt. It's been quite a while, but not email has shown up in inbox or spam. Have also tried multiple times.
Comment 10 Ran Rutenberg 2022-10-14 16:40:01 UTC
I tried using my old Hotmail address instead of Gmail, but the confirmation email doesn't arrive to Hotmail as well.
Comment 11 Jeff Gazso 2022-10-14 17:59:30 UTC
Users are now joining IRC asking for edits to the wiki when they spot errors because they can't create accounts due to this issue. I'm genuinely happy to help users with documentation issues -- and I did. The problem is, when done over IRC some changes require a lot of back-and-forth to get right and it can be taxing for both the newcomer and the person rendering assistance.
Comment 12 Jae Hak Kim 2022-10-20 05:14:47 UTC
Same here - confirmation email never arrives on my gmail account. I had to use my own domain.
Comment 13 Mauricio Ghiorzi 2022-11-24 16:22:05 UTC
I had Google Workspace and Wiki's mail does not arrived
Comment 14 Mauricio Ghiorzi 2022-11-24 17:52:49 UTC
As Google Workspace administrator I had several configurations about Spam Filter behavior

I dont know if any of this settings could be override or bypass Google's rejection for my domain

I added gentoo.org domain in Spam whitelist and also 140.211.166.183 and 2001:470:ea4a:1:5054:ff:fec7:86e4 IP address.

I will try to send activation mail in an hour to make sure this changes are in effect

I'll let you know any outcome
Comment 15 Jeff Gazso 2022-12-24 17:57:53 UTC
It's interesting to me that the Gentoo wiki is experiencing this problem but the forum is not. Someone please let me know if the implicit assumption that they're both using the same back-end infrastructure for sending emails is a faulty one.

Can one of you who has successfully gotten an email from the wiki after this became an issue kindly upload the full text of the email including ALL of the headers? Ideally, I'd like a successfully received email sent to a Google Workspace recipient AND one from some other provider; but I'll take what I can get.

If I don't get a response from someone on this thread in a few days, I'll create a burner account at some random email provider and run a few tests and see what I can figure out. I'm primarily a Gmail user and contribute to the wiki semi-regularly so this issue is really starting to annoy me. I want to see what — if anything — I can do about it.
Comment 16 Jeff Gazso 2022-12-27 02:31:17 UTC
I did some in-depth troubleshooting on this issue. I created a burner account at Yahoo.com and a test account on the wiki just to get the new user welcome message. I compared that to one of the last email messages the wiki sent to my gmail before this issue manifested itself.

I stepped through the email headers and checked relevant bits of Gentoo infrastructure against common RTBL's, etc., etc. Gentoo's infrastructure seems fine. I see that forum emails are working just fine and they come from the exact same infrastructure, so I would have been shocked if I found the issue here.

Later, I manually started SMTP sessions via telnet to mail.gentoo.com for troubleshooting purposes. The relevant parts are:

```
rcpt to: wiki-noreply@gentoo.org
550 5.1.1 <wiki-noreply@gentoo.org>: Recipient address rejected: User unknown in local recipient table
...
rcpt to: forum-mods@gentoo.org
550 5.1.1 <forum-mods@gentoo.org>: Recipient address rejected: User unknown in local recipient table
```

*This is a fairly common minor issue, but it should be fixed.*

Modern anti-spam techniques often include verifying the alleged sender account is a valid recipient at the originating domain prior to delivery. Not having a valid user here is a common configuration issue. Nevertheless, it will typically add to the domain's/user's spam weight and should be fixed. The easiest way to do that would be to add `wiki-noreply` *et al* to the user table and delete any messages for them as they come in; it's a very common solution to this problem.

At this point, other than the above minor issue I'm convinced Gentoo's infrastructure is not the cause of this bug. Gmail does not like wiki-noreply@gentoo.org for no reason I can discern. Technically, renaming the account will likely "fix" the issue but will set us up for failure as Gmail will likely ban that email account eventually for the same reason and we will be no closer to knowing why.

Someone from the Gentoo Infrastructure team should probably reach out to Google directly and ask for assistance. They can be contacted for issues like this via https://about.google/contact-google/.

Good luck.
Comment 17 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2022-12-27 23:56:08 UTC
How did you get that forums-mods was not-valid? It absolutely exists.
```
rcpt to: forum-mods@gentoo.org                                                                                                                                          
550 5.1.1 <forum-mods@gentoo.org>: Recipient address rejected: User unknown in                                                                                          
local recipient table                                                                                                                                                   
```

I created wiki-noreply@ forwarding to /dev/null for the moment.

The other(In reply to Mauricio Ghiorzi from comment #14)
> As Google Workspace administrator I had several configurations about Spam
> Filter behavior
...
> I will try to send activation mail in an hour to make sure this changes are
> in effect
> 
> I'll let you know any outcome

Hi Mauricio,

Did you retesting help?
Comment 18 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2023-01-05 17:15:12 UTC
Update since nobody else did:

Making sure wiki-noreply@gentoo.org exists did NOT fix the problem.
Comment 19 Jeff Gazso 2023-01-05 18:24:00 UTC
(In reply to Robin Johnson from comment #18)
> Update since nobody else did:
> 
> Making sure wiki-noreply@gentoo.org exists did NOT fix the problem.

I said, "This [the email accounts not existing] is a fairly common minor issue, but it should be fixed." This is because some MTA's will call back to the sender and confirm the account actually exists. The result of this "conversation" over SMTP can alter a message's spam-weight with anti-spam tools prior to delivery. It's not usually enough *by itself* to mark an account/domain as spam let alone compel the message to be silently dropped.

I think the correct course of action is to reach out to Google directly at https://about.google/contact-google/ and see what they say.
Comment 20 Alec Warner (RETIRED) archtester gentoo-dev Security 2023-01-06 22:35:12 UTC
I spent the past few days looking at this, trying to narrow down the cause through trial and error.

 - Previously our spam reputation was not great (due to our existing smtp flow.) However I checked google postmaster tools recently and it seems to have improved.
 - Robin sent a test mail from the wiki box and it went through, so we knew it was not entirely a reputation problem; some elements of the mail were triggering the rejection.
 - I set up a dozen or so fake test accounts, with modified message text to iterate on what messages went through vs not.

The conclusion:
 - Our version of the wiki has complex mail sending logic, which can use native PHP stuff (PEAR) or an MTA. We mostly use an MTA here (postfix). Because the software has to support users who don't have an MTA, it has to implement a bunch of MTA functionality itself.
 - gmail dislikes some of the custom MTA functionality, in particular the DATE and MESSAGE_ID mail headers the wiki is choosing to add.
 - If I patch them out of the wiki, the MTA that we use adds them in the perhaps more normal / expected MTA format.
 - I suspect a significant amount of spam "looks like our wiki spam" and it comes from hacked PHP applications (wordpress) so it behooves us to try not to look like that WP spam.

I've deployed the patches to the wiki software.
Comment 21 Nikita Melnichenko 2023-01-07 23:07:00 UTC
Thank you for making progress! I was able to get an email today for the first time, however I just got

> Subject: Gentoo Wiki email address confirmation
> 
> Someone, probably you
> has registered an account "{my_account_name}" with this email address on Gentoo Wiki.

without any link.

Alec, in your comment you're talking about experimenting with messages. Could you please check whether the email template still contains the link or not?
Comment 22 Jim Tupper 2023-01-08 00:42:45 UTC
Can confirm with Nikita, I too got the confirmation email from the wiki without any link to actually confirm the email address with.

I resent the email confirmation and received the same email a second time - no link.
Comment 23 Alec Warner (RETIRED) archtester gentoo-dev Security 2023-01-08 01:34:27 UTC
(In reply to Nikita Melnichenko from comment #21)
> Thank you for making progress! I was able to get an email today for the
> first time, however I just got
> 
> > Subject: Gentoo Wiki email address confirmation
> > 
> > Someone, probably you
> > has registered an account "{my_account_name}" with this email address on Gentoo Wiki.
> 
> without any link.
> 
> Alec, in your comment you're talking about experimenting with messages.
> Could you please check whether the email template still contains the link or
> not?

Ahh yeah my bad, some of my steps had me editing the messages (later I found a better / faster way) and I just failed to put them back, but they are back now. Please re-request any links.

Thanks for pointing out I left them broken!

-A
Comment 24 Greg Kubaryk 2023-01-08 01:48:54 UTC
I was able to change my wiki account to my gmail-based email address; shall we close this out or leave it open a bit longer?
Comment 25 Nikita Melnichenko 2023-01-08 07:10:28 UTC
Hmm, I re-requested but got exactly the same email body without the link. I used this page for the request: https://wiki.gentoo.org/wiki/Special:ConfirmEmail
Comment 26 Jeff Gazso 2023-01-08 14:22:49 UTC
I can confirm I just got a wiki generated thank you email from Maffblaster for some content I created. This appears to be fixed — though I'm a bit wary about celebrating too soon. Can someone spell out exactly what happened here? Did it prove to be the date and message ID headers or was it something else?
Comment 27 John Helmert III archtester Gentoo Infrastructure gentoo-dev Security 2023-01-08 17:07:38 UTC
*** Bug 863602 has been marked as a duplicate of this bug. ***
Comment 28 Alec Warner (RETIRED) archtester gentoo-dev Security 2023-01-08 18:41:53 UTC
(In reply to Nikita Melnichenko from comment #25)
> Hmm, I re-requested but got exactly the same email body without the link. I
> used this page for the request:
> https://wiki.gentoo.org/wiki/Special:ConfirmEmail

Ok this should be fixed now, the wiki had cached the bad message content internally and I had to flush the cache (which is done.)

I also generated a test account to test the sign up flow and I got the correct message (with links!) and I used one of them to abort the signup.

-A
Comment 29 Alec Warner (RETIRED) archtester gentoo-dev Security 2023-01-08 18:42:48 UTC
(In reply to Jeff Gazso from comment #26)
> I can confirm I just got a wiki generated thank you email from Maffblaster
> for some content I created. This appears to be fixed — though I'm a bit wary
> about celebrating too soon. Can someone spell out exactly what happened
> here? Did it prove to be the date and message ID headers or was it something
> else?

If "it" is Google's smtp servers thinking the emails are spam, then yes it was the mediawiki-generated message-ID headers and Date headers that google thought looked spammy.

-A
Comment 30 Nikita Melnichenko 2023-01-09 02:11:17 UTC
Works as expected now. Thanks Alec!
Comment 31 Matthew Marchese Gentoo Infrastructure gentoo-dev 2023-01-09 06:29:12 UTC
Awesome work! Thank again for wading in to this waist deep and fixing it, antarus!