In this installment, I’ll start talking about some of the parts (“infrastructure”) that you need to have in place before you can think about hosting an email service.

IP Addresses, Redux

Last time I talked about IP addresses, and said “[Internet connected] computers are identified by an IP address.” You may have heard about “IP address exhaustion,” the problem that there are so many Internet-connected devices these days that there aren’t enough addresses for all of them. This problem applies to IPv4[1] addresses, which is the sort you’ve probably seen (four numbers separated by dots, like “192.168.0.129”). To fix this scarcity[2], eggheads came up with IPv6[3], which provides for about a quadrillion-quadrillion more addresses[4]. But even with this vastly greater range of addresses, you can’t just pick a random address and expect that to work on the Internet. Recall last time I also said, “IP addresses are routable,” and for that routing to work in a tractable way, there has to be some organization to how addresses are handed out.

Whose IP Address Is It, Anyway?

Generally speaking, the ultimate authority for all the IP addresses in the world rests with the Internet Assigned Numbers Authority (IANA). In practice, all not-quite-4 billion IPv4 addresses and the gazillion IPv6 addresses are broken into blocks and authority for each block is delegated to other entities: public or private corporations, government agencies, etc. These entities in turn break their blocks into smaller blocks and hand those out, etc. This hierarchical delegation is what makes IP addresses routable. A central Internet router only needs to look at the first part of an address to know that it is in a block delegated to, say, the Asia-Pacific network authority. Successive routers will determine the address to be in a block delegated to China Telecom, then a smaller block allocated to ChinaNet Ningbo, then a still smaller block allocated to Fenghua Hospital, where one of the night orderlies uses their work computer to send spam emails cleverly crafted to convince the unsuspecting to click on links to micorsoft.com. By the same mechanism, the IP address on your phone or computer is assigned to you through of a chain of delegations.

Static Versus Dynamic

But how is that address assignment accomplished? Back in days of yore, every IP address was manually configured. That is, after you unboxed your shiny new DECStation and jammed a vampire tap into the 10base5 thick wire that ran under your desk, you went down to the suspender-wearing beardo and asked him[5] what address you should use. That address, then, was permanently (today, we would say “statically”) assigned to your computer. This process, elegant as it seems, has a small scalability problem. Even for a small network, it’s inconvenient and error prone. In a larger network, it’s onerous and, when addresses are scarce, it’s wasteful to permanently assign an address to devices that may be used only infrequently.

Dynamic address assignment is meant to solve all these problems[6]. Through a mechanism I won’t explain[7], when a device joins a network, an IP address is temporarily, or “dynamically,” assigned for some period of time. When the device leaves, it relinquishes the address. Or, if the time expires and the device hasn’t asked for an extension (if it’s turned off, etc.), the address is reclaimed. The IP addresses on every device in your day-to-day life (phones, tablets, etc.) are almost certainly dynamically assigned. Even something like a cable modem that does not, for the most part, move around or get turned off still has a dynamic address, it just keeps requesting extensions. Try turning it off and going on vacation for a week, you’ll have a different address when you get back.

Tinned Pork Product

A static IP address is a hard requirement for running an email server[8]. There are a few reasons for this, but mostly it has to do with our friend in Fenghua Hospital. Preventing spam email is a Sisyphean task that requires a layered strategy. The first layer is, simply, don’t accept email from mail servers that look shady, and the reddest of red flags is a mail server that is sending from a dynamic address. It’s not hard to learn the ranges of IP addresses that ISPs have reserved for dynamic allocation. There are lists compiled just for the purpose of limiting spam[9], and most big email providers will refuse to talk to mail servers with a dynamic address. There are other reasons why you want a static address, and I’ll talk about those next time.

 


[1] Internet Protocol version 4, first deployed in 1982-83.

[2] And to rethink some of the original design decisions, based on how people actually use the Internet.

[3] Internet Protocol version 6, duh. Design was finalized in 1998, but the standard was not ratified until 2017.

[4] IPv4 has on the order of 10^9 addresses, vs. order of 10^38 for IPv6.

[5] Theoretically possible it was a “her”, but let’s be honest here.

[6] Don’t worry about the beardo, configuring DHCP servers is complicated enough to guarantee job security.

[7] Okay, since I teased it in footnote [6], it’s Dynamic Host Control Protocol (DHCP).

[8] Assuming you want to be able to send email, that is.

[9] Blackhole lists, that also include other IP addresses known to generate spam.