The IP Security Protocol, Part 2
Up to now, we have been talking about IPSec relationships between two communicating peers, taking for granted the existence of some kind of trusted liaison between them. In IPSec jargon, this relationship is called a security association (SA). For each IPSec instance (i.e., each peer it is communicating with), a host or gateway keeps an SA that collects all the information related to the instance itself. For example, it may contain the following:
IPSec mode (either tunnel or transport)
negotiated encryption algorithms
SA granularity (which depends on the selector, described below)
An SA is uniquely identified by three parameters:
SPI (Security Parameter Index)
destination IP address
security protocol (either AH or ESP)
The SA represents a monodirectional, secure logical channel working with a single security protocol. If a bidirectional data exchange is required (normally it is), two SAs are needed. Also, if both AH and ESP are required for communication, two SAs for each direction are needed.
For each network interface enabled to "talk" IPSec, two databases are maintained: the SA database (SAD) and the security policy database (SPD). When a packet is being sent, the IPSec layer looks for its destination address in the SAD. If an entry is found, the relevant information is extracted and used to properly protect and encapsulate the packet.
On the receiving side, the arrival of a packet triggers a search by the SPD, which identifies the policies that should be applied to the packet. The key used for the look up in the SPD is called the packet selector. In IPSec terminology, this is information extracted from the packet (e.g., IP source and destination addresses, TCP or UDP ports and so on) sufficient to define the packet flow belonging to the SA. Depending on whether the selector is fine- or coarse-grained, an SA may be applied to all the packets exchanged between two peers (regardless of L4 protocols and ports) or to a specific packet flow. For example, if you wanted to define an IPSec channel for receiving HTTP data from a specific IPSec-enabled web server, the selector would be (<destination address: your IP>, <source address: web server's IP>, <L4 protocol: TCP>, <source port: 80>).
Three policies may be applied to a received packet, depending on the result of the SPD search:
discard the packet
bypass IPSec and process the packet normally (IPSec is not used for this packet flow)
apply IPSec according to what is specified in the SAD
According to these procedures, each packet going through an IPSec-enabled interface is subject to IPSec policies. In particular, packets that do not contain any IPSec fields are filtered. When no entry is found in the SPD for a particular packet's selector, the default behavior is to discard the packet.
As we have seen, the whole IPSec architecture is based on the presence of some common secret keys on both peers. Before any secure communication may begin, such keys are used to establish the SA. Keys may be manually configured on the peers (e.g., a passphrase may be agreed between the security administrators), or they may be automatically distributed using the IKE procedure. The keys may range from simple two-host shared secrets to digital certificates issued by official certification authorities. Hence, IKE can scale from a simple point-to-point data exchange mechanism to a complex network of encrypting hosts.
The IKE procedure creates a secure tunnel between two peers and then uses it to negotiate the SA. Note, this tunnel has nothing to do with the data tunnel that will be used eventually to exchange IPSec packets. More specifically, the IKE procedure in split into two phases. In Phase 1, the two peers establish a secure channel over which configuration data can be safely exchanged. In Phase 2, the IPSec SA is actually negotiated.
The first operation of Phase 1 is the authentication of the remote peer. As noted above, encryption without proper authentication can be extremely dangerous. Different authentication mechanisms can be employed, ranging from shared secret keys (manually configured) to public key cryptography. In the latter case, key exchange is based on the Diffie-Hellman algorithm reinforced with the usage of public key signatures.
Today’s modular x86 servers are compute-centric, designed as a least common denominator to support a wide range of IT workloads. Those generic, virtualized IT workloads have much different resource optimization requirements than hyperscale and cloud applications. They have resulted in a “one size fits all” enterprise IT architecture that is not optimized for a specific set of IT workloads, and especially not emerging hyperscale workloads, such as web applications, big data, and object storage. In this report, you will learn how shifting the focus from traditional compute-centric IT architectures to an innovative disaggregated fabric-based architecture can optimize and scale your data center.
Sponsored by AMD
Built-in forensics, incident response, and security with Red Hat Enterprise Linux 6
Every security policy provides guidance and requirements for ensuring adequate protection of information and data, as well as high-level technical and administrative security requirements for a system in a given environment. Traditionally, providing security for a system focuses on the confidentiality of the information on it. However, protecting the data integrity and system and data availability is just as important. For example, when processing United States intelligence information, there are three attributes that require protection: confidentiality, integrity, and availability.
Learn more about catching the bad guy in this free white paper.
Sponsored by DLT Solutions
| Making Linux and Android Get Along (It's Not as Hard as It Sounds) | May 16, 2013 |
| Drupal Is a Framework: Why Everyone Needs to Understand This | May 15, 2013 |
| Home, My Backup Data Center | May 13, 2013 |
| Non-Linux FOSS: Seashore | May 10, 2013 |
| Trying to Tame the Tablet | May 08, 2013 |
| Dart: a New Web Programming Experience | May 07, 2013 |
- RSS Feeds
- New Products
- Making Linux and Android Get Along (It's Not as Hard as It Sounds)
- Drupal Is a Framework: Why Everyone Needs to Understand This
- A Topic for Discussion - Open Source Feature-Richness?
- Home, My Backup Data Center
- New Products
- Paranoid Penguin - Building a Secure Squid Web Proxy, Part IV
- Trying to Tame the Tablet
- Developer Poll
- Looking Good
1 hour 18 min ago - Hey God - You may not be
5 hours 32 min ago - Reply to comment | Linux Journal
8 hours 5 min ago - Drupal is an Awesome CMS and a Crappy development framework
12 hours 44 min ago - IT industry leaders
15 hours 6 min ago - Reply to comment | Linux Journal
1 day 7 hours ago - Reply to comment | Linux Journal
1 day 10 hours ago - Reply to comment | Linux Journal
1 day 11 hours ago - great post
1 day 12 hours ago - Google Docs
1 day 12 hours ago
Free Webinar: Linux Backup and Recovery
Most companies incorporate backup procedures for critical data, which can be restored quickly if a loss occurs. However, fewer companies are prepared for catastrophic system failures, in which they lose all data, the entire operating system, applications, settings, patches and more, reducing their system(s) to “bare metal.” After all, before data can be restored to a system, there must be a system to restore it to.
In this one hour webinar, learn how to enhance your existing backup strategies for better disaster recovery preparedness using Storix System Backup Administrator (SBAdmin), a highly flexible bare-metal recovery solution for UNIX and Linux systems.



Comments
Securing my LAN.
I want to secure my LAN from internal attacks. I primarily want to prevent an external notebook PC from being brought in by an employee and be configured to work on the LAN.
I have certain IP based rules for access and deny of resources. If an external device joins my LAN it could assume any IP and gain access to the otherwise denied resource.
One way I see is to put passphrase on every PC. The other is the use of IKE on the LAN. Can a unauthorized machine be prevented from getting a key via IKE?
Re: The IP Security Protocol, Part 2
As a reference performance note, FreeS/Wan (Linux IPSec implementation) plus AES patches
can almost saturate (95%) a 100Mbps link with a P4 1GHz.