IPsec Configuration - Win32 apps (2024)

  • Article

Windows Filtering Platform (WFP) is the underlying platform for Windows Firewall with Advanced Security. WFP is used to configure network filtering rules, which include rules that govern securing network traffic with IPsec. Application developers may configure IPsec directly using the WFP API, in order to take advantage of a more granular network traffic filtering model than the model exposed through the Microsoft Management Console (MMC) snap-in for Windows Firewall with Advanced Security.

What is IPsec

Internet Protocol Security (IPsec) is a set of security protocols used to transfer IP packets confidentially across the Internet. IPsec was formerly mandatory for all IPv6 implementations (but see IPv6 Node Requirements; and optional for IPv4.

Secured IP traffic has two optional IPsec headers, which identify the types of cryptographic protection applied to the IP packet and include information for decoding the protected packet.

The Encapsulating Security Payload (ESP) header is used for privacy and protection against malicious modification by performing authentication and optional encryption. It can be used for traffic that traverses Network Address Translation (NAT) routers.

The Authentication Header (AH) is used only for protection against malicious modification by performing authentication. It cannot be used for traffic that traverses NAT routers.

For more information on IPsec, see also:

IPsec Technical Reference

What is IKE

Internet Key Exchange (IKE) is a key exchange protocol that is part of the IPsec protocol set. IKE is used while setting up a secure connection and accomplishes the safe exchange of secret keys and other protection-related parameters without the intervention of the user.

For more information on IKE, see also:

Internet Key Exchange

What is AuthIP

Authenticated Internet Protocol (AuthIP) is a new key exchange protocol that expands IKE as follows.

While IKE only supports computer authentication credentials, AuthIP also supports:
  • User credentials: NTLM, Kerberos, certificates.
  • Network Access Protection (NAP) health certificates.
  • Anonymous credential, used for optional authentication.
  • Combination of credentials; for example, a combination of machine and user Kerberos credentials.

AuthIP has an authentication-retry mechanism that verifies all configured authentication methods before failing the connection.
AuthIP can be used with secure sockets to implement application-based IPsec secured traffic. It provides:

  • Per-socket authentication and encryption. See WSASetSocketSecurity for more information.
  • Client impersonation. (IPsec impersonates the security context under which the socket is created.)
  • Inbound and outbound peer name validation. See WSASetSocketPeerTargetName for more information.

What is an IPsec Policy

An IPsec policy is a set of rules that determine which type of IP traffic needs to be secured using IPsec and how to secure that traffic. Only one IPsec policy is active on a computer at one time.

To learn more about implementing IPsec policies, open the Local Security Policy MMC snap-in (secpol.msc), press F1 to display the Help, and then select Creating and Using IPsec Policies from the table of contents.

For more information on IPsec policies, see also:

Overview of IPsec Policy Concepts
Description of an IPsec Policy

How to Use WFP to Configure IPsec Policies

The Microsoft implementation of IPsec uses Windows Filtering Platform to setup IPsec policies. IPsec policies are implemented by adding filters at various WFP layers as follows.

  • At the FWPM_LAYER_IKEEXT_V{4|6} layers add filters that specify the negotiation policies used by the keying modules (IKE/AuthIP) during Main Mode (MM) exchanges. Authentication methods and cryptographic algorithms are specified at these layers.

  • At the FWPM_LAYER_IPSEC_V{4|6} layers add filters that specify the negotiation policies used by the keying modules during Quick Mode (QM) and Extended Mode (EM) exchanges. IPsec headers (AH/ESP) and cryptographic algorithms are specified at these layers.

    A negotiation policy is specified as a policy provider context associated with the filter. The keying module enumerates the policy provider contexts based on the traffic characteristics and obtains the policy to use for the security negotiation.

    Note

    The WFP API can be used to specify the Security Associations (SAs) directly and therefore to ignore the keying module negotiation policy.

  • At the FWPM_LAYER_INBOUND_TRANSPORT_V{4|6} and FWPM_LAYER_OUTBOUND_TRANSPORT_V{4|6} layers add filters that invoke callouts and determine which traffic flow should be secured.

  • At the FWPM_LAYER_ALE_AUTH_RECV_ACCEPT_V{4|6} layers add filters that implement identity filtering and per-application policy.

The following diagram illustrates the interaction of the various WFP components, with respect to IPsec operation.IPsec Configuration - Win32 apps (1)

Once IPsec is configured, it integrates with WFP and extends the WFP filtering capabilities by providing information to be used as filtering conditions at the Application Layer Enforcement (ALE) authorization layers. For example, IPsec provides the remote user and remote machine identity, which WFP exposes at the ALE connect and accept authorization layers. This information can be used for fine-grained remote identity authorization by a WFP-based firewall implementation.

Below is a sample isolation policy that may be implemented using IPsec:

  • FWPM_LAYER_IKEEXT_V{4|6} layers – Kerberos authentication.
  • FWPM_LAYER_IPSEC_V{4|6} layers – AH/SHA-1.
  • FWPM_LAYER_INBOUND_TRANSPORT_V{4|6} and FWPM_LAYER_OUTBOUND_TRANSPORT_V{4|6} layers - negotiation discovery for all network traffic.
  • FWPM_LAYER_ALE_AUTH_RECV_ACCEPT_V{4|6} layers - IPsec required for all network traffic.

WFP Layers

Filtering Layer Identifiers

ALE Layers

IPsec Policy Scenarios Implemented using WFP API:

Transport Mode

Negotiation Discovery Transport Mode

Negotiation Discovery Transport Mode in Boundary Mode

Tunnel Mode

Guaranteed Encryption

Remote Identity Authorization

Manual IPsec SAs

IKE/AuthIP Exemptions

IPsec Solutions:

Server and Domain Isolation

As an expert in network security and Windows Filtering Platform (WFP), I have hands-on experience and an in-depth understanding of the concepts mentioned in the article regarding Windows Firewall with Advanced Security and its underlying technology, the Windows Filtering Platform (WFP). My expertise extends to IPsec (Internet Protocol Security), IKE (Internet Key Exchange), AuthIP (Authenticated Internet Protocol), and the configuration of IPsec policies using WFP.

IPsec is a vital set of security protocols used for secure data transfer across the Internet. It employs the Encapsulating Security Payload (ESP) header for encryption and the Authentication Header (AH) for authentication. Understanding the differences between these headers and their applicability in various network scenarios, including NAT traversal, is essential for implementing secure communication.

IKE, a part of the IPsec protocol suite, facilitates secure key exchange, ensuring secure connections without user intervention. It's crucial for setting up secure connections and exchanging keys and related parameters securely.

AuthIP, an extension of IKE, broadens authentication capabilities beyond computer credentials to include user credentials, NAP health certificates, anonymous credentials, and combinations of credentials. It offers enhanced authentication mechanisms and is compatible with secure sockets, allowing per-socket authentication, encryption, and inbound/outbound peer name validation.

IPsec policies, which determine the types of IP traffic to be secured and how to secure it, are created and managed using the Local Security Policy MMC snap-in or programmatically through the WFP API. These policies consist of rules dictating the security measures to be applied to various network traffic types.

The integration of IPsec with WFP enhances filtering capabilities by providing additional information at the Application Layer Enforcement (ALE) authorization layers. This integration enables fine-grained remote identity authorization and allows for the implementation of isolation policies to secure network traffic at different layers using WFP API filters.

The WFP API is utilized to configure IPsec policies by adding filters at different WFP layers, such as FWPM_LAYER_IKEEXT, FWPM_LAYER_IPSEC, FWPM_LAYER_INBOUND_TRANSPORT, FWPM_LAYER_OUTBOUND_TRANSPORT, and FWPM_LAYER_ALE_AUTH_RECV_ACCEPT. These filters define negotiation policies, traffic flow, identity filtering, and per-application policies, crucial for enforcing security measures at various network levels.

In summary, the integration of IPsec with WFP via the mentioned layers and APIs allows for comprehensive security measures, including encryption, authentication, isolation policies, and fine-grained authorization, thereby ensuring robust protection for network traffic in various scenarios, such as server and domain isolation.

IPsec Configuration - Win32 apps (2024)

FAQs

How to configure IPsec in Windows? ›

Configure Internet Protocol Security (IPSEC)
  1. Select Actions > Properties. ...
  2. Select IPsec Settings > Customize. ...
  3. Under Key exchange (Main Mode), select Advanced > Customize. ...
  4. Select Add. ...
  5. Select the algorithms that you want to use for each purpose. ...
  6. Move the security method that you have added to the top of the list.

What is IPsec configuration? ›

IPSec is a set of communication rules or protocols for setting up secure connections over a network. Internet Protocol (IP) is the common standard that determines how data travels over the internet. IPSec adds encryption and authentication to make the protocol more secure.

Which Windows tools can be used to configure IPsec? ›

Windows Filtering Platform (WFP) is the underlying platform for Windows Firewall with Advanced Security. WFP is used to configure network filtering rules, which include rules that govern securing network traffic with IPsec.

How do I configure IPsec policy on a local computer? ›

Navigate to Computer Settings > Windows Settings > Security Settings > IP Security Policies on Active Directory. You can now manually configure the IPSec Policy. See Block Ping Traffic with IPSec for examples.

How to configure IPsec VPN step by step? ›

Step-by-Step Procedure
  1. Specify a name for the SA. ...
  2. Specify the mode of the manual SA. ...
  3. Configure the direction of the manual SA. ...
  4. Configure the IPsec protocol to use. ...
  5. Configure the value of the SPI. ...
  6. Configure the authentication algorithm and key. ...
  7. Configure the encryption algorithm and key.

How to check if IPsec is enabled? ›

To view status information about active IPsec tunnels, use the show ipsec tunnel command. This command prints status output for all IPsec tunnels, and it also supports printing tunnel information individually by providing the tunnel ID.

Is IPsec the same as VPN? ›

Many VPNs use the IPsec protocol suite to establish and run these encrypted connections. However, not all VPNs use IPsec. Another protocol for VPNs is SSL/TLS, which operates at a different layer in the OSI model than IPsec. (The OSI model is an abstract representation of the processes that make the Internet work.)

Which mode of IPsec should you use? ›

1. Which mode of IPsec should you use to assure the security and confidentiality of data within the same LAN? Explanation: ESP transport mode should be used to ensure the integrity and confidentiality of data that is exchanged within the same LAN.

Should I disable IPsec? ›

Without IPsec Passthrough enabled, your traffic will be blocked if firewall restrictions are in place. This is not an issue if you have a modern router, but it can be an issue if you have an outdated router.

What are the 3 main protocols that IPSec uses? ›

The three main protocols comprising IPsec are: Authentication Header (AH), Encapsulating Security Payload (ESP), and Internet Key Exchange (IKE).

Where does IPSec run? ›

The IPsec protocol suite operates at the network layer of the OSI model. It runs directly on top of IP (the Internet Protocol), which is responsible for routing data packets. Meanwhile, SSL operates at the application layer of the OSI model.

Which VPN protocol is best for IPSec? ›

Protocols Comparison
VPN ProtocolSpeedStability
IPSec/IKEv2Very GoodExcellent
WireGuard*ExcellentVery Good
SSTPFairFair
L2TP/IPSecFairGood
2 more rows

Where in Windows can you configure IPsec? ›

Setting up the Windows 10 machine

On the Windows 10 machine, open Network and Internet Settings. Choose VPN from the left panel and add a VPN connection. Edit the advanced options. Place the IP address of your VPN server under server name or address.

What are the requirements for IPsec configuration? ›

All IPsec VPN configurations require at least two items: (1) the Internet Security Association and Key Management Protocol (ISAKMP) or Internet Key Exchange (IKE) policy; and (2) the IPsec policy. These policies determine how an IPsec tunnel will negotiate phase 1 and phase 2 respectively when establishing the tunnel.

How do I connect to IPsec? ›

How to Set Up an IPsec VPN Client
  1. Right-click on the wireless/network icon in your system tray.
  2. Select Open Network and Sharing Center. ...
  3. Click Set up a new connection or network.
  4. Select Connect to a workplace and click Next.
  5. Click Use my Internet connection (VPN).
  6. Enter Your VPN Server IP in the Internet address field.
Aug 26, 2021

How to configure VPN server in Windows? ›

Set Up VPN on Windows 10
  1. Click the Windows Start button and select the Settings cog.
  2. Under Windows Settings, select Network & Internet.​​
  3. Select VPN from the left menu, then at the right, click Add a VPN connection.
  4. In the dialog box that opens:
  5. Set VPN provider to "Windows (built-in)".

How to configure SSL VPN in Windows? ›

Create a VPN profile
  1. Select Start > Settings > Network & internet > VPN > Add VPN.
  2. Under Add a VPN connection, do the following: For VPN provider, choose Windows (built-in). In the Connection name box, enter a name you'll recognize (for example, My Personal VPN). ...
  3. Select Save.

How do I allow IPsec through my Firewall? ›

To set up an IPSec session, the firewall needs to allow UDP protocol on specifically defined IANA port 500 for IKE (Internet Key exchange) and port 4500 for encrypted packets. ESP and AH are also protocols that are designated with IANA standardized numbers 50 and 51, respectively.

How to setup IKEv2 VPN on Windows? ›

How to set up IKEv2 VPN connection on Windows 10
  1. On the VPN tab, click Add VPN Connection.
  2. In the Subscriptions section, look for domains of IKEv2 VPN servers, as well as the Username and Password VPN.
  3. Choose: Windows (Built-in) ...
  4. Connect to IKEv2 VPN server on Windows 10.
  5. Connection to IKEv2 VPN established successfully.

Top Articles
Patterns And Powers Of 10 (Definition, Types and Examples) - BYJUS
How long does it take for an appeal to be decided by the Court? - NCDOJ
Food King El Paso Ads
Amc Near My Location
Enrique Espinosa Melendez Obituary
Tabc On The Fly Final Exam Answers
Stadium Seats Near Me
Poe Pohx Profile
Nordstrom Rack Glendale Photos
Cvs Devoted Catalog
Culver's Flavor Of The Day Monroe
FIX: Spacebar, Enter, or Backspace Not Working
Love Compatibility Test / Calculator by Horoscope | MyAstrology
WWE-Heldin Nikki A.S.H. verzückt Fans und Kollegen
How to Store Boiled Sweets
Images of CGC-graded Comic Books Now Available Using the CGC Certification Verification Tool
Roster Resource Orioles
Where Is George The Pet Collector
Mc Donald's Bruck - Fast-Food-Restaurant
Espn Horse Racing Results
Between Friends Comic Strip Today
Military life insurance and survivor benefits | USAGov
Yosemite Sam Hood Ornament
Valic Eremit
Craig Woolard Net Worth
10 Best Places to Go and Things to Know for a Trip to the Hickory M...
WPoS's Content - Page 34
Winterset Rants And Raves
Funky Town Gore Cartel Video
Loopnet Properties For Sale
In Branch Chase Atm Near Me
Newcardapply Com 21961
Best Workers Compensation Lawyer Hill & Moin
Ewwwww Gif
Jewish Federation Of Greater Rochester
Daily Times-Advocate from Escondido, California
888-822-3743
Subdomain Finder
Coffee County Tag Office Douglas Ga
Martha's Vineyard – Travel guide at Wikivoyage
BCLJ July 19 2019 HTML Shawn Day Andrea Day Butler Pa Divorce
Port Huron Newspaper
How to Connect Jabra Earbuds to an iPhone | Decortweaks
Bonecrusher Upgrade Rs3
tampa bay farm & garden - by owner "horses" - craigslist
Wvu Workday
Tyrone Unblocked Games Bitlife
Appsanywhere Mst
Fahrpläne, Preise und Anbieter von Bookaway
Ippa 番号
Wayward Carbuncle Location
Latest Posts
Article information

Author: Greg O'Connell

Last Updated:

Views: 6577

Rating: 4.1 / 5 (42 voted)

Reviews: 81% of readers found this page helpful

Author information

Name: Greg O'Connell

Birthday: 1992-01-10

Address: Suite 517 2436 Jefferey Pass, Shanitaside, UT 27519

Phone: +2614651609714

Job: Education Developer

Hobby: Cooking, Gambling, Pottery, Shooting, Baseball, Singing, Snowboarding

Introduction: My name is Greg O'Connell, I am a delightful, colorful, talented, kind, lively, modern, tender person who loves writing and wants to share my knowledge and understanding with you.