So I have thought about this a little more and a few amendments to my original proposition,
1: Would also need a hook file to create forwards for addon/alias domains
2: Rather than creating a forwarder to
[email protected] domain could these reports be forwarded to the account default email address/catchall
[email protected]$domain sort of thing?
This would allow addon domains and root domains to be sent to a mailbox the users can access and deal with or not as they wish also once the account is setup these forwarders can be amended/added to to give third parties access/copies of these emails to analyze the results. This would also allow for a script that could be implemented across multiple servers without editing in a hardcoded email address or pulling the email from the server contact details email and forcing the server admins to deal with all of these (hint hint cPanel can implement this as part of the whole system maybe?)
Additionally an option to purge these account default mailboxes of emails older than XX days to prevent disk usage creep would be nice. simple nightly cron might do this something like:
Code:
for user in `/bin/ls -A /var/cpanel/users` ; do find /home/$user/mail/cur/ -mtime +14 -exec rm -rf {} \; done
for user in `/bin/ls -A /var/cpanel/users` ; do find /home/$user/mail/new/ -mtime +14 -exec rm -rf {} \; done
(I need to check this code haven't tested yet but something like this) possibly have this as an option in tweak settings instead of just "system account" "fail" "black hole" have additional options under "system account" for "server wide" with number of days to retain for on a server wide setting or "user managed" to put this same option in the individual cPanel's for customers to decide the retention period themselves
I agree not many users actually WANT the reports or know what to do with them if they had them but they do want the DMARC in place for email delivery/spam prevention and this is the best option I have come up with so far for automating this setup on a server wide scale