[英]Send mail in phpmailer using DKIM Keys
Currents i am using phpmailer to send mail's. Currents 我正在使用 phpmailer 发送邮件。 now how its possible to send email in phpmailer with DKIM keys
现在如何使用 DKIM 密钥在 phpmailer 中发送电子邮件
i search in phpmailer Class file and i found the below code我在 phpmailer 类文件中搜索,我找到了下面的代码
/**
* DKIM selector.
* @type string
*/
public $DKIM_selector = '';
/**
* DKIM Identity.
* Usually the email address used as the source of the email
* @type string
*/
public $DKIM_identity = '';
/**
* DKIM passphrase.
* Used if your key is encrypted.
* @type string
*/
public $DKIM_passphrase = '';
/**
* DKIM signing domain name.
* @example 'example.com'
* @type string
*/
public $DKIM_domain = '';
/**
* DKIM private key file path.
* @type string
*/
public $DKIM_private = '';
Can i know how its possible.我能知道它是如何可能的吗?
If you take a look in the PHPMailer unit tests , there is an example of how to set up DKIM.如果您查看PHPMailer 单元测试,有一个关于如何设置 DKIM 的示例。
Here are the basics beyond what you already need to do to send a message (obviously change the domain, key path and selector to match your config, and add a passphrase if you use one);以下是发送消息所需的基础知识(显然,更改域、密钥路径和选择器以匹配您的配置,并在使用密码时添加密码); this also assumes that you are intending to sign using the same identifier as your
From
address:这还假设您打算使用与您的
From
地址相同的标识符进行签名:
$mail->DKIM_domain = 'example.com';
$mail->DKIM_private = '/path/to/my/private.key';
$mail->DKIM_selector = 'phpmailer';
$mail->DKIM_passphrase = '';
$mail->DKIM_identity = $mail->From;
When you send()
the message (and not before), it will use these settings to generate a DKIM signature.当您
send()
消息时(而不是之前),它将使用这些设置来生成 DKIM 签名。
I have the following experience:我有以下经验:
Start here 从这里开始
http://dkim.worxware.com/ http://dkim.worxware.com/
At the bottom - click Continue....this will take you to the tool to generate the private key, public key and how to use them 在底部 - 单击继续....这将带您到工具生成私钥,公钥以及如何使用它们
It will alow you to generate private/public key with instructions 它将使您生成带有指令的私钥/公钥
In brief: - seup to send using the private/public key file to add dkim headers in email header - modify DNS txt record for the public key 简而言之: - 使用私钥/公钥文件发送seup以在电子邮件头中添加dkim头 - 修改公钥的DNS txt记录
There are NO tutorials as of today's date - I FOUND it this after gettin g nowhere for a couple months 截至今天的日期没有任何教程 - 我发现它几个月之后无处可去
HTH HTH
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.