diff options
Diffstat (limited to 'content/mail')
| -rw-r--r-- | content/mail/inbox.md | 6 | ||||
| -rw-r--r-- | content/mail/rdns.md | 3 | ||||
| -rw-r--r-- | content/mail/smtp.md | 2 | ||||
| -rw-r--r-- | content/mail/validate.md | 29 |
4 files changed, 26 insertions, 14 deletions
diff --git a/content/mail/inbox.md b/content/mail/inbox.md index 9b45a77..3f70b9c 100644 --- a/content/mail/inbox.md +++ b/content/mail/inbox.md @@ -39,7 +39,7 @@ We also need two little DNS records set on your domain registrar's site/DNS serv ## Configuring Dovecot -Dovecot\'s configuration file is in `/etc/dovecot/docevot.conf`. If you +Dovecot\'s configuration file is in `/etc/dovecot/dovecot.conf`. If you open that file, you will see this line: `!include conf.d/*.conf` which adds all the `.conf` files in `/etc/dovecot/conf.d/` to the Dovecot configuration. @@ -114,10 +114,10 @@ service auth { } protocol lda { - mail_plugins = \$mail_plugins sieve + mail_plugins = $mail_plugins sieve } protocol lmtp { - mail_plugins = \$mail_plugins sieve + mail_plugins = $mail_plugins sieve } plugin { sieve = ~/.dovecot.sieve diff --git a/content/mail/rdns.md b/content/mail/rdns.md index 6a6ddf2..85cce0f 100644 --- a/content/mail/rdns.md +++ b/content/mail/rdns.md @@ -3,7 +3,8 @@ title: "Setup rDNS" tags: ['mail'] date: 2022-12-02 --- -While [DNS records](dns.html) refer a domain name to the IP address + +While [DNS records](/basic/dns) refer a domain name to the IP address where the the website is hosted, there is also rDNS (reverse DNS) and specifically PTR (pointer) records which do the reverse: link a server\'s IP to a domain name. diff --git a/content/mail/smtp.md b/content/mail/smtp.md index dee5640..3def765 100644 --- a/content/mail/smtp.md +++ b/content/mail/smtp.md @@ -25,7 +25,7 @@ If you want to start an email server, therefore, go to your VPS\'s site and open a ticket or make a request to open up email ports, notably port `25`. This is a simple process that requires nothing too special. One of the wagies at your VPS will kindly do the needful and open your ports for you. Note -that this is not the same as unblocking a port with [ufw](ufw.html), +that this is not the same as unblocking a port with [ufw](/../ufw), which still needs to be done for SMTP to work. ufw allow 25,587 proto tcp diff --git a/content/mail/validate.md b/content/mail/validate.md index 2e371b2..8447409 100644 --- a/content/mail/validate.md +++ b/content/mail/validate.md @@ -119,10 +119,9 @@ systemctl reload postfix ## Adding the DNS record! -We are only one step away from having functioning OpenDKIM. We must add -the DKIM public key to our server\'s DNS settings, so go ahead and open -up [your registrar\'s site](https://www.epik.com/?affid=we2ro7sa6) or -wherever your site\'s DNS settings are. +We are only one step away from having functioning OpenDKIM. We must add the +DKIM public key to our server\'s DNS settings, so go ahead and open up your +registrar\'s site or wherever your site\'s DNS settings are. The public key is found in the file `/etc/postfix/dkim/mail.txt`, but it will display as multiple lines and multiple quoted strings, which is @@ -145,9 +144,8 @@ host we put it for is `mail._domainkey`. {{< img alt="Adding the OpenDKIM TXT entry in DNS settings" src="/pix/dkim-01.png" link="/pix/dkim-01.png" >}} -On my registrar, Epik, this is how it is input, but on some registrars, -it may be required to include your domain name as well as -`mail._domainkey.example.org`. +On my registrar, this is how it is input, but on some registrars, it may be +required to include your domain name as well as `mail._domainkey.example.org`. If you have your own DNS server, add a TXT entry as follows: @@ -172,7 +170,7 @@ You can permanently change your hostname by changing it in `/etc/hostname` and rebooting, or you can just run `hostname example.org` to change it temporarily for testing. Either way, this will allow us to run the `mail` command as in [the SMTP -article](smtp.html). +article](../smtp). ```sh echo "Hi there. @@ -211,9 +209,22 @@ an email-authentication standard used to prevent spammers from sending messages that appear to come from a spoofed domain. cat /etc/mailname - echo "v=spf1 mx a:mail.$(cat /etc/mailname) -all" + IP4=<your VPS's IPv4 address> + IP6=<your VPS's IPv6 address> + echo "v=spf1 mx a:mail.$(cat /etc/mailname) ip4:$IP4 ip6:$IP6 -all" + +**Note**: previous versions of this guide didn't ask you to specify the `ip4` +and `ip6` mechanisms. If you don't include them, some email hosts (most +notoriously gmail) will not accept mail from your server. + +The `IP4` and `IP6` values should be the same as what you set your [PTR +records](../rdns) to. The output of `cat /etc/mailname` is the Host field. The output of the second command is the TXT value. Again, you can check [that site](https://appmaildev.com/en/spf) to make sure your DKIM, DMARC, and SPF entries are valid. That's it! + +## Contribution + +- SPF mechanisms updated by Martin Chrzanowski \-- [website](https://m-chrzan.xyz), [donate](https://m-chrzan.xyz/donate.html) |
