Open main menu

CDOT Wiki β

Changes

OPS335 Lab 4b

358 bytes added, 21:07, 5 January 2021
m
Reverted edits by Andrew (talk) to last revision by Ahadalioglu
|-
| '''security''' || SSL/TLS || STARTTLS
|-
| '''References'''
| colspan="2" | [1] [https://inside.senecacollege.ca/its/services/email/studentemployee/email_clients/othermail.html Configuring other Email Clients]<br> [2] [https://ssgoku129.wordpress.com/2012/11/29/how-to-setup-seneca-learnid-myseneca-ca-with-email-clients-and-devices/ How-to setup Seneca LearnID @myseneca.ca with Email Clients]
|}
<ol><li value="4">Edit the '''/etc/postfix/main.cf''' file for '''vm2 vm3 ONLY''', scroll down to the line containing: '''mydestination''' and change line to the text shown below:<br><source>mydestination = $mydomain, $myhostname, localhost.$mydomain, localhost</source>'''Note:''' Even though your machine's name is ''vm2vm3.yoursenecaid.ops'', your postfix MTA will also receive emails addressed to the domain called: yoursenecaid.ops</li></ol>
<br>
::In order for this to work, we need to add a DNS record that will point mail sent to the domain towards one of the SMTP servers configured to accept it.
<ol><li value="5">Add an '''MX''' record to the forward lookup zone on '''host''' so that all incoming mail addressed to the domain is sent to your vm2vm3.</li><li>Restart the service and use the '''dig''' command to confirm that it works.</li><li>Send an email from your '''vm3vm2''' to '''root@yourdomain.ops'''</li><li>Confirm that it arrives on your '''vm2vm3''' machine</li></ol>
=== Relay Email Through Another Server===
When email is sent from either vm, it is addressed from the domain, but receiving MTAs might query why mail sent from vm2 doesn't match the address of the MX record for the domain. This would be a red-flag for potential spam. To avoid this, we can relay all mail sent from vm3 vm2 (or any other machine in our network) through vm2 vm3 so that it properly appears to come from the mail server that matches the MX record for the domain.
'''Perform the following steps:'''
# Move to your vm3 vm2 machine.# Direct your '''vm3vm2''' MTA to relay mail through vm2vm3, by making the following editing change for the '''/etc/postfix/main.cf''' file:<br><source>relayhost = vm2vm3.<yourdomain>.ops</source>
# Restart the '''postfix''' service.
# Next, you must instruct your '''vm2vm3''' machine to allow your vm3 vm2 machine to pass email through it by making the following editing change to the '''/etc/postfix/main.cf''' file:<br><source>mynetworks = 192.168.X.0/24</source>NOTE: Substitute in your '''own network''' for X<br><br>
# Restart the '''postfix''' service.