Skip to content

Commit 86af173

Browse files
committed
5G sidebar
1 parent d53aa10 commit 86af173

File tree

1 file changed

+120
-83
lines changed

1 file changed

+120
-83
lines changed

systems.rst

Lines changed: 120 additions & 83 deletions
Original file line numberDiff line numberDiff line change
@@ -13,23 +13,22 @@ Chapter 9: Other Examples
1313
Having focused on how to use the available cryptographic and
1414
authentication building blocks to secure the transport and network
1515
layers, we now turn our attention to other examples of how Internet
16-
systems are secured. The examples are part of the overall
17-
*defense-in-depth* strategy introduced in Chapter 2; they address
18-
specific threats—associated with specific use case—that remain even
19-
when mechansism like TLS and DNSSEC are deployed.
16+
systems are secured. The examples address specific threats—associated
17+
with specific use cases—that remain even when mechanism like TLS and
18+
DNSSEC are deployed.
2019

2120
The systems described in this chapter are at different layers: some
2221
are are built into applications, some run at the IP layer, and some
2322
secure network links. But while they address different layer-specific
2423
threats, what the examples have in common is that they all leverage
25-
the same set of security builing blocks. Seeing how these building
24+
the same set of security building blocks. Seeing how these building
2625
blocks can be assembled in different ways to build different solutions
2726
is main value of this chapter. To this end, the following sections
2827
focus on the use case and corresponding threat, with a high-level
29-
description of how the system addresses the threat; no new algoritms
28+
description of how the system addresses the threat; no new algorithms
3029
or fundamental capabilities are required.
3130

32-
It is also noteworthy that in addition to taking avantage of existing
31+
It is also noteworthy that in addition to taking advantage of existing
3332
building blocks, the example systems are highly configurable. The idea
3433
of making a security system algorithm independent is a good one,
3534
because you never know when your preferred cryptographic algorithm
@@ -136,7 +135,7 @@ consider two scenarios where it is used. Telecommuters often subscribe
136135
to ISPs that offer high-speed Internet access at home, and they use
137136
these ISPs (plus some chain of other ISPs) to reach machines operated
138137
by their employer. This means that when a telecommuter logs into a
139-
machine inside his employer’s data center, both the passwords and all
138+
machine inside their employer’s data center, both the passwords and all
140139
the data sent or received potentially passes through any number of
141140
untrusted networks. SSH provides a way to encrypt the data sent over
142141
these connections and to improve the strength of the authentication
@@ -145,16 +144,16 @@ employee connects to work using the public Wi-Fi at a coffee shop.)
145144

146145
A second common usage of SSH is to login into a remote router, server,
147146
or VM for the purpose of managing it; for example, changing its
148-
configuration, reading its log files, or installing the latest
149-
software. Clearly, an administrator wants to be sure that he can log
150-
into a remote machine securely and that unauthorized parties can
151-
neither log in nor intercept the commands sent to the machine or the
152-
output sent back to the administrator. This use case is common enough
153-
that SSH is often incorporated into more sophisticated management
154-
software that automates some aspect of remote management. This is
155-
increasingly the case for tools that support Cloud DevOps, with
156-
GitHub, Docker, Ansible, and Jenkins being popular examples that use
157-
SSH's remote execution feature.
147+
configuration, reading its log files, or installing the latest software.
148+
Clearly, administrators want to be sure that they can log into a
149+
remote machine securely and that unauthorized parties can neither log
150+
in nor intercept the commands sent to the machine or the output sent
151+
back to the administrator. This use case is common enough that SSH is
152+
often incorporated into more sophisticated management software that
153+
automates some aspect of remote operations. This is increasingly the
154+
case for tools that support Cloud DevOps, with GitHub, Docker,
155+
Ansible, and Jenkins being popular examples that use SSH's remote
156+
execution feature.
158157

