check_mail_permissions could not determine the sender domain [case 59140]

sehh

Well-Known Member
Feb 11, 2006
579
5
168
Europe
The recent upgrade cause another issue, our exim_mainlog is full of these errors:

check_mail_permissions could not determine the sender domain

Anyone knows what is going on?
 

mtindor

Well-Known Member
Sep 14, 2004
1,394
72
178
inside a catfish
cPanel Access Level
Root Administrator
I'm seeing tons of these errors in the logs too. But from what I look at when grepping the message ID, it appears that they are making it through to their destination though because a grep of the message id in exim_mainlog reveals the forwarded mail being accepted by Gmail, Hotmail, Comcast, etc. But I have no idea what they look like when they reach their destination.

Mike
 

mtindor

Well-Known Member
Sep 14, 2004
1,394
72
178
inside a catfish
cPanel Access Level
Root Administrator
Actually I just set up a forwarder and tested it, and the new forwarder produces the same error / warning. But, it was delivered to its destination and looks fine.

Mike
 

cPanelNick

Administrator
Staff member
Mar 9, 2015
3,482
35
208
cPanel Access Level
DataCenter Provider
This generally just means the sender was remote. Example: [email protected] => forwarded address.

Right now we don't count messages from a remote sender to a remote redirected/forwarded address against the email send limits.

It might make sense to count the message as if owner of the redirect/forwarder is the sender. However its not that simple for messages sent to two or more redirected/forwarded addresses that send to remote addresses on different domains on the same server. In this circumstance you would effectively have one message with two senders.

Likewise ideas for how to handle these circumstances have been considered in case 59140, however there has been no final decision either way.
 

mtindor

Well-Known Member
Sep 14, 2004
1,394
72
178
inside a catfish
cPanel Access Level
Root Administrator
Re: check_mail_permissions could not determine the sender domain [case 5914

Ok. Nothing is broke then. Now that I know what it's all about, it's no big deal. But for those that don't know what it's all about, it sounds like there truly is a problem that might need some attention. Suggested handling would be to re-word the log message. I have no clue what to reword it to. I would suggest no mention of check_mail_permissions [since that sounds like somethings broken in Exim]. check_mail_permissions is only relevant to your developers, and your developers already know that this message is generated by that routine.

2012-04-29 20:44:47 1SOejM-0005ns-J2 [email protected] ==> [email protected] forwarded to [email protected] [sender_host_address=64.6.217.29 recipients_count=1]

I'd find that syntax pretty useful for troubleshooting forwarded mail. And the message ID wouldn't need to be listed twice in the log. It's already logged at the beginning.

My $0.02 . If it stays like it is, I'm okay with that too.

Thanks for the explanation, Nick.

Mike
 

sehh

Well-Known Member
Feb 11, 2006
579
5
168
Europe
Re: check_mail_permissions could not determine the sender domain [case 5914

I agree with mtindor, the message is misleading and if they don't fix the underlying issue, they should at least rename the error message to something more appropriate.
 

sneader

Well-Known Member
Aug 21, 2003
1,195
63
178
La Crosse, WI
cPanel Access Level
Root Administrator
Re: check_mail_permissions could not determine the sender domain [case 5914

+1 for mtindor's comments. I came here looking for help with the same "error". Confusing and misleading.

- Scott
 

cPanelNick

Administrator
Staff member
Mar 9, 2015
3,482
35
208
cPanel Access Level
DataCenter Provider
Re: check_mail_permissions could not determine the sender domain [case 5914

+1 for mtindor's comments. I came here looking for help with the same "error". Confusing and misleading.

- Scott
We have settled on a solution in the case. If we have time to implement it in 11.34 we will try to get it in there.
 

sneader

Well-Known Member
Aug 21, 2003
1,195
63
178
La Crosse, WI
cPanel Access Level
Root Administrator
Re: check_mail_permissions could not determine the sender domain [case 5914

Thanks for the update, Nick!

- Scott
 

gkgcpanel

Well-Known Member
Jun 6, 2007
214
1
166
cPanel Access Level
DataCenter Provider
So, now running WHM 11.36.1 (build 6) and I'm still getting these messages in the log files...

2013-05-19 22:48:20 1UeH5A-0008SX-5C <= [email protected] H=xxxxxxxx.xxxxx.xxxxxxx.com (xxxxxxxx.xxxxx.xxxxxxx.com) [nn.nnn.nn.nnn]:5134 P=esmtps X=TLSv1:AES128-SHA:128 S=392273 id=CDBF067C.1FD80%[email protected] T="Re: Bible Study reminder." for [email protected]
2013-05-19 22:48:20 cwd=/var/spool/exim 3 args: /usr/sbin/exim -Mc 1UeH5A-0008SX-5C
2013-05-19 22:48:20 1UeH5A-0008SX-5C check_mail_permissions could not determine the sender domain [routed_domain=gmail.com message_exim_id=1UeH5A-0008SX-5C sender_host_address=nn.nnn.nn.nnn recipients_count=1]
2013-05-19 22:48:21 1UeH5A-0008SX-5C => [email protected] <[email protected]> R=lookuphost T=remote_smtp H=gmail-smtp-in.l.google.com [173.194.77.26] X=TLSv1:RC4-SHA:128
2013-05-19 22:48:21 1UeH5A-0008SX-5C Completed

The message appears to have been delivered, but the customer is complaining that they didn't get it.

So was this fix implemented in 11.34 (as stated above)???
 

heyjohnboy

Well-Known Member
Oct 7, 2003
62
0
156
Valencia, CA
We are encountering this same issue on a new server that is currently running WHM 11.38.2, seeing lots of instances of the following error message:

check_mail_permissions could not determine the sender domain [routed_domain=xxxxxxxx.com message_exim_id=1VDygQ-0001km-Lh sender_host_address=xxx.xx.xxx.xx recipients_count=1]

They all appear to be caused by forwarders from the receiving mailbox to an external mailbox such as gmail, aol, etc.

Is there any new info regarding this error and how to resolve it? We just migrated an older Cpanel server to this new one, and the errors were not being generated on the old server. Thanks!

John
 

cPanelNick

Administrator
Staff member
Mar 9, 2015
3,482
35
208
cPanel Access Level
DataCenter Provider
The warning just means that a message could not be assigned to a user for accounting purposes ( mail delivery reports and email send limits.)

UPDATE: case 59140 missed the cutoff for 11.34 and we never came back to it (got lost in the shuffle). It is back on track now and in change review.
 

rvskin

Well-Known Member
PartnerNOC
Feb 19, 2003
400
1
168
Sorry to bring it back. Could you please explain what you have done for this case? I still find 'check_mail_permissions could not determine the sender domain' on cPanel/WHM 11.48. I know it is a warning that someone might abuse our server and could be easily to get blacklisted. But it is not clear to me that you count it toward a 'Number of failed or deferred messages a domain may send before protections can be triggered' or not?
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,909
2,228
463
Per internal case number 59140, the following changes were made:

- When a message is forwarded off server via a valiases file, the sender is now set to the owner of the forwarder.
- Forwarded messages are now counted against the email hourly limit.
- Ensured that forwarded messages do not get their "From:" header re-written.
The "check_mail_permissions could not determine the sender domain" warning message you see in /var/log/exim_mainlog is explained in this post:

The warning just means that a message could not be assigned to a user for accounting purposes ( mail delivery reports and email send limits.)
There's no plan to remove that message from /var/log/exim_mainlog as best I can tell, as it's an accurate message.

Thank you.