1 00:00:00,000 --> 00:00:00,900 In this lesson, 2 00:00:00,900 --> 00:00:03,870 we're going to discuss email ports and protocols. 3 00:00:03,870 --> 00:00:05,250 Email ports and protocols 4 00:00:05,250 --> 00:00:07,590 refer to the conventions and numerical gateways 5 00:00:07,590 --> 00:00:10,560 that govern the transmission of emails across the internet. 6 00:00:10,560 --> 00:00:13,410 These protocols are the backbone of email communication, 7 00:00:13,410 --> 00:00:15,660 and they ensure that messages are sent, received, 8 00:00:15,660 --> 00:00:17,460 and managed efficiently. 9 00:00:17,460 --> 00:00:19,483 Now, email communication primarily involves 10 00:00:19,483 --> 00:00:24,483 three main protocols, this is SMTP, POP3, and IMAP. 11 00:00:24,930 --> 00:00:26,220 Each of these plays a unique role 12 00:00:26,220 --> 00:00:28,770 in the email delivery and retrieval process, 13 00:00:28,770 --> 00:00:30,450 and they operate using specific ports 14 00:00:30,450 --> 00:00:32,640 that facilitate these operations. 15 00:00:32,640 --> 00:00:35,370 First, let's talk about SMTP. 16 00:00:35,370 --> 00:00:38,670 Now, SMTP or the Simple Mail Transfer Protocol, 17 00:00:38,670 --> 00:00:40,860 is the standard protocol used for sending emails 18 00:00:40,860 --> 00:00:42,270 across the internet. 19 00:00:42,270 --> 00:00:44,970 SMTP operates over Port 25, 20 00:00:44,970 --> 00:00:47,340 which is the default port used by email servers 21 00:00:47,340 --> 00:00:49,560 to relay messages to one another. 22 00:00:49,560 --> 00:00:52,830 SMTP is used for the transmission of outbound emails, 23 00:00:52,830 --> 00:00:54,840 and it's the protocol that your email server 24 00:00:54,840 --> 00:00:56,400 is going to use to send your message 25 00:00:56,400 --> 00:00:58,410 to the recipient email server. 26 00:00:58,410 --> 00:01:00,150 It's important to note that SMTP 27 00:01:00,150 --> 00:01:03,030 is only used for sending emails from your server 28 00:01:03,030 --> 00:01:04,980 and not for receiving them. 29 00:01:04,980 --> 00:01:08,160 Now, SMTP is operating over port 25, 30 00:01:08,160 --> 00:01:09,990 and it's considered to be an insecure protocol 31 00:01:09,990 --> 00:01:12,690 because the data is going to be sent in plain text. 32 00:01:12,690 --> 00:01:14,820 Due to the increasing concerns over email security, 33 00:01:14,820 --> 00:01:19,820 though, SMTPS was introduced as a secure variant of SMTP 34 00:01:20,070 --> 00:01:25,070 SMTPS or SMTP Secure is not really a protocol itself, 35 00:01:25,080 --> 00:01:27,990 but rather it's a way to secure the SMTP protocol 36 00:01:27,990 --> 00:01:30,390 by transporting it via the secure socket layer 37 00:01:30,390 --> 00:01:32,790 or transport layer security protocols. 38 00:01:32,790 --> 00:01:34,290 This creates an encrypted tunnel, 39 00:01:34,290 --> 00:01:36,720 and then the SMTP protocol can tunnel its data 40 00:01:36,720 --> 00:01:38,640 through that encryption tunnel. 41 00:01:38,640 --> 00:01:43,513 SMTPS is going to operate over port 465 or port 587 42 00:01:44,460 --> 00:01:46,740 to ensure that the email messages are being encrypted 43 00:01:46,740 --> 00:01:47,670 during transit 44 00:01:47,670 --> 00:01:50,040 and they're protected from being read or tampered with 45 00:01:50,040 --> 00:01:52,740 by unauthorized parties or attackers. 46 00:01:52,740 --> 00:01:54,840 Second, we have POP3. 47 00:01:54,840 --> 00:01:58,140 Now, POP3 or Post Office Protocol Version Three 48 00:01:58,140 --> 00:01:59,370 is used to retrieve emails 49 00:01:59,370 --> 00:02:03,360 from a remote server to a local client over port 110. 50 00:02:03,360 --> 00:02:05,190 The POP3 protocol is designed 51 00:02:05,190 --> 00:02:07,650 to download messages from the server to the email client 52 00:02:07,650 --> 00:02:08,970 and then delete those messages 53 00:02:08,970 --> 00:02:11,760 from the email server after they were downloaded. 54 00:02:11,760 --> 00:02:12,900 Now, this was the primary way 55 00:02:12,900 --> 00:02:16,470 that email was received in the 1990s and the early 2000s 56 00:02:16,470 --> 00:02:19,170 when most people only had access to a single computer 57 00:02:19,170 --> 00:02:20,730 that they used on a daily basis, 58 00:02:20,730 --> 00:02:22,800 like their desktop computer at work. 59 00:02:22,800 --> 00:02:24,420 Now, this was great back in the old days 60 00:02:24,420 --> 00:02:26,220 when we didn't have the always on internet connections, 61 00:02:26,220 --> 00:02:28,800 we have today because back then you'd actually have to make 62 00:02:28,800 --> 00:02:30,600 a phone call using your computer 63 00:02:30,600 --> 00:02:33,116 by using a dial up modem to call that server, 64 00:02:33,116 --> 00:02:34,320 and then you download emails 65 00:02:34,320 --> 00:02:36,060 and then access them from your computer, 66 00:02:36,060 --> 00:02:37,860 whether you were online or offline, 67 00:02:37,860 --> 00:02:39,570 because those emails were now located 68 00:02:39,570 --> 00:02:42,090 on your local machine after you downloaded them. 69 00:02:42,090 --> 00:02:44,010 The problem with this is that you were then limited 70 00:02:44,010 --> 00:02:46,710 if you wanted to access your email from multiple devices, 71 00:02:46,710 --> 00:02:48,540 because the messages might only be available 72 00:02:48,540 --> 00:02:50,910 on the first device that downloaded them. 73 00:02:50,910 --> 00:02:53,490 Now, in subsequent updates to the POP3 protocol, 74 00:02:53,490 --> 00:02:55,350 they now have the option to download the emails 75 00:02:55,350 --> 00:02:56,183 from the server 76 00:02:56,183 --> 00:02:59,340 and to still keep the original copy on that server, 77 00:02:59,340 --> 00:03:01,230 but the read or delete status 78 00:03:01,230 --> 00:03:03,270 was not synchronized across devices, 79 00:03:03,270 --> 00:03:05,850 which still made it a less usable option than IMAP, 80 00:03:05,850 --> 00:03:07,680 which we're going to discuss shortly. 81 00:03:07,680 --> 00:03:09,360 Now, before we move into IMAP though, 82 00:03:09,360 --> 00:03:12,270 it's important to point out that POP3 by default 83 00:03:12,270 --> 00:03:14,460 does transmit the emails in plain text 84 00:03:14,460 --> 00:03:17,310 because it is considered to be an insecure protocol. 85 00:03:17,310 --> 00:03:18,960 To overcome this limitation, 86 00:03:18,960 --> 00:03:22,620 there was a secure variant called POP3S or POP3 Secure 87 00:03:22,620 --> 00:03:23,815 that was created. 88 00:03:23,815 --> 00:03:27,690 POP3 Secure typically operates over Port 995 89 00:03:27,690 --> 00:03:31,440 using an SSL or TLS tunnel to encrypt the POP3 data 90 00:03:31,440 --> 00:03:34,950 as it moves between an email server and an email client. 91 00:03:34,950 --> 00:03:36,780 Third, we have IMAP. 92 00:03:36,780 --> 00:03:39,990 Now IMAP stands for the Internet Message Access Protocol, 93 00:03:39,990 --> 00:03:42,210 and it offers more flexibility than POP3 94 00:03:42,210 --> 00:03:44,100 when you're receiving your emails. 95 00:03:44,100 --> 00:03:47,340 IMAP is going to operate over Port 143, 96 00:03:47,340 --> 00:03:48,810 and it allows you to manage your emails 97 00:03:48,810 --> 00:03:50,850 directly on the email server. 98 00:03:50,850 --> 00:03:53,520 This means that you can access and synchronize your messages 99 00:03:53,520 --> 00:03:55,020 across multiple devices 100 00:03:55,020 --> 00:03:57,810 as long as you have an available internet connection. 101 00:03:57,810 --> 00:04:00,300 IMAP was really developed for the always on internet age 102 00:04:00,300 --> 00:04:01,680 that we currently live in, 103 00:04:01,680 --> 00:04:03,720 and IMAP in particular is useful 104 00:04:03,720 --> 00:04:06,540 if you frequently check your email from different devices 105 00:04:06,540 --> 00:04:09,300 such as your work computer, your laptop, your tablet, 106 00:04:09,300 --> 00:04:10,470 and your smartphone, 107 00:04:10,470 --> 00:04:12,810 because it ensures that your inbox, your set items, 108 00:04:12,810 --> 00:04:15,180 and your organization are consistent across 109 00:04:15,180 --> 00:04:17,910 all of those devices, including your read, delete, 110 00:04:17,910 --> 00:04:20,610 and send status for each of those emails. 111 00:04:20,610 --> 00:04:21,839 Like POP3, though, 112 00:04:21,839 --> 00:04:24,600 IMAP was not initially created with security in mind 113 00:04:24,600 --> 00:04:26,460 and it transmits the emails in plain text 114 00:04:26,460 --> 00:04:28,380 between the server and the client. 115 00:04:28,380 --> 00:04:30,030 To increase our email security, 116 00:04:30,030 --> 00:04:33,840 we should instead select IMAPS, also known as IMAP Secure, 117 00:04:33,840 --> 00:04:36,270 instead of the original IMAP protocol, 118 00:04:36,270 --> 00:04:39,600 IMAP Secure operates over Port 993 119 00:04:39,600 --> 00:04:41,580 to provide a secure and encrypted connection 120 00:04:41,580 --> 00:04:44,010 between the email server and the email client 121 00:04:44,010 --> 00:04:46,080 by transmitting data inside of an encrypted 122 00:04:46,080 --> 00:04:47,880 SSL or TLS tunnel, 123 00:04:47,880 --> 00:04:49,980 and then sending the data through the encryption tunnel 124 00:04:49,980 --> 00:04:52,620 using the standard IMAP protocol. 125 00:04:52,620 --> 00:04:55,636 So remember, when it comes to email ports and protocols, 126 00:04:55,636 --> 00:04:59,430 SMTP and SMTPS are going to be used for setting emails. 127 00:04:59,430 --> 00:05:02,520 With SMTPS, providing a secure and encrypted path 128 00:05:02,520 --> 00:05:04,495 for the data to be transmitted. 129 00:05:04,495 --> 00:05:07,470 POP3 and IMAP are both used for receiving emails, 130 00:05:07,470 --> 00:05:10,290 but IMAP offers more sophisticated email management 131 00:05:10,290 --> 00:05:11,760 if you're going to be accessing your email 132 00:05:11,760 --> 00:05:13,350 from multiple devices. 133 00:05:13,350 --> 00:05:15,450 Anytime you're configuring your email systems, 134 00:05:15,450 --> 00:05:18,060 you should set them up to provide the more secure variants 135 00:05:18,060 --> 00:05:21,960 like SMTPS, POP3S and IMAPS 136 00:05:21,960 --> 00:05:23,340 to increase your level of security 137 00:05:23,340 --> 00:05:24,930 and prevent a successful eavesdropping 138 00:05:24,930 --> 00:05:27,150 or an on-path attack from occurring. 139 00:05:27,150 --> 00:05:28,710 By understanding these protocols, 140 00:05:28,710 --> 00:05:29,910 you can ensure that your messages 141 00:05:29,910 --> 00:05:32,733 are being sent and received securely and efficiently.