159158
The latest version of SSH, Version 2, consists of three protocols:\ [#]_
160159

@@ -220,19 +219,20 @@ connect; standard SSH-TRANS only authenticates the server by default.
220219

221220
The main thing you should take away from this discussion is that SSH
222221
is a fairly straightforward application of the protocols and
223-
algorithms we have seen throughout this book. However, what
224-
sometimes makes SSH a challenge to understand is all the keys a user
225-
has to create and manage, where the exact interface is operating
226-
system dependent. For example, the OpenSSH package that runs on most
227-
Unix machines supports a command that can be used to create
228-
public/private key pairs. These keys are then stored in various files
229-
in directory in the user’s home directory. For example, file
230-
``~/.ssh/known_hosts`` records the keys for all the hosts the user has
231-
logged into, file ``~/.ssh/authorized_keys`` contains the public keys
232-
needed to authenticate the user when he or she logs into this machine
233-
(i.e., they are used on the server side), and file ``~/.ssh/id_rsa``
234-
contains the private keys needed to authenticate the user on remote
235-
machines (i.e., they are used on the client side).
222+
algorithms we have seen throughout this book. However, what sometimes
223+
makes SSH a challenge to understand is all the keys a user has to
224+
create and manage, where the exact interface is operating system
225+
dependent. For example, the OpenSSH package that runs on most Unix
226+
machines (e.g., Linux, MacOS) supports a command (``ssh-keygen``) that
227+
can be used to create public/private key pairs. These keys are then
228+
stored in various files in directory in the user’s home directory. For
229+
example, file ``~/.ssh/known_hosts`` records the keys for all the
230+
hosts the user has logged into, file ``~/.ssh/authorized_keys``
231+
contains the public keys needed to authenticate the user when he or
232+
she logs into this machine (i.e., they are used on the server side),
233+
and file ``~/.ssh/id_rsa`` contains the private keys needed to
234+
authenticate the user on remote machines (i.e., they are used on the
235+
client side).
236236

237237
.. _fig-ssh-tunnel:
238238
.. figure:: figures/f08-14-9780123850591.png
@@ -241,26 +241,26 @@ machines (i.e., they are used on the client side).
241241

242242
Using SSH port forwarding to secure other TCP-based applications.
243243

244-
Finally, SSH has proven so useful as a system for securing remote login,
245-
it has been extended to also support other applications, such as sending
246-
and receiving email. The idea is to run the applications over a secure
247-
“SSH tunnel.” This capability is called *port forwarding*, and it uses
248-
the SSH-CONN protocol. The idea is illustrated in :numref:`Figure
249-
%s <fig-ssh-tunnel>`, where we see a client on host A indirectly
250-
communicating with a server on host B by forwarding its traffic through
251-
an SSH connection. The mechanism is called *port forwarding* because
252-
when messages arrive at the well-known SSH port on the server, SSH first
253-
decrypts the contents and then “forwards” the data to the actual port at
254-
which the server is listening.
255-
256-
This is effectively a tunnel, which in this case happens to provide
257-
confidentiality and authentication. (In practice, it ma also get you
258-
through a corporate firewall, which leaves port 22 open.) It is
259-
possible to provide a kind of virtual private network (VPN) using SSH
260-
tunnels in this way. But unlike the VPN mechanism described in the
261-
next section, it is a tunnel to a single remote machine rather than to
262-
a remote network. The latter gives you access to *any* machine on the
263-
local network.
244+
Finally, SSH has proven so useful for securing remote login that it
245+
has been extended to also support other applications (e.g., sending
246+
and receiving email). The idea is to run the applications over a
247+
secure “SSH tunnel.” This capability is called *port forwarding*, and
248+
it uses the SSH-CONN protocol. The idea is illustrated in
249+
:numref:`Figure %s <fig-ssh-tunnel>`, where we see a client on host A
250+
indirectly communicating with a server on host B by forwarding its
251+
traffic through an SSH connection. The mechanism is called *port
252+
forwarding* because when messages arrive at the well-known SSH port on
253+
the server, SSH first decrypts the contents and then “forwards” the
254+
data to the actual port at which the server is listening.
255+
256+
Port forwarding effectively creates a secure tunnel that provides
257+
confidentiality and authentication. (In practice, it sometimes also
258+
gets you through a corporate firewall, which often leave port 22
259+
open.) It is possible to provide a kind of virtual private network
260+
(VPN) using SSH tunnels in this way, but unlike the VPN mechanism
261+
described in the next section, SSH tunnels to a single remote machine
262+
rather than to a remote network. The latter gives you access to *any*
263+
machine on the local network.
264264

265265
9.3 IP Security (IPsec)
266266
-------------------------
@@ -271,7 +271,7 @@ called, is optional in IPv4 but mandatory in IPv6. Indeed, better
271271
security was one of the stated goals of IPv6, although it turned out
272272
that the central ideas could also be retrofitted into IPv4. It's also
273273
noteworthy that while the original intent was for IPsec to be part
274-
securing the network infrastructrue (as discussed in the previous
274+
securing the network infrastructure (as discussed in the previous
275275
chapter), today IPsec is most commonly used to implement secure
276276
tunnels running on top of the public Internet. These tunnels are often
277277
part of a Virtual Private Network (VPN), for example, connecting a
@@ -374,15 +374,16 @@ destination.
374374
An IP packet with a nested IP packet encapsulated using ESP in tunnel
375375
mode. Note that the inner and outer packets have different addresses.
376376

377-
These tunnels may also be configured to use ESP with confidentiality and
378-
authentication, thus preventing unauthorized access to the data that
379-
traverses this virtual link and ensuring that no spurious data is
380-
received at the far end of the tunnel. Furthermore, tunnels can provide
381-
traffic confidentiality, since multiplexing multiple flows through a
382-
single tunnel obscures information about how much traffic is flowing
383-
between particular endpoints. A network of such tunnels can be used to
384-
implement an entire virtual private network. Hosts communicating over a
385-
VPN need not even be aware that it exists.
377+
These tunnels may also be configured to use ESP with confidentiality
378+
and authentication, thus preventing unauthorized access to the data
379+
that traverses this virtual link and ensuring that no spurious data is
380+
received at the far end of the tunnel. Furthermore, tunnels can
381+
provide traffic confidentiality, since multiplexing multiple flows
382+
through a single tunnel obscures information about how much traffic is
383+
flowing between particular endpoints. And as mentioned in the
384+
introduction to this section, a network of such tunnels can be used to
385+
implement an entire virtual private network. Hosts communicating over
386+
a VPN need not even be aware that it exists.
386387

387388
9.4 Web Authentication (WebAuthn) and Passkeys
388389
-----------------------------------------------
@@ -431,16 +432,19 @@ defined in the Web Authentication (WebAuthn) specification of the W3C
431432
efforts including those of the FIDO alliance (FIDO = Fast Identity
432433
Online).
433434

434-
The basic idea behind passkeys is simple enough: a user (or more
435-
likely, a device owned by the user) creates a private/public key pair
435+
The basic idea behind passkeys is simple: a user (or more likely, a
436+
device owned by the user) creates a private/public key pair
436437
specifically for a single web site and provides the public key to the
437438
site. The user proves their identity to the web site using some other
438439
method such as a previously established user name and password. The
439440
web site stores the public key for subsequent use. The next time that
440441
the user wants to authenticate to the web site, the site issues a
441442
challenge to the user, who uses the locally stored private key to sign
442443
their response to the challenge. The web site uses the stored public
443-
key to authenticate the user.
444+
key to authenticate the user. Said another way, if you are familiar
445+
with SSH's use of public/private key pairs to authenticate a user
446+
logging into a remote server, you understand how passkeys are used to
447+
log into a remote web service.
444448

445449
The fact that the process is bootstrapped by getting the user to
446450
authenticate using a traditional approach (such as user name and
@@ -475,18 +479,17 @@ names as the commercial offerings and standards around them have
475479
evolved. The generic names include U2F (universal second factor) and
476480
FIDO (from the FIDO Alliance).
477481

478-
Now that biometric
479-
authentication, such as facial and fingerprint recognition, is
480-
available on many devices, it is common to require biometric
481-
authentication to access a passkey. So a passkey might be stored on a
482-
mobile phone and require facial recognition of the owner before the
483-
passkey can be accessed.
484-
485-
The second class of passkey implementation allows the credentials to be
486-
copied among multiple devices, typically using some sort of password
487-
manager to keep the credentials secure and synchronized across
488-
devices. In this case, the private/public key pair is stored in the
489-
password manager and then is made available to the user across
482+
Now that biometric authentication, such as facial and fingerprint
483+
recognition, is available on many devices, it is common to require
484+
biometric authentication to access a passkey. So a passkey might be
485+
stored on a mobile phone and require facial recognition of the owner
486+
before the passkey can be accessed.
487+
488+
The second class of passkey implementation allows the credentials to
489+
be copied among multiple devices, typically using some sort of
490+
password manager to keep the credentials secure and synchronized
491+
across devices. In this case, the private/public key pair is stored in
492+
the password manager and then is made available to the user across
490493
different devices (laptops, mobile phones, etc.) when they need the
491494
passkey.
492495

@@ -543,20 +546,54 @@ corporate network if that same computer has, say, an Ethernet
543546
connection as well.
544547

545548
Consequently, there has been considerable work on securing Wi-Fi links.
546-
Somewhat surprisingly, one of the early security techniques developed
547-
for 802.11, known as Wired Equivalent Privacy (WEP), turned out to be
548-
seriously flawed and quite easily breakable.
549-
550549
The IEEE 802.11i standard provides authentication, message integrity,
551550
and confidentiality to 802.11 (Wi-Fi) at the link layer. *WPA3* (Wi-Fi
552551
Protected Access 3) is often used as a synonym for 802.11i, although it
553552
is technically a trademark of the Wi-Fi Alliance that certifies product
554553
compliance with 802.11i.
555554

556555
For backward compatibility, 802.11i includes definitions of
557-
first-generation security algorithms—including WEP—that are now known to
558-
have major security flaws. We will focus here on 802.11i’s newer,
559-
stronger algorithms.
556+
first-generation security algorithms—including Wired Equivalent
557+
Privacy (WEP)—that are now known to have major security flaws. We will
558+
focus here on 802.11i’s newer, stronger algorithms.
559+
560+
.. admonition:: Securing Mobile Cellular Networks
561+
562+
The other widely used wireless networking technology is the Mobile
563+
Cellular Network, today ubiquitously known as 5G. The biggest
564+
difference between 5G and Wi-Fi is that the Mobile Network Operator
565+
(MNO)—the counterpart of an enterprise network administrator—has
566+
more direct control over the devices that are allowed to connect to
567+
their network. Specifically, the MNO provides a Subscriber Identity
568+
Module (SIM) card that must be present in the mobile device. This
569+
SIM hosts a small database that includes a globally unique
570+
identifier (known as an IMSI, for International Mobile Subscriber
571+
Identifier) and a secret key.
572+
573+
When a device first becomes active, it communicates with a nearby
574+
base station over an unauthenticated radio channel. The base
575+
station forwards the request to a backend server over a secure
576+
backhaul connection, and that server (assuming it recognizes the
577+
IMSI) initiates an authentication protocol with the device. There
578+
are a set of options for authentication and encryption, but AES is
579+
commonly used. Note that this authentication exchange is initially
580+
in the clear since the base station to device channel is not yet
581+
secure. (The 5G specification uses significantly more precise
582+
terminology for all its components, but "backend server" conveys
583+
the basic idea; it is analogous to the AS used by Wi-Fi.)
584+
585+
Once the device and backend server are satisfied with each other's
586+
identity, the server informs the other 5G components of the
587+
parameters they will need to service the device (e.g., the IP
588+
address assigned to the device and the appropriate QoS
589+
parameters). It also instructs the base station to establish an
590+
encrypted channel to the device and gives the device the symmetric
591+
key it will subsequently use for the encrypted data channel with
592+
the base station. This symmetric key is encrypted using the public
593+
key of the device, so only the device can decrypt it. It does this
594+
using the secret key on its SIM card. Once complete, the device can
595+
use this encrypted channel to send and receive data over the
596+
wireless link to the base station.
560597

561598
802.11i authentication supports two modes. In either mode, the end
562599
result of successful authentication is a shared Pairwise Master Key.

0 commit comments

Comments
 (0)