Vesta Control Panel - Forum

Community Forum

Skip to content

Advanced search
  • Quick links
    • Main site
    • Github repo
    • Google Search
  • FAQ
  • Login
  • Register
  • Board index Main Section Web Server
  • Search

DKIM/DomainKEY settings if using Google Apps

Questions regarding the Web Server
Apache + Nginx, Nginx + PHP5-FPM
Post Reply
  • Print view
Advanced search
5 posts • Page 1 of 1
mehargags
Support team
Posts: 1096
Joined: Sat Sep 06, 2014 9:58 pm
Contact:
Contact mehargags
Website Skype

Os: Debian 8x
Web: apache + nginx
DKIM/DomainKEY settings if using Google Apps
  • Quote

Post by mehargags » Mon Feb 09, 2015 1:10 pm

I Have my DNS outside of VestaCP Server, and the domain hosted is using incoming Emails via Google apps. however the website generates and send a lot of mail from the PHP app, I want to know what I shall put in my DNS so that the mail generated from my VestaCP server (PHP generated) lands well and not marked SPAM



by Default VestaCP creates this in its DNS records when DKIM support is checked

Code: Select all

mail._domainkey 	TXT 		"k=rsa; 

Code: Select all

p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCZHHdiKNdEbN3tMJTKqW0BxjLZi1c76Cb+aRfhc1tNE57bfjw59S96bXJc1U+s4S9zR3J3GkHk/4uIRL13XX0rwNwFCJ35Bq2EFGb0DmFPT+5jHoUKJwZLAqJjfHhbU9oz+5JsYh38dAOp2sp6afpJrp9n3V5cMhEujsSk3dsaQwIDAQAB"

Code: Select all

_domainkey 	TXT 		"t=y; o=~;"
should these be copied to my external DNS?

Are PHP Generated mails signed with domainkey/DKIM or not ?

I do have the SP4 with IPv4 set in my DNS properly. is that enought ?

Thanks alot
Top

skurudo
VestaCP Team
Posts: 8099
Joined: Fri Dec 26, 2014 2:23 pm
Contact:
Contact skurudo
Website Facebook Google+ Skype
Twitter

Re: DKIM/DomainKEY settings if using Google Apps
  • Quote

Post by skurudo » Mon Feb 09, 2015 9:36 pm

I think there is another way to solve this problem.

When you use extternal mail like Google mail (Google apps) or Yandex mail for domain (lile me), you have two ways:
1) external smtp (it's options, nothing more)
2) or use DKIM

Let's chose second way. We alreade have DKIM support from Google. If we have to sign mail with google dkim, we have to obtain private RSA key (I don't understand how) and we must use DKIM public and private keys from google only. But we have dkim selectors and we can change selector in exim -> /etc/exim4/exim4.conf.template (for debian, in centos conf file may be have another location) -> from

Code: Select all

dkim_selector = mail
to

Code: Select all

dkim_selector = vmail
Restart exim and then add in your DNS (external and local) new TXT record -- vmail._domainkey

All your mail will be signed by local dkim and in DNS you already have proof, that's mail from your server and signed by your MTA. It's works by the way, I checked this myself in Gmail and Yandex.mail.

PS: Don't forget, you must have correct SPF record too. It's important.
Top

mehargags
Support team
Posts: 1096
Joined: Sat Sep 06, 2014 9:58 pm
Contact:
Contact mehargags
Website Skype

Os: Debian 8x
Web: apache + nginx
Re: DKIM/DomainKEY settings if using Google Apps
  • Quote

Post by mehargags » Tue Feb 10, 2015 1:58 pm

Ok thanks.

slightly different scenario, Can you tell me how I can make System Generated (Php & code) Email to land safely in hotmail, gmail and other services.

I know how to set ip4 x.x.x.x in the spf for this tast, is there a way to DKIM Sign the Php generated mails ?
that raises another questions, how to setup this for different domains hosted ?

Is there a way Exim can sense the mail being called from, and properly sign the outgoing mail with appropriate key ??

Sorry if I'm asking too much, I will be happy to clear up more thoughts on this if I'm not clear on the questions.

Thanks
Top

mehargags
Support team
Posts: 1096
Joined: Sat Sep 06, 2014 9:58 pm
Contact:
Contact mehargags
Website Skype

Os: Debian 8x
Web: apache + nginx
Re: DKIM/DomainKEY settings if using Google Apps
  • Quote

Post by mehargags » Sat Feb 14, 2015 8:39 am

on another note... is there a way you can DKIM sign the outgoing mails generated by PHP Mail() ??

Since PHP and Apache2 both run as a "user" on the system, there must some way for Exim to know the request coming in and Sign the outgoing mails generated through PHP.
Top

skurudo
VestaCP Team
Posts: 8099
Joined: Fri Dec 26, 2014 2:23 pm
Contact:
Contact skurudo
Website Facebook Google+ Skype
Twitter

Re: DKIM/DomainKEY settings if using Google Apps
  • Quote

Post by skurudo » Sat Feb 14, 2015 6:27 pm

If you find another way, tell me too.
Top


Post Reply
  • Print view

5 posts • Page 1 of 1

Return to “Web Server”



  • Board index
  • All times are UTC
  • Delete all board cookies
  • The team
Powered by phpBB® Forum Software © phpBB Limited
*Original Author: Brad Veryard
*Updated to 3.2 by MannixMD
 

 

Login  •  Register

I forgot my password