Active Directory in Networks Segment by FireWalls

zhaozj2021-02-12  144

Introduction

Early adoption of the Active Directory? Service demonstrated customer interest in deploying it in environments in which the domain controllers and domain members are separated by one or more firewalls. This paper describes how to configure the domain controllers and firewalls to enable Active Directory functionality in these Scenarios; IT Describes The Functionality That IS UNVAILABLE IN Such Scenarios; And It Identifies Security Considerations in Each Scenario. This Paper Considers The Three Most Common Scenarios:

.

· Two Forests Deployed ON Opposite Sides of a Firewall-One In The Perime NetWork and ONE INENANAL NETWORK WITH INE INE DOMAINS.

· A Single Forest Is Deployed in An Internal Network With Different Portions of the Forest Separated by FireWall (s).

The scenarios and recommendations in this paper apply to systems using Microsoft? Windows? 2000. Information about additional scenarios or features included with Microsoft? Windows Server? 2003 will be provided in a future paper. Appendix A includes detailed procedures for using IPSec to secure traffic between domain controllers through the firewall. The procedures described in Appendix A can be used in a Windows Server 2003 environment. However, in a Windows Server 2003 environment, there might be small differences in the procedures required to create the IPSec policy.

Operational Building Blocks

. Each network scenario can be broken down into a set of operations that a particular client is trying to achieve These operations are the building blocks for other network scenarios This section describes each operation individually;. You can use these descriptions to create customized scenarios that are NOT COVERED IN THISPER. for a list of commonly used ports referened in the following operations, see appendix c.user login and authentication

A User Network Logon Across A FireWall Uses The Following:

· Microsoft-DS Traffic (445 / TCP, 445 / UDP)

· Kerberos Authentication Protocol (88 / TCP, 88 / UDP)

· Lightweight Directory Access Protocol (LDAP) Ping (389 / UDP)

· Domain Name System (DNS) (53 / TCP, 53 / UDP)

Computer Login and Authentication

A Computer Logon to a Domain Controller Uses The Following:

· Microsoft-DS Traffic (445 / TCP, 445 / UDP)

· Kerberos Authentication Protocol (88 / TCP, 88 / UDP)

· LDAP PING (389 / UDP)

· DNS (53 / TCP, 53 / UDP)

Establishing an expected trust between Domains

When Establishing a trust Between Domain Controllers in Different Domains, The Domain Controllers Communicate with each other by means of the following:

· Microsoft-DS Traffic (445 / TCP, 445 / UDP)

· LDAP (389 / TCP) OR 636 / TCP if Using Secure Sockets Layer (SSL))

· LDAP PING (389 / UDP)

· Kerberos Authentication Protocol (88 / TCP, 88 / UDP)

· DNS (53 / TCP, 53 / UDP)

Validating and authenticating a trust

Trust Validation Between Two Domain Controllers in Different Domains Uses the Following:

· Microsoft-DS Traffic (445 / TCP, 445 / UDP)

· LDAP (389 / TCP OR 636 / TCP if Using SSL)

· LDAP PING (389 / UDP)

· Kerberos (88 / TCP, 88 / UDP) · DNS (53 / TCP, 53 / UDP)

· Net logon service

Because the Net Logon service can not be locked down to a single RPC port, the RPC endpoint mapper (135 / tcp and 135 / udp) needs to be open, as does a small range of dynamic RPC ports for the mapper to use. For information About How to Limit The Range of Dynamic RPC Ports, See Appendix E.

Access file resource

File Access Uses SMB over IP (445 / TCP, 445 / UDP).

Perform A DNS Lookup

TO Perform A DNS Lookup Across A FireWall Ports 53 / TCP and 53 / UDP Must Be open. DNS IS Used for Name Resolution and supports Other Services Such as The Domain Controller Locator.

Perform Active Directory Replication

The Type of Network Traffic That Is Required for Replication IS BETWEEN DOMAIN Controllers of One or More Domains. Both Types of Replication Require The Following:

· Directory Service RPC Traffic (Configurable Directory Service RPC Port)

· LDAP (389 / TCP OR 636 / TCP if Using SSL)

· LDAP PING (389 / UDP)

· Kerberos (88 / TCP, 88 / UDP)

· DNS (53 / TCP, 53 / UDP)

· SMB over ip traffic (445 / TCP, 445 / UDP)

Replication within a domain also requires File Replication service (FRS) using a dynamic RPC port. Replication traffic and configuration is further described in "Domain Controller Replication Across a Firewall" later in this paper. For instructions for configuring a static directory service RPC port, See Appendix D. for The Procedure to Limit The Range of Dynamic RPC Ports, See Appendix E.

Common Scenarios

The following section describes the most common customer scenarios in which Active Directory domain controllers and domain members are separated by one or more firewalls. Each scenario requires special configuration of the firewall to enable computers to authenticate (and authenticate to) other resources residing on the other side of the firewall, including one that requires enabling Active Directory replication across the firewall This section makes appropriate recommendations regarding domain controller and firewall configurations, depending on whether Active Directory replication needs to be enabled.The following represent some common examples;. other, more complex scenarios can be supported by identifying the appropriate operations as described in Operational Building Blocks and configuring the firewalls to allow propagation of network traffic as required by the identified operations.

Member Servers Separated from A Domain Controller

The following scenario has firewalls separating one or more member servers from one or more domain controllers. A common example of this scenario is a Web application server or a member server that is running Microsoft? Exchange Server and resides in the perimeter network accessing data from an INTERNAL RESOURCE, SUCH AS A File Share for Scripts, And Authenticating to A Domain Controller Wtem.

To enable a server located in the perimeter network to access data from an internal resource (such as a Global Catalog) open ports on the firewall and create point-to-point IP restrictions so that only specific computers are allowed to communicate across the firewall.

Open ports that are required by applications that you are using. For example, to enable Microsoft? Exchange 2000 Server to retrieve data from the Global Catalog, open port 3268. You need to obtain the exact list of ports required from your application vendors. For A List of other commonly used ports, See appendix c.open the folowing ports for authentication traffic:

· Kerberos ports (88 / tcp, 88 / udp) used to perform mutual authentication between the member server and the domain controller. Kerberos traffic needs to be allowed in addition to the possible application specific traffic.

· DNS Ports (53 / TCP, 53 / UDP) Used for name lookups.

· LDAP Ports (389 / UDP, 389 / TCP OR 636 / TCP for SSL) Used for Locator Pings.

· Microsoft-DS Traffic (445 / TCP, 445 / UDP).

Deploying Domain Controllers in a Perimeter Network

Your forest determines the security boundary. Having a separate forest in the perimeter network is more secure than creating a forest that exists in both external and internal networks. This general rule applies to any scenario in which networks have different levels of security. If you need to enable users from the internal network to access resources in the perimeter network and the reverse, establish explicit trust between the domains. in this scenario, you can have one or more domains that have established trust with domains whose domain controllers are separated by a firewall .

To enable internal users and resources residing in the perimeter network to have access to each other open the following ports on the firewall and create point-to-point IP restrictions so that only the specific domain controllers can communicate across the firewall. Use the User and Computer Authentication and Trust Validation operational building blocks described above to determine the type of traffic that needs to pass through the firewall and the ports that need to be opened. · Port (s) used by specific applications if needed. You need to obtain the exact List of ports there.

· Kerberos (88 / TCP, 88UDP)

· LDAP (389 / UDP, 389 / TCP And / OR 636 / TCP IF Using LDAP over SSL)

· SMB over ip traffic (445 / TCP, 445 / UDP)

· DNS Ports (53 / TCP, 53 / UDP) Used for Name Lookups

If creating a separate forest for the perimeter network zone is not possible, and you are planning to deploy domain controllers of the same forest in the perimeter network and in the internal network, then replication between domain controllers needs to occur, and the appropriate configuration needs TO BE DONE. For Details, See Domain Controller Replication Across A Firewall Later in this document.

Deploying Active Directory in An Internal Network Containing FireWalls

Although IS Not Common, There Area The Internet Separation by FireWalls, ALE..

The Following Diagram Represents a Scenario in Which:

· A Domain Member Computer (m1) IS Separated from The Domain Controller (M2) for ITS Domain (DOM 1) BY A Firewall (FireWall 1 and FireWall 2).

· A User is Separated from A Domain Controller (m3) for ITS Domain (DOM2) BY A Firewall (FireWall 1 and FireWall 3). · The user accesses a resource on a Member Computer (m4) of another domain (DOM3) That IS LOCATED IN A Portion of Network That Is Separated from the user by firewalls (firewall 1, firewall 4, and wirewall 5).

............................. ...

Deploying Active Directory in such networks requires additional configuration of the domain controllers and the firewalls to enable user and resource authentication and Active Directory replication across the firewalls. This scenario uses many of the operational building blocks described in Operational Building Blocks earlier in this paper.

For this scenario, open the required ports for Kerberos, LDAP, DNS, and SMB over IP. Depending upon which applications need to communicate across the firewalls, other ports might be required. You need to obtain the exact list of ports that need to be Open from the application vendors. for a list of the corresponding ports, see appendix c.

Additional configuration that is required to enable Active Directory replication is described in the following section. If your design requires that users and computers be authenticated only by local domain controllers (that is, domain controllers within the same site), and that domain controller administration is performed only from local computers (that is, computers within the same site), you need only to configure domain controller replication across the firewall, instead of opening the ports described in the previous section. For more information about configuring domain controller replication in this scenario , see Domain Controller Replication Across a Firewall later in this paper.This scenario can also be broken down into smaller scenarios. The following illustrations show how you can use the operational building blocks described in Operational Building Blocks to construct complex scenarios.

The Computer and User Login Scenario Uses The User and Computer Authentication Operational Building Blocks and Requires That The Following Ports Be open:

· Kerberos (88 / TCP, 88UDP)

· LDAP (389 / UDP, 389 / TCP And / OR 636 / TCP IF Using LDAP over SSL)

· SMB over ip traffic (445 / TCP, 445 / UDP)

· DNS Ports (53 / TCP, 53 / UDP) Used for Name Lookups

The File and Resource Access Scenario Uses The User and Computer Authentication Operational Building Blocks and Requires That The Following Ports Be open:

· Kerberos (88 / TCP, 88UDP)

· LDAP (389 / UDP, 389 / TCP And / OR 636 / TCP IF Using LDAP over SSL)

· SMB over ip traffic (445 / TCP, 445 / UDP)

· DNS Ports (53 / TCP, 53 / UDP) Used for Name Lookups

While opening these ports will allow these protocols through the firewall, user IDs, user password hashes and application data will be exposed in some of these protocols. Security concerns may require all traffic to be encrypted as it flows through the firewalls between the different subnets. Typically, a virtual private network (VPN) tunnel is implemented to secure traffic between firewalls. Windows 2000 Server Routing and Remote Access Service provides both VPN capabilities for site-to-site (also known as gateway-to-gateway) tunnels. However, if a VPN were not available, then an IPSec policy on each computer can enforce and automatically negotiate IPSec transport mode security for traffic between subnets using domain-based Kerberos trust. This could secure all server-to-server, client-to-client and Client-to-Server Traffic, But Should Not Be Used To Secure Client-To-Domain Controller Traffic, or Domain Controller To Domain Controller Traffic. for more information, see appendix a and article 254949, "Client-to-Domain Controller and Domain Controller-to-Domain Controller IPSec Support," in the Microsoft Knowledge Base, at http://go.microsoft.com/fwlink/?LinkId=16462.Domain Controller Replication Across a firewall

.

Inter-Domain Domain Controller Replication Across A FireWall

For replication between domain controllers that reside in separate domains and are separated by a firewall, encapsulate domain controller-to-domain controller traffic within IPSec and open the firewall for IPSec traffic. The IPSec filter rules should be set up to further limit the ports allowed within. for IPSec setup instructions, see Appendix A and Appendix B (for a sample script). for a list of commonly used ports, see Appendix C. for registry key modification information required to set a single port for directory service replication use, see appendix D.This solution provides a more secure communication channel between domain controllers while opening only a small defined set of ports on the firewall. It provides optimal firewall security as well as the ability to set up IPSec policies on each server. In addition, the Authentication Header (AH) VARIATION OF IPSec Can Be Used to Monitor The Encapsulated Traffic. This Variation of IPSec is Described in appendix a. Alth IPsec Need .

Intra-Domain Domain Controller Replication Across A FireWall

For Active Directory replication within a domain that has domain controllers separated by a firewall, encapsulate domain controller-to-domain controller traffic within IPSec and open the firewall for IPSec traffic. For IPSec setup instructions, see Appendix A.

This solution provides a more secure communication channel between domain controllers while opening a small defined set of ports on the firewall. It provides the highest level of firewall security, as well as the ability to set up IPSec policies on each server. Although IPSec needs to be configured on each domain controller, by using Group Policy, you can apply the IPSec configuration to an organizational unit object that contains a set of domain controllers In this scenario dynamic RPC port allocation needs to occur to allow traffic across domain controllers;. RPC port Allocation Also Prevents Specific Port Filters from Being Added in The IPsec Policy.note

For more information about security considerations for using Active Directory in perimeter networks, see Chapter 5, "Security Design," in the Reference Architecture Guide: Internet Data Center, at http://go.microsoft.com/fwlink/?LinkId=16468 And Chapter 8, "Directory Services," in The Reference Architecture Guide: Enterprise Data Center, at http://go.microsoft.com/fwlink/?LinkId=16463.

Appendix A: configuring and managing ipsec policies to secure traffic betWeen Domain Controllers

This appendix uses an example Internet Protocol security (IPSec) policy configuration to describe the recommended configuration for using IPSec in transport mode to secure all traffic (not just Active Directory replication traffic) between domain controllers that are on opposite sides of a firewall. Step- BY-Step Procedures for configuring an appropriate ipsec policy

You can use IPSec to secure all traffic between domain controllers in separate forests, between two domain controllers in the same domain (for example, to secure site-to-site replication traffic), between domain controllers in parent and child domains, and in other scenarios, as described earlier in this paper. For a detailed example of an IPSec policy configuration that you can use to secure traffic between two domain controllers in separate forests, see Deploying Domain Controllers in a Perimeter Network earlier in this white paper (this appendix uses this example to describe a recommended configuration for using IPSec. for more information, see Creating an IPSec Policy to Encrypt Traffic Between Two Domain Controllers later in this appendix). You can configure similar IPSec policies as needed for other scenarios. However, it is not Currently Recommended That You Use IPsec to Secure Communication Between Domain Members (Either Clients Or Servers) and their Domain Controllers. When Do main members use IPSec-secured communication with domain controllers, increased latency might occur, and complex IPSec policy configuration and management is required. For more information, see article 254949, "Client-to-Domain Controller and Domain Controller-to-Domain Controller IPSec Support, "in the microsoft knowledge", at http://go.microsoft.com/fwlink/?Linkid=16462.important

The example IPSec policy configuration described in this appendix secures traffic only between domain controllers that are on opposite sides of a firewall. Do not use these examples to enable IPSec-secured communication between domain members that are on opposite sides of a firewall.

Notes

The example IPSec policy configuration described in this appendix is ​​based on a Windows 2000 Service Pack 3 or later environment. You can use the same IPSec policy configuration in a pure Windows Server 2003 environment or in a mixed-platform environment. However, note that there might be differences in the steps used to manage the Windows Server 2003 IPSec policy.Portions of IPSec and related services for Windows 2000, Windows XP, and Windows Server 2003 were jointly developed by Microsoft and Cisco Systems, Inc.

Using The Example IPsec Policy Configuration Described in this appendix provides the folloading business benefits:

· IPSec allows you to configure security policies to meet the security requirements of a user, group, application, domain, site, or global organization. IPSec is integrated at the IP layer, so applications that use TCP / IP pass data to the IP layer , where it can be transparently secured by IPSec. in this way, IPSec provides security against vulnerabilities in upper-layer protocols and applications. for example, you can enhance security by using IPSec as a first layer of defense for the server message block (SMB ) file-sharing protocol that is used extensively for replication and other file transfer functions. Two identified SMB security issues were found in Windows 2000 and in Windows XP. Although supported fixes for the Windows 2000 and Windows XP issues are now available from Microsoft, you CAN enhance security by using ipsec as a first layer of defense for smb or ivout the two of the two odentified smb security Vulnerabilities and supported fixes for Windows 2000 and Windows XP, see articles 329170, "MS02-070: Flaw in SMB Signing May Permit Group Policy to Be Modified," and 326830, "MS02-045: Unchecked Buffer in Network Share Provider May Lead to Denial-of-Service "In the Microsoft Knowledge Base, at http://go.microsoft.com/fwlink/?Linkid=16462.

· IPSec provides host-based authentication and encryption for all traffic between domain controllers to ensure that the administrative owner of the data retains full control of the data. The identity information in Active Directory constitutes the core of the data security inside the organization, so even if business and legal trust relationships that manage the trust of the network path are not enforced perfectly or are silently compromised, the IPSec-secured communications remain secured. · IPSec allows for simple and secure firewall traversal. Firewalls interpret the many protocols that are used in communications between domain controllers as only IPSec Encapsulating Security Payload (ESP) (protocol 50) traffic or as Authentication Header (AH) (protocol 51) traffic. Firewalls permit traffic only for these protocols [and Internet Security Association and Key Management Protocol (ISAKMP) Traffic], And these Protocols are inherently second against attics.

· IPSec, with the Triple Data Encryption Standard (3DES) encryption algorithm and Secure Hash Algorithm 1 (SHA1) integrity algorithm, meets the requirement of many government, military, financial, and health care institutions that Common Criteria and FIPS 140-1-certified algorithms be used to secure their traffic. The algorithm used to encrypt traffic over most Windows protocols [for example, remote procedure call (RPC), Kerberos, and Lightweight Directory Access Protocol (LDAP)] is the RC4 stream cipher, which is not certified Under Common Criteria OR FIPS 140-1.

· As a software-based Windows solution, IPSec is more cost-effective for securing host-to-host communications than a hardware-based solution, such as purchasing and operating a virtual private network (VPN) or a private leased line. · If you use IPSec offload adapters, IPSec provides lower CPU utilization than using protocol-specific security measures, such as SMB signing, provides because offload adapters accelerate the cryptographic operations that are used to secure IPSec packets, therefore minimizing the performance costs for encryption. As a Result, IPsec-Secured TCP / IP Connections Can Achieve The Same Throughput AS TCP / IP Connections That Are Not Ipsec-Secured.

Note

If you can not use IPSec offload network adapters, then IPSec encryption increases the CPU load on a domain controller. Accordingly, you might need to add more CPU capacity, depending on the available CPU and the amount of network traffic. Thorough testing is required to evaluate the performance impact of IPSec on domain controllers. For more information about the benefits of using IPSec hardware offload adapters, see IPSec Offload Performance and Comparison, at http://go.microsoft.com/fwlink/?LinkId=16469.

Although IPSec can greatly enhance security, be aware that deploying IPSec on your network requires additional training and administrative costs, and, if you need to purchase IPSec hardware offload network adapters or increase CPU capacity, it can increase hardware costs. Therefore, before deploying IPSec for any specific scenario, carefully consider and document the potential security threats that IPSec is intended to address, your security requirements, the costs of deploying IPSec, and the expected business benefits.

Creating an IPSec Policy to Encrypt Traffic Between Two Domain ControllersWhen you design an IPSec policy to secure all traffic between domain controllers that are on opposite sides of a firewall, make sure that you have the following information available:

· A Diagram of Inter-Domain and intra-domain Communication Paths That Shows The Location of Each Firewall and Any Network Address Translators, IF Network Address Translators Are USEDs.

· The Static IP Addresses of Each Domain Controller On Either Side of the FireWall (s).

In Addition, Before you create an ipsec policy: Decide the folload:

· WHETHER You want to use ipsec to encrypt Traffic to Provide Confidentiality Or To Provide Only Data Origin Authentication and Data Integrity.

· WHETHER You CAN ISSUE A Computer Certificate To Each Domain Controller That Uses IPSec (Recommended).

This appendix uses the example IPSec policy configuration that is introduced in Deploying Domain Controllers in a Perimeter Network to demonstrate how to create an IPSec policy to encrypt traffic between two domain controllers, SEA-PN-DC-01 and SEA-NA-DC-01 That The the the Domain Controllers Are In Two Forests That Are Deployed ON OPPOSITE SIDES OF A FIRED. SEA-PN-DC-01 IS IN A Perimeter Network, And SEA-NA-NA-NA-DC-01 IS IN An InnAl Network. AN IP address is specified for each of these two domain controllers. To allow for communication across forest trusts between these two domain controllers, you can configure one external trust (if trust is needed in only one direction) or two external trusts, one for each direction .

This figure is based in part on the network architecture that is documented in Windows 2000 Resource Kit Deployment Lab Scenarios. For more information, see Deployment Lab Scenarios, at http://go.microsoft.com/fwlink/?LinkId=504.To create an IPSec policy for this example, deactivate the default response rule, and define only one rule to protect traffic between the specific IP addresses of the two domain controllers. The following table summarizes the IPSec rule that must be defined.

Source Address

Destination Address

Protocol

Source Port

Destination Port

Action

CERTIFICATION Authority (CA)

Name of rule / notes

172.16.40.5

172.16.8.5

Any

N / a

N / a

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

SEA-PN-DC-01 <-> SEA-NA-DC-01, ALL

172.16.8.5

172.16.40.5

Any

N / a

N / a

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirror (Automatically Generated)

Add a filter that specifies that all of the traffic that is sent between the IP addresses of the two domain controllers, including Kerberos, RPC, Domain Name System (DNS), LDAP, and Internet Control Message Protocol (ICMP), be IPSec-secured . If the Mirrored check box is selected in filter Properties when you specify the filter in a filter list, then you need to define a filter for only one direction (for clarity, the rule that is defined in the previous table includes two one-way Filters).

WHEN You Define An Ipsec Policy With this filter, IT IS important to consider the Following:

· If you use the Ping.exe command-line tool to verify connectivity between the two domain controllers, then Ping.exe triggers an Internet Key Exchange (IKE) negotiation. As a result, the output reports "Negotiating IP Security," even if An IPsec Security Association (SA) Does Not Exist, And The Ping Command Fails. If An Ipsec SA EXISTS, or if An Ipsc Policy Is Not Assigned, The Ping Command Should Succeed.

· If you use IPSec to protect ICMP traffic between domain controllers (as is recommended in this appendix), then you can use the ping command, which sends ICMP Echo Request messages to verify network connectivity, however, tools such as Tracert (which depend on the processing of ICMP traffic by routers) might not work. Tracert sends ICMP Echo Request messages with incrementally increasing Time to Live (TTL) values ​​to determine the path taken to a destination. If IPSec protects ICMP traffic, then the Tracert output can not show the correct path between the domain controllers because the ICMP packets are in IPSec format. in this case, the output shows only the destination computer, not the path of intermediate routers. However, if you use Tracert to determine the path taken from one domain controller to A Destination Other Than THE Remote Domain Controller ed by IPSec. To enable Tracert to show the routers in the path between two domain controllers, create a second rule in the IPSec policy with a filter to permit ICMP traffic between the two IP addresses of the two domain controllers, and make sure that any firewalls or other devices are configured to permit this traffic. Because IPSec does not protect ping ICMP Echo Request messages, you must use a TCP or UDP-based service to verify IPSec-secured connectivity. · If the path between the IP addresses of the two Domain Controllers Has A Network Address Translator, THE NetWork Address Translator Cannot Work Because The Windows 2000 Implementation of IPsec Doses Not Allow Network Address Translators to Modify IPsec Packets.

· If you determine that IPSec is necessary to secure domain controller communications, then it is strongly recommended that you use the IPSec policy configuration described in this appendix. Specific IPSec policy configuration options, such as excluding only ICMP traffic, using subnet filters, using IPSec without encryption, and adding a filter to block traffic on specific ports, are described in this appendix, within the context of the overall recommended configuration. It is not recommended that you configure a customized IPSec policy with many filters to negotiate security for traffic on each protocol and port, due to the complexity of policy configuration, management, and troubleshooting required. Such a configuration can also increase costs and result in decreased performance. It is recommended that you keep your IPSec policy configuration as simple as possible.Procedures for Defining an IPsec Policy To Encrypt Traffic Between Two Domain Controllers

To Define An Ipsec Policy To Encrypt Traffic Between Two Domain Controllers, Perform The Following Procedures:

1.configure fireswalls to permit ESP, Isakmp, And Ah Traffic.

2.Remove The Default Filtering Exemption for Kerberos and Resource Reservation Protocol (RSVP) Traffic.

3.Create a filter list, Andadd a filter.

4.create a filter action.

5.create an ipsec policy, and add a rule to the policy.

6.ssign the ipsec policy.

Configuring firewalls to permit ESP, ISAKMP (IKE), And Ah Traffic

When a firewall exists between IPSec peers, as it does in the example, you must configure the firewall to forward IPSec traffic on UDP source and destination port 500, IP protocol 50 (ESP), or IP protocol 51 (AH). First, to permit IPSec traffic on UDP source and destination port 500, use the following settings to create a firewall filter called Permit ISAKMP traffic on UDP port 500: · Source address = Specific_IP_address of domain controller

· Destination Address = specific_ip_address of Domain Controller

Protocol = UDP

· Source port = 500

· Destination port = 500

To Permit IPsec Traffic ON IP Protocol 50 (ESP) OR IP Protocol 51 (AH), Use The Following Settings To Create A FireWall Filter Called Permit Ipsec Traffic On Esp or Ah Protocol (50 OR 51):

· Source Address = Specific_IP_Address of Domain Controller

· Destination Address = specific_ip_address of Domain Controller

Protocol = 50 or 51

In Addition, When You Configure The FireWall, Do The Following:

Configure the firewall to permit Traffic Between Only The Specific IP Addresses of the Two Domain Controllers (in The Example, 172.16.40.5 and 172.16.8.5).

· Configure the firewall filter to permit or track fragments for ESP, ISAKMP, and AH traffic. In Windows 2000 releases through Service Pack 4 and in Windows XP and Windows XP Service Pack 1, IKE message fragmentation is required when certificate authentication is used. Also MANY UDP Applications Do Not Attempt To Avoid Fragmentation, and Therefore The Udp Traffic IS Fragmented When IPsec Protects IT.

· Allow IKE and IPSec communications to flow statically in both directions between the IP addresses of the domain controllers. Do not configure the firewall to perform stateful filtering on UDP source and destination port 500 (ISAKMP), IP protocol 50 (ESP), or IP Protocol 51 (AH). · IF Communication Requires TCP Path Maximum Transmission UNIT (MTU) Discovery, Configure the Firewall To Permit ICMP Destination Unreachable Messages.

Note

If a non-Microsoft firewall or other network device is performing network address translation on the traffic between the domain controllers, then you can not use Windows 2000 IPSec to secure traffic end-to-end between the domain controllers. In addition, you can not use Windows 2000 IPSec to secure traffic end-to-end between the domain controllers if a computer running Microsoft Internet Security and Acceleration (ISA) Server is used as a firewall between domain controllers, because ISA Server always performs network address translation on traffic that passes through it . For more information, see article 329807, "INFO: ISA Server Does Not Support Domain Members in Perimeter Network," article 254949, "Client-to-Domain Controller and Domain Controller-to-Domain Controller IPSec Support," in the Microsoft Knowledge Base, at http://go.microsoft.com/fwlink/?Linkid=16462.

Removing the default filtering exemption for Kerberos and rsvp Traffic

After you configure the firewall to permit ESP, ISAKMP, and AH traffic, you must remove the default filtering exemption for Kerberos and RSVP traffic to ensure that IPSec can secure these traffic types. By default, in Windows 2000 and Windows XP, broadcast, multicast , Kerberos, RSVP, and ISAKMP traffic is exempt from IPSec filtering, even if you define a filter to match all IP traffic between the IP addresses of the two domain controllers. to secure Kerberos and RSVP traffic between the IP addresses of the two domain controllers You Must Remove This Default filtering exemption by modifying the registry.caution

INCORRECTLY DAMAGES To The Registry, You Should Back Up Any Valued Data on The Computer. 0000-00-00. BEFORE MAKING OFFER.

To Remove The Default Filtering Exemption for Kerberos and Rsvp Traffic

1.under hkey_local_machine / system / currentControlset / Services / IPsec, Add A New DWORD Entry Named NodefaultExempt.

2.ssign this entry a value of 1. This Specifies That Kerberos and RSVP Traffic Are Not Exempt from IPsec Filtering (Multicast, Broadcast, and isakmp Traffic Are EXEMPT).

3.Restart the ipsec service.

Important

In Windows Server 2003 IPsec, IT IS Not Necessary To Set this Registry Key Because The Default Filtering Exemptions for Kerberos and RSVP Traffic Have Been Removed.

For more information, see article 254728, "IPSec Does Not Secure Kerberos Traffic Between Domain Controllers," and article 811832, "IPSec Default Exemptions Can Be Used to Bypass IPsec Protection in Some Scenarios," in the Microsoft Knowledge Base. To find these article See the Microsoft Knowledge Base, at http://go.microsoft.com/fwlink/?LinkId=16462.

Creating a filter List and add a filter

After you remove the default filtering exemption for Kerberos and RSVP traffic, create a filter list, and then add a filter to this list to define the traffic to secure between the two domain controllers. This procedure creates a filter list and adds a filter to the List, using the ip address, SEA-NA-DC-01 and SEA-PN-DC-01, AS An Example.to Create A Filter List and Add A Filter

1.on a Domain Controller, Click Start, Point To Programs, Point To Administrative Tools, and the Click Domain Controller Security Policy.

The Microsoft Management Console (MMC) window that opens displays the default domain controller Group Policy object (GPO) that is associated with the domain controller's organizational unit (OU) in Active Directory.

2.in The Console Tree, Click Windows Settings, Click Security Settings, And The Click IP Security Policies.

Note

If you change the filter settings or any other settings for an existing Active Directory-based IPSec policy that is assigned to a domain controller, or if you assign a new Active Directory-based IPSec policy to a domain controller, make sure to carefully coordinate these .. changes Although the IPSec policy in this example is shown as part of the security settings for this GPO, the GPO contains only a reference to the IPSec policy Group Policy detects changes only in IPSec policy assignments; it does not detect changes within an IPSec policy after it is assigned to a GPO. The IPSec service detects changes in the related IPSec policy. The differences between Group Policy and IPSec service polling intervals can result in incompatible policies if changes in policy settings or assignments are not carefully coordinated. For more information , SEE CONSIDERATIONS for Updating Active Directory-based IPsec Policy, Later in this appendix.3.right-click The details Pane, Click Manage IP Filter Lists And Filter Actions, AND THEN, IN Manage IP Filter Lists and Filter Actions, Click Add.

4. IP Filter List, Type a name and description for the filter list, and then click add.

5.on The IP Filter Wizard Welcome Page, Click Next.

6.in IP Traffic Source, Click A Specific IP Address, Type 172.16.40.5, and the Click Next.

7.in IP Traffic Destination, Click A Specific IP Address, Type 172.16.8.5, and the Click Next.

8. IP Protocol Type, Click Any (or Click A Specific Protocol, And, IF You Click TCP OR UDP, Specify A Port Number), and the Click Next.

9.on The IP Filter Wizard Completion Page, Click Finish, And The Click Close.

After You Create The Filter, IT APPEARS As Follows:

The Filter List Displays One Mirrored Filter, Which Appears As Follows: Note

The screenshot shows an optional description (SEA-PN-DC-01 <-> SEA-NA-DC-01, all) in the Description column in the properties for the filter However, you can not add this description by using the IP Filter. Wizard. to add a description for a filter, in filter Properties, click the Description tab, and, in Description, type an abbreviated description. Although such descriptions are not required, it is recommended that you specify them to aid in troubleshooting.

Creating Filters to Secure Traffic Between Additional Domain Controller IP Addresses

You can create additional filters in the same filter list to secure traffic between the specific IP addresses of other domain controller pairs. If you do so, all filters in the filter list use the action that is associated with the filter list in the rule.

IF There Two Domain Controller IP Addresses in Each Domain, Add A Filter List That Contains Four Mirrored Filters, AS Shown In The Following Table. When You Do So, Eight One-Way Filters Are generated.

Mirrored

Source Address

Destination Address

Protocol

Source Port / Destination Port

Name / Comment

YES

SEA-PN-DC-01

SEA-NA-DC-01

Any

N / a

SEA-PN-DC-01 <-> SEA-NA-DC-01, ALL

YES

SEA-PN-DC-01

SEA-NA-DC-02

Any

N / a

SIMILAR

YES

SEA-PN-DC-02

SEA-NA-DC-01

Any

N / a

SIMILAR

YES

SEA-PN-DC-02

SEA-NA-DC-02

Any

N / a

SIMILAR

This IPSec policy can be assigned to every domain controller in both forests (the perimeter network and the internal network). The policy takes effect only when a domain controller in either forest sends or receives packets that match the addresses in the filters.

Note that these filters are not defined to use My IP Address as a source or destination address The four mirrored filters are defined to use explicit IP addresses for source and destination addresses, instead of My IP Address, for the following reasons:. · When you want IPSec to secure communication between only one domain controller in each forest, using explicit IP addresses in the IPSec policy allows the policy to be assigned to all of the computers in the domain controller's OU. Although the IPSec policy is enforced in this case, it Do Not Affect Computers That Do Not Have ONE of the Specified IP Addresses.

· If you use IPSec to secure traffic between domain controllers in the same domain, then specifying My IP Address might cause IPSec to secure communication on internal paths between domain controllers that you do not want secured. For example, if you set up the perimeter network domain as a remote site for the internal domain, do not assign an IPSec policy to domain controllers in the perimeter network domain that includes only the My IP Address filter shown in the table below. If you specify this filter in an IPSec policy that is assigned to domain controllers in the internal network, then each domain controller in the internal network attempts to negotiate security with SEA-PN-DC-01. Although this behavior might be intended, if you use the same filter in an IPSec policy that is assigned to Domain Controllers In The Perimeter Network Domain, THEN Each Domain Controller Requires Ipsec WHEN Communicating with SEA-PN-DC-01 INTERNALLY, WITHIN THE Perimeting Using IPsec to Secure Communication Between All Domain Controllers In A Site, Use Static IP Addreses for Each Domain Controller In The Site.

· If you do not explicitly specify the IP address of each domain controller in the IPSec filter list, then communication to one domain controller might fail. For example, if the My IP Address filter is the only filter in the IPSec policy that is assigned to all domain controllers in the perimeter network domain, then communication is blocked between SEA-PN-DC-01 and other domain controllers in the same domain because SEA-PN-DC-01 interprets the My IP Address filter as requiring IPSec communication to its own IP address and ignores the filter. Because SEA-PN-DC-01 does not have other filters that allow it to negotiate security with the specific IP addresses of other domain controllers, it attempts to send unsecured traffic to the other domain controllers. The other domain controllers, which require IPSec communication, drop the unsecured packets that SEA-PN-DC-01 sends, and communication fails. Likewise, SEA-PN-DC-01 ignores security negotiation requests from other domain contro llers because it does not have an IPSec policy that allows it to respond to requests to negotiate security with the IP addresses of the other domain controllers. · Using explicit IP addresses for the source or destination address for a domain controller that uses more than one network adapter (which is often the case) or a domain controller that has more than one IP address assigned on a single network adapter, prevents IPSec from generating filters for each IP address on the computer, which might cause more filters to be created than necessary, INCREASING CPU Utilization.

However, IT Can Be Appropriate To Define A Filter To Use My IP Address, AS Shown In The Following Table:

Mirrored

Source Address

Destination Address

Protocolsource Port / Destination Port

Name / Comment

YES

My IP Address

SEA-PN-DC-01

Any

N / a

Any DC <-> SEA-NA-DC-01, ALL

Use the my ip address filter for the Following Conditions:

· When the IPSec policy is designed uniquely for each site (for example, when you want to secure all traffic from any internal domain controller to a specific domain controller in the perimeter network). You can add the My IP Address filter to the IPSec policy For The Domain Controllers In The Internal Network Subnet, Rather Than Creating A Filter for Each Domain Controller IP Address Pair.

· When you want to secure all internal traffic between many domain controllers, all domain controllers to use the same IPSec policy, and the number of IPSec filters that are required for the policy to be minimized. For example, if you have a domain with 100 domain controllers and you do not use the My IP Address filter, you need to specify a filter for each pair of domain controller IP addresses In this case, 4,950 mirrored filters would be required. [(100 x 100) - 100] / 2. Because any domain controller could communicate with a maximum of only 99 other domain controllers in the same domain, most of these filters would not be needed. If you use My IP address as a source address, in the same scenario, then you need only 100 Filters to Specify The Destination IP Address Of Each Domain Controller.

Creating filters to secure traffic between subnet

If there are many domain controllers in either domain, then the number of IP address combinations can be complex to manage. In such cases, consider creating filters to secure traffic between subnets. However, keep in mind that if you create filters to secure traffic between subnets, rather than between specific IP addresses, then communication between the domain controller in the source subnet and member computers in the destination subnet might be blocked, if the member computers in the destination subnet do not also have an appropriate IPSec policy and mutual authentication method for IKE to successfully negotiate security.For the example described in this appendix, to secure traffic between the subnet for the perimeter network (which contains SEA-PN-DC-01) and the internal network (which contains SEA-NA-DC-01 ), Define the Following Filter List:

Mirrored

Source Address

Destination Address

Protocol

Source Port / Destination Port

Name / Comment

YES

172.16.40.0/255.255.252.0

172.16.8.0/255.255.252.0

Any

N / a

SEA-PN-DC SUBNET <-> SEA-NA-DC SUBNET, ALL

When a filter like this applies to the domain controllers, the domain controllers negotiate security for any packet that is sent with a matching source and destination IP address. If the IP addresses of the domain controllers are closely grouped within a smaller subnet range, then you can use a smaller subnet in the source or destination address. For example, if the domain controller IP addresses in the perimeter network subnet range from 172.16.40.2 through 172.16.40.8, then you can use a subnet definition of 172.16.40.0/255.255. 255.248 (172.16.40 / 29).

If you use subnet filters, keep in mind that IPSec-secured packets must be small enough to fit through the smallest link of the network path between the domain controllers. The maximum packet size supported for any link on a network path is known as the maximum transmission unit (MTU). The smallest MTU supported for all links on the network path is known as the path MTU (PMTU). Through the process of PTMU discovery, if a packet exceeds the MTU for any link along the network path, then the router sends an ICMP Destination Unreachable packet to the source address of the TCP packet, to indicate that the packet can not be forwarded unless it is fragmented. When the message is received, TCP adjusts its MTU for the connection so that any packets sent on the connection are no larger than the MTU.The Windows implementation of IPSec is integrated with TCP so that TCP automatically reduces the TCP packet size when IPSec must add additional bytes to the packet for AH or ESP headers. As a result, I PSec-secured TCP packets are sized according to the MTU allowed by the outbound network adapter. A router or VPN gateway in the network path might still require a smaller packet, however, and therefore PTMU discovery must function correctly so that the MTU of the packet Can Be determined. for PTMU Discovery To Function Correctly, You Must Add Filters To Your IPsec Policy To Permit Inbound ICMP Destination Unreachable Messages from Routers or Other Gateways.

When IPSec filters are used to specify the IP addresses of individual domain controllers, inbound ICMP Destination Unreachable messages are not blocked. However, if you use the subnet filter that is specified in the preceding table on SEA-NA-DC-01 to require IPSec for any traffic to the perimeter network subnet, then an ICMP Destination Unreachable message from a router with an IP address of 172.16.40.1 is dropped. As a result, PTMU discovery does not function correctly and TCP communication to SEA-PN-DC-01 might be delayed or fail every time a packet that exceeds the PMTU is sent.To ensure that PMTU discovery functions correctly when you use larger subnet filters, add the following one-way filter to the IPSec policy that is assigned to SEA-NA-DC -01. This Filter Permits Inbound ICMP Destination Unreachable Messages from The Entire Perimeter NetWork Subnet, 172.16.40.0.

Source Address

Destination Address

Protocol

Source Port

Destination Port

Action

CERTIFICATION Authority (CA)

Name of rule / notes

172.16.40.0/255.255.252.0

My IP Address

ICMP

N / a

N / a

Permit

N / a

Allow PMTU

If you can add a more specific filter to require IPSec communication between domain controllers (for example, if you use the smaller subnet range of 172.16.40.0/255.255.255.248), then you might not need to use the filter in the preceding table to permit inbound ICMP traffic. Alternatively, if you can not specify a smaller subnet range for the filter, and only a few routers need to send ICMP Destination Unreachable messages, then add a filter that uses the specific IP address of the router as the source address for ICMP traffic.

Note that the ICMP filter in this example is not mirrored so that outbound ICMP packets used by the ping command will trigger an IKE negotiation and be protected by IPSec. The ping command allows different sizes of ICMP packets to be sent and forces routers to send ICMP . Destination Unreachable messages when required To determine the maximum size of an IPSec packet, run the following ping command on SEA-NA-DC-01, after you assign IPSec policy on both domain controllers and verify that IPSec SAs are established: ping -f -L 172.16.40.5

.

If firewalls are configured to block inbound ICMP traffic to the domain controller that is sending IPSec-secured TCP traffic, or if the inbound ICMP traffic to the domain controller is blocked for other reasons, then consider configuring the network adapter on the domain controller to send smaller TCP packets, or configure TCP / IP to detect when large packets are being dropped and to automatically attempt to reduce the size of the packet. However, because these two configuration options might cause delays in all other TCP / IP communications with the domain controller YOULD IMPLEMENT THESE OPTIONS ONLY You Cannot Add An Ipsec Filter To Allow Inbound ICMP Messages on The Domain Controller That Is Sending IPsec-Secured TCP Traffic.

When you design the IPSec policy for SEA-PN-DC-01, if you plan to use subnet filters, consider whether inbound ICMP traffic must be permitted to SEA-PN-DC-01 because IPSec-secured TCP packets that sent from are the perimeter network to the internal network might also exceed the PMTU. for more information about PMTU discovery and how to configure TCP / IP and network adapters to use different methods for reducing MTU, see the "Path Maximum Transmission Unit (PMTU) Discovery" section and the EnablePMTUBHDetect and MTU registry key descriptions in Microsoft Windows 2000 TCP / IP Implementation Details, at http://go.microsoft.com/fwlink/?LinkId=16467.Creating filters to secure traffic between IP addresses and subnets

If you create filters to secure traffic between a combination of IP addresses and subnets, make sure that both sides of the communication use exactly the same filter definition For example, the following filter list corresponds to the example.:

Mirrored

Source Address

Destination Address

Protocol

Source Port / Destination Port

Name / Comment

YES

172.16.40.0/255.255.255.0

172.16.8.5

Any

N / a

SEA-PN-DC SUBNET <-> SEA-NA-DC 01, ALL

When you use this filter for an IPSec policy that is assigned to all domain controllers in the perimeter network (SEA-PN-DC) and in the internal network (SEA-NA-DC) subnet, only one domain controller in the internal network ( SEA-NA-DC-01) will initiate a security negotiation with any of the domain controllers in the perimeter network subnet, because only SEA-NA-DC-01 has an IP address that matches this filter. If there is a second domain controller in the internal network (SEA-NA-DC-02) with an IP address of 172.16.8.6, traffic between that domain controller and any of the domain controllers in the perimeter network subnet is not matched against the filter, because SEA-NA- DC-02 has a different IP address. Therefore, SEA-NA-DC-02 does not initiate a security negotiation when attempting to communicate to any domain controller in the perimeter network subnet, and communication fails. Likewise, the domain controllers in the perimeter Network Subnet Will Always Initiate A Security Negotiati on with SEA-NA-DC-01 but not with any other domain controller IP address in the internal network subnet. Communication should fail in these cases because the firewall should be configured to block all unsecured communication between domain controllers.

If you use two IPSec policies with filters that do not match, the policies can not work together. For example, if you use one IPSec policy for all domain controllers in the perimeter network subnet with a filter that matches all traffic from that subnet and the specific IP Address of SEA-NA-DC-01 and YOU USE A SECOND IPSEC Policy With A Different Filter for SEA-NA-DC-01 That Matches Traffic BetWeen The Specific IP Addresses of Sea-NA-DC-01 and SEA-PN -DC-01, these two policies can not work together, and in some cases, the security negotiation might fail. When any domain controller in the perimeter network subnet initiates a security negotiation first to SEA-NA-DC-01, the negotiation fails because SEA-NA-DC-01 is not configured to accept a subnet as a source address. However, if SEA-NA-DC-01 initiates a security negotiation first to any domain controller in the perimeter network subnet, the negotiation succeeds because the filter That SEA-NA-DC-01 Uses Is More Specific THEN The Filter USE D by The Domain Controllers in The Perimeter Network Subnet.enabling and disable network adapters

A Windows 2000 IPSec policy with filters that match traffic between specific IP addresses is enforced when the IPSec service starts and detects that the specified IP addresses are already configured on the network adapter. If the network adapter is disabled during computer startup or when the IPSec service is started, and if the network adapter is configured to use an IP address that is specified in the policy, then you must restart the IPSec service after re-enabling the network adapter, or the IPSec policy is not enforced. If the network adapter is enabled when the IPSec service is started and then disabled and re-enabled while the IPSec service is still running, then the IPSec policy is still enforced. If you use a filter with a source address of My IP address in the IPSec policy, then Windows 2000 Automatic Or Creates The Appropriate IPsec Policy WHEN You Add A Network Adapter or An IP Address To The Computer. Windows Server 2003, However, CAN Automatical Create The Appropriate IPsec Policy WHEN You Use an ipsec policy with filters That Match Traffic Between Specific IP Addreses, and the network adapter is disabled durning computer startup.creating a filter action

After you create a filter list and add filters to define the traffic that IPSec is to secure, create a filter action to specify how IPSec is to secure traffic between the domain controllers. This procedure defines how traffic between SEA-NA-DC-01 and SEA-PN-DC-01 IS To Be Secured, as an example.

TO CREATE A FILTER Action

1.create a console containing ip security policies. OR, Open A Saved Console File Containing IP Security Policies.

2.Right-click the details pane, click Manage IP filter lists and filter actions, click the Manage Filter Actions tab, and then, in Manage IP filter lists and filter actions, click Add.3.On the Filter Action Wizard welcome page, Click next.

4. In Filter Action Name, Type a name and description for the filter action, and then click next.

5. In Filter Action General Options, Click Negotiate Security, And The Click Next.

6.in Communicating With Computers That Do Not Support IPsec, Click Do Not Communicate With Computers That Do Not Support IPsec, and the Click Next.

7.in IP Traffic Security, Click The Security Method That You Want To Use.

The IPsec Policy Described in The Example In this appendix uses ESP with 3DES Encryption. To configure ipsec to use esp with 3des Encryption, Click Custom, And The Click Settings.

Notes

If you select High rather than Custom, IPSec also uses ESP. However, 56-bit DES encryption is used by default, rather than 3DES encryption. If 3DES encryption is available in your locale, it is recommended that you use this stronger level of encryption , rather than DES encryption. Computers running Windows 2000 must have the High Encryption Pack or Service Pack 2 (or later) installed in order to use 3DES. If a computer running Windows 2000 is assigned a policy that uses 3DES encryption, but does not have the High Encryption Pack or Service Pack 2 (or later) installed, the security method defaults to the weaker DES algorithm. to ensure at least some level of privacy for communication, make sure to allow DES as a fallback option whenever a 3DES setting is applied to a group of computers, in case some of them can not support 3DES. For more information, see Windows 2000 High Encryption Pack, at http://go.microsoft.com/fwlink/?LinkId=7272.You can use IPSec AH encapsulation , Rather Than ESP E Ncryption, if you do not need to encrypt all traffib, or if you are trouplanooting ipsec. To use ah, click medium.

8.To continue to configure IPSec to use ESP with 3DES encryption, in Custom Security Method Settings, select the Data integrity and encryption (ESP) check box. Under Integrity algorithm, click SHA1, under Encryption algorithm, click 3DES, and then click OK .

Note

YOULD NOT NEED TO Modify The Default Session Key Settings. There Defaults Are Used If You Do Not Configure Other Values.

9. IN IP Traffic Security, Click Next.

10.on The Filter Action Wizard Completion Page, Select The Edit Properties Check Box, And The Click Finish.

11.in The Filter Action Properties Dialog Box, Clear The Accept UnSecured Communication, But Always Respond Using IPsec Check Box, and The Click Ok.notes

When you define the Negotiate security filter action so that unsecured communication is not accepted (by verifying that the Accept unsecured communication, but always respond using IPSec and Allow unsecured communication with non-IPSec aware computer check boxes are cleared), the security negotiation fails if IKE does not receive a response from the destination computer. However, if you have two domain controllers in the same domain that must replicate IPSec policy settings, or if you are not assigning an active IPSec policy to all domain controllers simultaneously, select the Allow unsecured communication with non-IPSec-aware computers check box during the rollout phase, so that communication is not blocked after some of the domain controllers start using IPSec policy. After all of the domain controllers receive the appropriate IPSec policy and are successfully using IPSec, you CAN clear this check box.

For maximum-security environments, when you must protect highly sensitive data for long periods of time, select the Session key Perfect Forward Secrecy check box. If you select this check box, make sure that it is selected in the IPSec policy that is assigned to .

12.IN Manage IP Filter Lists and filter actions, click close.

Creating an ipsec policy and add a rule to the policy

After creating the filter list and filter actions that you want to use for your IPSec policy, you must create the policy and add a rule to combine the filter list with the filter actions. This procedure creates a policy to secure traffic between SEA-NA- DC-01 and SEA-PN-DC-01 and adds the rule as specified in the previous section, as an example.to create an ipsec policy and address a rule to the policy

1.create a console containing ip security policies. OR, Open A Saved Console File Containing IP Security Policies.

2.Right-Click The Details Pane, And The Click Create IP Security Policy.

3.on The IP Security Policy Wizard Welcome Page, Click Next.

4. IN IP Security Policy Name, Type a name and a description for the policy, and then click next.

5. In Requests for Secure Communication, Clear The Activate The Default Response Rule Check Box, and the Click Next.

6.on The IP Security Policy Wizard Completion Page, Verify That The Edit Properties Check Box is SELECTED, AND THEN CLICK FINISH.

7.on the rules tab, to add a new rule to this policy, click add.

8.on The Security Rule Wizard Welcome Page, Click Next.

9. In Tunnel Endpoint, Click this rule does not Specify A Tunnel, and the Click Next.

10. In Network Type, Click All Network Connections, and the Click Next.

11.in Authentication Method, Choose An Authentication Method to Use.

To use certificate authentication (Recommended. For more information about certificate authentication and other authentication considerations, see "Considerations for Selecting an Authentication Method," after this procedure), click Use a certificate from this Certificate Authority (CA), click Browse to choose the CA, AND THEN Complete Steps 11A and 11b.

Note

For certificate authentication to be successful, the computer must have a certificate in the computer store that chains to this root CA. The Microsoft Root Authority CA is shown as an example.a. In Select Certificate, select the trusted root CA that you want to Use, and then click OK.

b. in Authentication Method, The Name of The SELECTED ROOT CA IS DISPLAYED. CLICK NEXT.

12.IN IP Filter List, Click The Filter List That You Created Earlier (SEA PN-DC-01 <-> SEA-NA-DC-01 All Traffic), and then Click Next.

13. In Filter Action, Click The Filter Action That You Created Earlier (ESP 3DES / SHA1, NO TX / RX CLEAR, NO PFS 20FEB02 ), and then Click Next.

14.on The Security Rule Wizard Completion Page, Click Finish.

15.on the rules Tab, The IPsec Policy Is Displayed As Follows, with the rule this you just added. Click Close To Close The Dialog Box and Return To The IP Security Policy Management Snap-in.

Considances for selecting an automation method

When security is negotiated for the traffic between domain controllers in two separate forests, the forest trust relationship is not used to establish the trust required for IKE authentication. Instead, you must configure an IPSec policy to use either certificate authentication or preshared key authentication. Although IPSec also provides Kerberos as an option for IKE authentication, using Kerberos for IKE authentication between domain controllers is not supported. It is recommended that you use certificate authentication when you configure an IPSec policy to secure traffic between domain controllers. The following list includes additional considerations For Each Authentication Method:

Certificate Authentication

In Windows 2000 Server, you can use Certificate Services to automatically manage computer certificates for IPSec throughout the certificate lifecycle. Certificate Services is integrated with Active Directory and Group Policy, and it simplifies certificate deployment by enabling certificate auto-enrollment and renewal and by providing several default certificate templates that are compatible with IPSec.The choice of a root CA is a very important security decision because IKE must use a certificate or certificate chain from this root CA to authenticate the remote domain controller. IKE authentication does not verify the name or IP address in the certificate, so it can protect only against untrusted attacks against IPSec communication. If a computer with a certificate from this root CA were compromised, an attacker could use that computer to conduct trusted man-in-the-middle attacks on IPSec communication Or to Establish Ipsec-Secured Connectivity from One of the Remote Domain Controller ' s IP addresses. Likewise, if too many computers have certificates from this root CA, a trusted attack might be possible. In this IPSec policy design, any computer that uses the same IP address as the remote domain controller (or that is in the same Subnet As The Remote Domain Controller, IF Subnet Filters Are Used and That Has Obtained A Certificate from this root CA is Trusted for IPsec Communication.

Upper-layer authentication protocols, such as Kerberos and RPC authentication, can provide defense-in-depth against a trusted man-in-the middle attack. Accordingly, many organizations deploy their own CA root, to ensure that only their computers have a certificate that is trusted for IPSec communication. It is recommended that you use a Windows 2000 Server issuing CA to provide certificates for IPSec because the issuing CA is available on all computers running Windows 2000 Server and because it can automatically enroll and update certificates. However, IPSec also supports the use of a variety of non-Microsoft X.509 public key infrastructure (PKI) systems. Windows 2000 IKE is compatible with many certificate systems, including those offered by Microsoft, Entrust, VeriSign, and Netscape. If you are using a Non-Microsoft PKI System, The PKI System Must Be Able To Issue Certificates in The CryptoApi Computer Certificate Store. if you have already D eployed a non-Microsoft PKI system, you can create a Windows 2000 Server issuing CA as a child CA of the non-Microsoft root CA.For information about the use of certificates for IKE negotiation, see Step-by-Step Guide to Internet Protocol Security (ipsec), at http://go.microsoft.com/fwlink/?LinkId=269. For Information About Windows 2000 Certificate Services, See the Step-by-Step Guide To Administering Certificate Services, at http: // GO .microsoft.com / fwlink /? linkid = 326.

· Preshared Key Authentication

If certificates are not available, you can use preshared key authentication instead. To use preshared key authentication, in Authentication Method, click Use this string to protect the key exchange (preshared key).

Preshared key authentication is provided for interoperability purposes and for compliance with RFC standards. However, Microsoft does not recommend the use of preshared key authentication because the key value is not securely stored, and it is therefore difficult to keep secret. The preshared key value is stored in clear text in an IPSec policy. Any member of the local Administrators group can view a local IPSec policy, and such a policy can be read by any system service with local System user rights. Additionally, any authenticated user in the domain can view Active Directory-based IPSec policy. Even if you try to limit access to the IP Security Policies container in Active Directory by denying Read access to this container to members of the Domain Users group and by granting Read access to members of the Domain Computers group, Any Member of The Local Administratrs Group ON A Domain Computer CAN Query Active Directory for Policy Information by Using The Local System Context. Because IPSec policies comprise many Active Directory objects in the IP Security Policies container, setting Read permissions on individual objects in this container is not recommended.For these reasons, use preshared key authentication only for testing and when it is not possible to use certificate authentication in a PRODUCTION ENVIRONMENT.

If you must use preshared key authentication, use only local IPSec policy (not Active Directory-based policy), a 25-character or longer random key value, and a different preshared key value for every IP address pair. These practices result in different security rules for each destination, and ensure that a compromised preshared key compromises only the IKE authentication between the pair of computers that share the key, rather than many IPSec communication paths. · Kerberos authentication

Although you can use Kerberos for IKE authentication between member computers, using Kerberos for IKE authentication between domain controllers is not supported. Because Kerberos requires that traffic be permitted over several dependent network protocols (DNS, ICMP, UDP, and LDAP) in addition to UDP and TCP ports 88, the IPSec policy configuration that is required to enable Kerberos authentication to a domain controller is very complex. Additionally, Kerberos is not available in Windows 2000 Server for authentication across forest trusts.

Accessing and assigning an ipsec policy

After you create an IPSec policy, you must assign it for the policy to take effect. IPSec policies can be assigned to the GPO of a site, domain, or an OU. In addition, each computer has one local GPO, which is also known as The local computer policy.

You can use IP Security Policy Management to create, modify, and store IPSec policies in Active Directory. To activate an IPSec policy, you must use Group Policy Object Editor to assign the IPSec policy to the OU in Active Directory that contains the server. Keep in mind that in an Active Directory domain environment, the IPSec policies that are assigned to a site, domain, or OU override the IPSec policies that are assigned to the local computer. to prevent this from occurring, deny the computer account Read access to the GPO in the Active Directory domain that is delivering the IPSec policy assignment.The following sections describe several different methods for accessing an IPSec policy, depending on whether the IPSec policy is Active-Directory based or local, and then how to assign an IPSec policy.

You CAN Access Active Directory-based IPsec Policy by Doing Any of The Following On The Domain Controller from Which You Want to Manage Policy:

· Start IP Security Policy Management in Domain Controller Security Policy.

· Start IP Security Policy Management from The Domain Controllers OU in Active Directory.

· Add IP Security Policy Management for Active Directory-Based IPsec Policy TO MMC.

You CAN Access Local Ipsec Policy for A Domain Controller by Doing Either of the Following On The Domain Controller for Which You Want To Manage Policy:

· Add IP Security Policy Management for Local IPsec Policy TO MMC.

· Add Group Policy Object Editor for Local IPsec Policy TO MMC.

To Start IP Security Policy Management in Domain Controller Security Policy

1.On the domain controller from which you want to manage IPSec policy, click Start, point to Programs, point to Administrative Tools, and then click Domain Controller Security Policy.The MMC window that opens displays the default domain controller GPO that is associated with The Domain Controller's OU in Active Directory.

2.in The Console Tree, Click Windows Settings, Click Security Settings, And The Click IP Security Policies.

WHEN You Open The Security Policy Settings in Domain Controller Security Policy, The Graphical User Interface (GUI) for IP Security Policies APPEARS AS FOLLOWS:

To Start IP Security Policy Management from The Domain Controllers OU in Active Directory (Group Policy)

The Default GPO That Is Associated with a domain controller is assigned to the domain controllers ou in Active Directory.

1.On the domain controller from which you want to manage policy, click Start, click Control Panel, double-click Administrative Tools, double-click Active Directory Users and Computers, and then navigate to Domain Controllers.

2.IN The Console Tree, Right-Click Domain Controllers, And The Click Properties.

3. In Domain Controllers Properties, Click The Group Policy Tab, Click The GPO That You Want to Edit, And The Click Edit.

The GPO That You Want to Edit (In this Example, The Domain Controller for the Internal Network Domain, Sea-perimeter.com), APPEARS AS FOLLOWS:

To Add IP Security Policy Management for Active Directory-Based IPsec Policy TO MMC

1. Click Start, Click Run, Type MMC, And The Click OK.

2.in MMC, Click Console, Click Add / Remove Snap-in, And The Click Add.

3. Click IP Security Policy Management, and The Click Add.

4.Click Management Domain Policy for this Computer's Domain.

If you access Active Directory-based IPSec policy both by opening Active Directory Users and Computers and adding IP Security Management to this console and by managing domain policies for the local domain or a remote domain, then the GUI appears as follows: Note

To view or modify Active Directory-based policy settings, you must be logged on to the computer with the credentials required to access Active Directory-based IPSec policy on that computer or on remote computers. You can not specify different credentials to accomplish this task.

To Add IP Security Policy Management for a local ipsec policy to mmc

Do One of the Following On The Domain Controller for Which You Want To Manage Policy:

· Add IP Security Policy Management To MMC As a Stand-Alone Snap-in. The Gui Appears As Follows:

Add Group Policy Object Editor To MMC, Choose Local Computer Policy as The GPO, AND THEN Navigate To IP Security Policies On Local Machine. The GUI APPEARS AS FOLLOWS:

To assign an ipsec policy

1.access the ipsec policy by using one of the methods described in this section.

2.IN The Details Pane, Right-Click The Policy That You Just Created (for this Example, SEA-PN Forest Traffic TO SEA-NA Forest, 20FEB03 ), and then Click Assign.

3.in The Console Tree, Right-Click IP Security Policies, And The Click Refresh.

Note

You can not assign an Active Directory-based policy from the IP Security Policies on Active Directory console; you can only configure the policy To assign Active Directory-based policy, you must use Group Policy Object Editor..

Exporting and Importing IPsec Policies

It is often helpful to dedicate one computer to use local IPSec policy. You can export the IPSec policy from this computer to a file, and then import the file into the local IPSec policy store on another computer.To export and import Active Directory-based IPSec policies, start IP Security Policy Management from MMC or access IP Security Policy Management from Group Policy (Active Directory), select the appropriate Active Directory-based IPSec policy, and then follow the procedures in this section.

The Export Policies menu command exports all IPSec policy objects from the policy store into one .ipsec file. Each policy object is internally identified by a globally unique identifier (GUID). You can also use the Export Policies menu command to back up an IPSec policy In The Event That You NEED TO RECOVER The Policy Later.

Importing an IPSec policy file overwrites existing IPSec policy objects that have the same GUID or creates new IPSec policy objects if they do not exist. If you change only the name of an IPSec policy, filter list, or filter action, and then re-import the policy file, then these IPSec policy objects are overwritten with the new names. However, if you select the Delete all existing policy information check box when you select the policy file to import, then all policies, filter actions and filter lists in the target Store Arend File. Note That You Cannot Export or Import A Single IPsec Policy, Filter List, or Filter Action.

Caution

IPsec Policy That Is Already Assigned To A GPO, The IPsec Policy Is Unassigned. You Must Edit The GPO AND REASSIGN The IPSec Policy After The Import is Complete.

Additionally, when importing or editing IPSec policy in Active Directory, do not close IP Security Policy Management before all of the IPSec policy data is written to Active Directory. If IP Security Policy Management can not finish writing all of the policy data into Active Directory, then IPSec policy corruption might result. If you detect IPSec policy corruption, you can try to reimport the IPSec policy file. In some cases, the IPSec policy objects must be deleted so that a new IPSec policy import operation can be successfully completed. you can use either LDP.exe or ADSIedit.exe to delete the IPSec policy objects. LDP.exe is a Windows Support Tool that is included in the Support Tools folder of the Windows 2000 operating system CD. ADSIedit.exe is a Windows Support Tool that uses the Active Directory Service Interfaces (adsi) and this also provides system cd. If you are managing ipsec policy remotly over Slow Links, THEN USE A File Copy Technique To transfer the IPSec policies in .ipsec export files, before you delete the IPSec policy objects. After you transfer the IPSec policies, use the Terminal Services client to connect to the remote server and perform the import operation quickly.To export local IPSec policies

1.create a console containing ip security policies. OR, Open A Saved Console File Containing IP Security Policies.

2.IN The Console Tree, Right-Click IP Security Policies On Local Machine, Point To All Tasks, And The Click Export Policies.

3.IN Save As, Specify WHERE to Save The .ipsec Policy File, and The Click Save.

Note

Make Sure To Properly Name and Secure Access To The File.

To Import Local ipsec Policies from a file

1.Create a console containing IP Security Policies. Or, open a saved console file containing IP Security Policies.2.In the console tree, right-click IP Security Policies on Local Machine, point to All Tasks, and then click Import Policies.

3.in Open, Specify The .ipsec policy file, and then click Open.

Considerations for Updating Active Directory-Based IPsec Policy

When you plan updates to Active Directory-based IPSec policy, make sure that the IP addresses that are used in the IPSec policy are consistent with the IP addresses that are used in the domain. Coordinate IPSec policy updates when you add new domain controllers to the domain so that the communications that the domain controller requires are not blocked. For example, you might need to import a local IPSec policy and certificate on a new domain controller to enable successful IPSec-secured communications when the domain controller first joins the domain, when .

Verify that successful IPSec security associations are established where expected. If Active Directory replication failure events occur, confirm that there are no communication problems first. In the IPSec policy example in this appendix, ICMP traffic is protected by IPSec so that you can use the ping COMMAND to Verify That Ike and IPsec Traffic Is Not Blocked on Any Communication Paths.

Keep in mind that changes to Group Policy assignments and IPSec policy settings might take effect at different times. Group Policy is used only to deliver the IPSec policy assignment to the domain controller's IPSec service. Assigning an IPSec policy to a GPO records the LDAP distinguished name (also known as DN) of the IPSec policy that is inside the GPO attribute ipsecOwnersReference. The IPSec service retrieves the assigned IPSec policy from Active Directory, maintains a current cache of the policy in the local registry of the domain controller, and updates the assigned policy settings by using a polling interval that is specified in the IPSec policy. Therefore, if you change IPSec policy settings on the domain controller, the changes are applied only when the IPSec service on the domain controller polls for changes.

While the IPSec service polls for changes in IPSec policy settings, the Winlogon service polls for changes in policy assignment within GPOs. Because a domain controller might detect changes in the settings of its assigned IPSec policy and changes in IPSec policy assignment within a GPO at different times, make sure that you carefully coordinate IPSec policy changes. If IPSec is used to protect traffic between domain controllers in the same domain, incompatible IPSec policies might cause communication (for example, the sending and receipt of replication traffic) between domain controllers to fail . Therefore, if you plan to either change settings for an existing IPSec policy that is assigned to a domain controller or to assign a new IPSec policy to a domain controller, plan and test these changes to ensure compatibility with the IPSec policy used by other domain Controllers. Consider Creating An Ipsec Policy First and Not Assigning It To a GPO, SO That The Policy Can Be Replicated THROUG hout the domain. After you verify that the policy is replicated throughout the domain, assign the policy to a GPO. This strategy ensures that the IPSec policy exists in the domain before domain controllers receive the GPO assignment.Scripting IPSec Policy

The primary method of creating and managing IPSec policy is by using the IP Security Policy Management console. To script the creation of IPSec policy, you can use Ipsecpol.exe, a command-line tool that is provided with the Windows 2000 Server Resource Kit. However, you can use Ipsecpol.exe only to create an IPSec policy. Ipsecpol.exe is not a full-featured command-line or scripting tool (for example, you can not use Ipsecpol.exe to delete or rename filter lists or filter actions) ., nor is it supported under any Microsoft standard support program or service You can download the latest version of Ipsecpol.exe from Ipsecpol.exe: Internet Protocol Security Policies Tool, at http://go.microsoft.com/fwlink/?LinkId = 16466.An Ipsecpol.exe script is provided in Appendix B as an example that you can use to create an IPSec policy for the perimeter network domain and for the internal network domain controller used as an example in this appendix. for another example of how To use ipsecpol.exe, see a RticLe 813878, "HOW BLOCK SPECIFIC NETWORK Protocols and ports by using ipsec," in the Microsoft Knowledge base, at http://go.microsoft.com/fwlink/?LinkId=16462.

Note

In Windows Server 2003, The Netsh IPsec Command-Line Tool Provides A Full-Featured and Microsoft-Supported Interface. Ipsecpol.exe Does Not Work On Computers Running Windows Server 2003.

IPsec Policy Compatibility Considances

Windows IPSec policies are compatible across the following operating systems: Windows 2000, Windows XP, and Windows Server 2003. For example, you can export IPSec policies that you create by using Ipsecpol.exe from computers running Windows 2000 and then import these policies into Windows Server 2003 Active Directory or local IPSec policy stores on computers running Windows Server XP or Windows 2003. Additionally, you can assign Windows 2000 Active Directory-based policy to computers running Windows 2000, Windows XP, or Windows Server 2003. Any IPSec policies that you create on computers running Windows XP and Windows Server 2003 can be stored in Windows 2000 Active Directory or exported and then imported for use on computers running Windows 2000, if the policies use the basic IPSec features supported by Windows 2000.However, if you plan to Apply ipsec policies That Use any of the new features That Are Available Only in The Windows Server 2003 Implementation of Ipsec, Do Not Assign THE se policies to computers running Windows XP or Windows 2000. Also, do not use the IP Security Policy Management snap-in in Windows 2000 or Windows XP to manage policies that use features that are new for Windows Server 2003. If you use Windows 2000 or Windows XP to Manage Windows Server 2003 Policies, Any New Windows Server 2003 Features Are Lost.

To ensure that the IPSec policy functions consistently and as expected on computers running the Windows Server 2003 family and on computers running Windows XP or Windows 2000, test the policy thoroughly on all relevant operating systems before deployment.

Important

It is recommended that you use a computer running Windows Server 2003 as an IPSec policy management station, due to the enhanced scripting support provided by the Netsh IPSec command-line tool and the availability of IP Security Monitor, which allows you to view filter details and Other Information About The Assigned Ipsec Policy.Performance and Troubleshooting Considerations

The Following Performance and Troubleshooting Considerations CAN Help Simplify The Administration of IPsec Policies.

Using ipsec hardware offload network adapters

. Hardware offload network adapters can accelerate IPSec processing by performing hardware offload of IPSec cryptographic functions For information about the 10/100 MB hardware offload network adapters that are available for Windows 2000 IPSec, see the following:

· The Intel Web Site, At http://go.microsoft.com/fwlink/?Linkid=16474. The Pro 100 S Series of Hardware Offload Adapters Can Be Used for Windows 2000 IPsec Hardware Offload.

· The 3com web site, at http://go.microsoft.com/fwlink/?Linkid=16475. 3COM Network Adapters with 3XP Processors Can Be Used for Windows 2000 IPsec Hardware Offload.

For Information About Additional Network Cards That Are Compatible with Windows 2000, See Search for Compatible Hardware Devices, at http://go.microsoft.com/fwlink/?LinkId=3787.

Viewing IPsec and Other Network Communication With Network Monitor

The Network Monitor component that is provided with Windows 2000 does not include a parser for the IPSec ESP protocol. However, Network Monitor in Windows Server 2003 contains a parser for ESP traffic. The Windows Server 2003 Network Monitor parser can interpret ESP traffic if this traffic is not encrypted or decrypted in software (that is, if encryption or decryption is performed by an IPSec hardware acceleration adapter, or if ESP without encryption is used). Therefore, if you need to use Windows Server 2003 Network Monitor to troubleshoot network traffic flows , change the filter actions in your IPSec policy so that the AH protocol is used for security negotiation, rather than ESP. for ease of configuration, when you create an IPSec policy to secure traffic between two domain controllers, consider configuring AH as the second security Method in the filter action That Used by Both Domain Controllers. That Way, You NEED TO CHANGE ONE ONE DOMAIN Controller Policy Filter Action To AH . If one domain controller is configured to use only AH, and the other domain controller is configured to use only ESP, security negotiation fails.If you plan to switch from using ESP to AH for troubleshooting purposes, remember to ensure that your firewall is configured To Forward Traffic on Protocol 51.

Evaluating Bad SPI Events

Bad SPI events indicate the total number of packets for which the Security Parameters Index (SPI) was incorrect. The IPSec driver records Bad SPI events in the Event Viewer System log when it receives an IPSec-formatted packet that it can not interpret. These events, Which Appear in The System Log As Event 4283: " Packets Discarded Due To Bad SPI," Are USUALLY BENIGN.

You can expect a small number of Bad SPI events per each IPSec peer IP address, due to the way in which IKE processes the transition of IPSec SAs during rekeys. This event is usually logged when an SA has been deleted on one IPSec peer, and the other IPSec peer still sends secure traffic on the deleted SA. This event is also logged when one IPSec peer begins sending IPSec-secured traffic using a new SA that the other peer is not yet ready to receive. These brief periods between rekeys typically do not cause problems for traffic over upper-layer protocols, which can accommodate the loss of a few packets. This number is likely to increase if rekey intervals are short and there are a large number of SAs. Windows Server 2003 IPSec has been enhanced to eliminate packet loss during the periods between rekeys.You can use IP Security Monitor to examine the number of rekeys. If the number of rekeys is very large compared to the amount of time that the connections have been active, consider sett ING The Key Lifetimes in The IPsec Policy to Be.

Note That You Cannot Disable Logging for Bad SPI Events.

Evaluating Events Generated by Automatical Starting Services During Computer Startup

Some services, such as DNS, start automatically on a domain controller and are designed to communicate immediately with other domain controllers during computer startup. When an IPSec policy is assigned to a domain controller, these services might record events in Event Viewer that indicate that the remote domain controller can not be reached. These events are expected during computer startup because the IPSec service starts at the same time as many other automatically starting services. If other services are configured to depend on the IPSec service during computer startup, the IPSec service does not delay these services. IPSec-secured connectivity is established as soon as the IPSec service starts, IPSec policy is applied, and outbound traffic triggers a security negotiation. However, if such events are recorded during normal operation, you might need to troubleshoot IPSec connectivity. Security considances

.

Configuring Domain Controller Baseline Security Option Settings

IPSec does not replace the need to implement additional measures to enhance the security of domain controllers. Such measures play a critical role in defending your network against attacks that use upper-layer protocols and services and attacks mounted from remote domain controllers that are compromised. Keep in mind that IPSec provides a limited defense against attacks from domain controllers that can successfully authenticate and negotiate security. For information about how to enhance the security of domain controllers and other computers, see Chapter 7, "Hardening Specific Server Roles," in Securing Windows 2000 Server, at http://go.microsoft.com/fwlink/?Linkid=15394.combining ipsec policy configurations

In addition to configuring an IPSec policy to negotiate security for traffic between domain controllers, as described in this appendix, you can configure an IPSec policy that uses IPSec blocking filters to enhance the security of domain controllers. For information about defining specific IPSec filters to permit or block traffic to domain members, see Table 7.5, "Domain Controller IPSec Network Traffic Map," in Chapter 7, "Hardening Specific Server Roles," in Securing Windows 2000 Server, at http://go.microsoft.com/fwlink/ ? LinkId = 15394. You can combine IPSec blocking filters with the IPSec policy described in this appendix. To implement both IPSec policies, combine the rules for the two policies into one policy. The IPSec policy in this appendix uses more specific filters than IPSec blocking Filters to Require That Ipsec Negotiate Security For All Traffic Between The Source and Destination IP Addresses of the Two Domain Controllers. Note That The Filters That Negotiate Security Between the specific IP addresses of the two domain controllers, as described in this appendix, will override the more general filters used for domain member traffic described in Table 7.5 of "Securing Windows 2000 Server." Security During Computer Startup

In Windows 2000, the IPSec service does not provide security during computer startup. As a result, IPSec does not protect traffic that is sent or received during startup. However, if you configure a firewall between two separate forests, as described in this appendix, ................. ...

In the Windows implementation of IPSec, the IPSec service starts automatically, by default. A delay in any service that starts automatically can delay all other dependent services that also start automatically. Therefore, to minimize the time required for a computer to start and to allow for IPSec policy to be applied as quickly as possible during this time, the IPSec service is configured by default to not have other dependent services. If the IPSec service is configured to have a dependent service, however, the IPSec service might be unable to apply The Assigned IPsec Policy Before The Dependent Service IS Notified That The IPsec Service Is Ready.

With Windows Server 2003 IPSec, you can ensure that IPSec provides security during computer startup through a combination of two methods. First, configure a computer startup mode (also known as the bootmode) for the IPSec driver so that traffic can be filtered before the IPSec service starts. To configure the computer startup mode for the IPSec driver, you must use the netsh ipsec dynamic set config bootmode command. Second, create and assign a persistent IPSec policy. persistent policy secures a computer even if a local or Active Directory-based IPSec policy can not be applied. After the IPSec service starts and applies the persistent policy, the IPSec service notifies the IPSec driver to move out of startup mode and to apply the persistent policy. to configure persistent policies, you must use the netsh ipsec static set Store location = persistent Command. Because Persistent Policy Adds To or Overrides The Local OR Active Directory-Based Policy, And It Remains in Effect Regardless Of WH ether other policies are applied, you should use persistent policies to secure traffic between domain controllers only when: · Computer startup security is required before local or Active Directory-based IPSec policy is applied.

· Faster IPSec-secured connectivity with a remote domain controller is required during computer startup. You can eliminate minor delays in the application of local or Active Directory-based IPSec policy by using persistent policy.

· You can use netsh ipsec command-line scripts to manage policy configuration on Domain Controllers, Rather Than Local or Active Directory-based IPsec Policy.

For more information about Netsh IPSec, see "Netsh commands for Internet Protocol security" in Help and Support Center for Windows Server 2003.Security during Safe Mode with Networking and Directory Services Restore Mode

In Windows 2000, the IPSec service does not start when the computer is started in Safe Mode with Networking or when Directory Services Restore Mode is used. Accordingly, IPSec does not protect traffic that is sent or received during these times. However, if you configure a firewall between the domain controllers, as described in this appendix, and if the firewall allows only IPSec traffic, then connectivity with the remote domain controller is blocked by the firewall and by the IPSec policy configuration on the remote domain controller.

In Windows Server 2003, the IPSec service also does not start when either Safe Mode with Networking or Directory Services Restore Mode is used. However, if you have already assigned a persistent IPSec policy or a local or Active Directory-based IPSec policy to a computer , by default, the IPSec driver provides stateful filtering of inbound traffic to that computer. For more information about using IPSec during Safe Mode with Networking, see Chapter 6, "Deploying IPSec" in Deploying Network Services in the Windows Server 2003 Deployment Kit, on The Web at http://go.microsoft.com/fwlink/?LinkId=8195.

Using IPsec Filters to Secure Traffic Between Domain Controllers over Specific Protocols and ports

For the domain trust scenario described in this appendix, you can configure IPSec filters to secure traffic over only the protocols and ports that are required for communication between domain controllers, rather than using IPSec to secure all traffic between domain controllers. You can not do this, however, when RPC is required for communication between domain controllers because the port numbers are not statically defined for all RPC programs.When a domain trust is configured, the following protocols and ports are required for communication between domain controllers:

· Kerberos (88 / TCP, 88 / UDP, But Not Used Between Domain Controllers if An expected thing "is configured)

· LDAP (389 / UDP, 389 / TCP, And / OR 636 / TCP IF Using LDAP over SSL)

· SMB over IP (445 / TCP, 445 / UDP)

· DNS (53 / TCP, 53 / UDP Used for Name Lookups)

TO Secure ONLY THE COMMUNICATION Used Between Domain Controllers in Domain Trusts, Add The Following Rules To Your IPsec Policy (SEA-PN-DC-01 and SEA-NA-DC-01 Are Used as an esample):

Rules for Outbound Connections Initiated from SEA-PN-DC-01 TO SEA-NA-DC-01

Source Address

Destination Address

Protocol

Source Port

Destination Port

Action

CERTIFICATION Authority (CA)

Name of rule / notes

172.16.40.5

172.16.8.5

UDP

Any

88

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, Kerberos UDP, Outbound

172.16.40.5

172.16.8.5

TCP

Any

88

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, Kerberos TCP, Outbound

172.16.40.5

172.16.8.5

UDP

Any

389

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, LDAP UDP, Outbound

172.16.40.5

172.16.8.5

TCP

Any389

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, LDAP TCP, OUTBOUND

172.16.40.5

172.16.8.5

TCP

Any

636

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, LDAP over SSL (LDAPS) TCP OUTBOUND

172.16.40.5

172.16.8.5

UDP

Any

445

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, SMB UDP, Outbound

172.16.40.5

172.16.8.5

TCP

Any

445

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, SMB TCP, OUTBOUND

172.16.40.5

172.16.8.5

UDP

Any

53

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, DNS UDP, Outbound

172.16.40.5

172.16.8.5

TCP

Any

53

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, DNS TCP, Outbound

Rules for Inbound Connections Initiated from SEA-NA-DC-01 To SEA-PN-DC-01 172.16.8.5

172.16.40.5

UDP

Any

88

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, Kerberos UDP, Inbound

172.16.8.5

172.16.40.5

TCP

Any

88

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, Kerberos TCP, INBOUND

172.16.8.5

172.16.40.5

UDP

Any

389

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, LDAP UDP, Inbound

172.16.8.5

172.16.40.5

TCP

Any

389

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, LDAP TCP, INBOUND

172.16.8.5

172.16.40.5

TCP

Any

636

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, LDAPS TCP, INBOUND

172.16.8.5

172.16.40.5

UDP

Any

445

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, SMB UDP, Inbound172.16.8.5

172.16.40.5

TCP

Any

445

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, SMB TCP, INBOUND

172.16.8.5

172.16.40.5

UDP

Any

53

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, DNS UDP, Inbound

172.16.8.5

172.16.40.5

TCP

Any

53

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, DNS TCP, INBOUND

172.16.8.5

172.16.40.5

ICMP

N / a

N / a

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirrored, ICMP, Both Directions

172.16.8.5

172.16.40.5

Any

N / a

N / a

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

N / a

Mirrored, Block All Other Between IPS

The second to last rule in the table, "Mirrored, ICMP, both directions," allows ICMP traffic between domain controllers so that you can use the ping command to test network connectivity. However, you can not use the ping command to test IPSec policy configurations because IPSec filters are defined for each protocol and port. The last rule in the table, "Mirrored, block all else between IPs," specifies that all other traffic between the two IP addresses of the two domain controllers is blocked and that, therefore, any attempts to communicate over RPC fail. With this IPSec policy, security associations use ESP 3DES / SHA1 IPSec encapsulation for only the protocols and ports that are specified in the table. When you use Network Monitor to view the traffic that is sent over these protocols And ports, That Traffic Appears as ESP IPsec Packets.

This IPSec policy requires that you create many rules because you must specify the direction of the traffic. It is recommended that you test an IPSec policy that uses a more basic "All Traffic" filter configuration first, before you test a policy that uses this more detailed filtering configuration (in general, you should use the simplest IPSec policy possible to meet your security requirements and management capabilities). It is also recommended that you test an IPSec policy that uses IPSec AH encapsulation first, rather than ESP, so that you can use Network Monitor captures to interpret the IPSec traffic for troubleshooting. to further aid in troubleshooting, you can also modify the last rule in the table to use an AH action, rather than a Block action.Keep in mind that if you use the My IP Address Filter, You Must Customize An Ipsec Policy for Each Domain, But if You Use Specific IP Addresses As Source And Destination Addresses, You CAN Apply this IPsec Policy TO Both SEA-NA-DC-01 A ND SEA-PN-DC-01.

Using IPsec Filters to Block A Subset of IPsec-Secured Traffic

Many TCP and UDP ports on a domain controller are used to support domain members and to host other services and applications. However, some ports are not required for communication between domain controllers. A successful network attack on any port or protocol can compromise a domain controller . You can configure firewalls to permit traffic only on certain ports that are required for communication for domain trusts between a domain controller in a perimeter network and a domain controller in an internal network, as described in Deploying Domain Controllers in a Perimeter Network earlier in this paper. However, if you use IPSec to bypass these firewalls, then the firewalls might be unable to filter IPSec-secured traffic over certain ports and protocols. If you are using IPSec AH or ESP without encryption for digital signing of traffic only, verify whether The FireWalls or Routers That You Plan To Use Can Inspect ipsec-secured Traffic. If You Use IPsec ESP Encryption To Secure Traffic, H Owever, Then Network Devices Cannot Inspect ipsec-secured traffic.

As an alternative, you can configure IPSec filters to block a subset of IPSec-secured traffic by blocking access to specific ports. Consider using this approach if you are using IPSec encryption or if your network devices can not inspect traffic that is digitally signed by IPSec. As an example, this section describes how to configure IPSec filters to block access to NetBIOS over TCP / IP (NetBT) ports on a specific domain controller IP address, when IPSec is used to secure all other traffic with that IP address. Before implementing an IPSec policy that uses detailed filtering such as this, consider whether it is feasible to devote the time and administrative effort required to do so. If not, you might depend instead on trust configuration and measures to enhance security on domain controllers to defend against attacks on Ipsec-second traffic.The Recommended Simple Rule Described Earlier in this appendix secures All Traffic Between The IP Addresses of the Two Domain Controllers. The Follo WING TABLE SUMMARIZES THISULE, Using The Two Domain Controllers in The Example:

Source Address

Destination Address

Protocol

Source Port

Destination Port

Action

CERTIFICATION Authority (CA)

Name of rule / notes

172.16.40.5

172.16.8.5

Any

N / a

N / a

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

SEA-PN-DC-01 <-> SEA-NA-DC-01, ALL TRAFFIC

172.16.8.5

172.16.40.5

Any

N / a

N / a

Require ESP 3DES / Sha1, No Inbound Clear, No Fallback To Clear

Ca root

Mirror (Automatically Generated)

In Windows 2000, when this filter (known as the "All Traffic" filter) is used, IPSec-secured traffic is received, verified, and then accepted without further inbound filter comparisons. On the domain controller in the internal network (SEA-NA -DC-01, in the example), IPSec can not secure all traffic between 172.16.40.5 and 172.16.8.5 and also block inbound NetBT traffic from 172.16.40.5. However, outbound traffic is matched against the most specific outbound IPSec filter. You can use this approach as a limited defense against certain port-based attacks within an "All Traffic" filter.For example, if an attacker compromises the domain controller in the perimeter network (SEA-PN-DC-01, in the example), the IPSec filters on this domain controller can not provide a defense against further attacks. However, you can block access to the NetBT ports on the internal domain controller by creating a filter to block outbound NetBT responses from that domain controller to the perimeter network domain c Ontroller.

To do this, add the following additional rule to the IPSec policy for SEA-NA-DC-01. This rule secures all traffic between 172.16.40.5 and 172.16.8.5 and blocks outbound NetBT traffic from 172.16.8.5, on UDP and TCP ports 137, 138, And 139.

Source Address

Destination Address

Protocol

Source Port

Destination Port

Action

CERTIFICATION Authority (CA)

Name of rule / notes

172.16.8.5

172.16.40.5

UDP

137, 138, 139

Any

Block

N / a

One-Way Filter to block Outbound NetBT UDP Response Traffic TO SEA-PN-DC-01

172.16.8.5

172.16.40.5

TCP

137, 138, 139

Any

Block

N / a

One-Way Filter to block Outbound NetBt TCP Response Traffic TO SEA-PN-DC-01

Because the filters for this rule block only outbound responses from the NetBT ports on SEA-NA-DC-01, SEA-NA-DC-01 can still receive incoming traffic on these ports from SEA-PN-DC-01. Under normal operations , however, IPSec filters on SEA-PN-DC-01 can block outbound traffic on these ports.These filters are more specific than the "All Traffic" filter because they specify certain protocols and ports. If the blocking filter specified a more general address combination, such as from 172.16.8.5 to 172.16.40.0/255.255.255.0 (the perimeter network subnet), then the blocking filter would be more general than the "All Traffic" filter, and, therefore, this filter would block IPSec-secured Traffic over udp and tcp ports 137, 138, and 139.

In Windows Server 2003 IPSec, after inbound IPSec-secured traffic is decapsulated, an additional filter lookup is performed against the entire IPSec policy. This enhancement allows further inbound filter comparisons to be made for IPSec-secured traffic, so that you can configure an inbound filter to block a specific subset of IPSec-secured traffic. For example, if SEA-NA-DC-01 was running Windows Server 2003 rather than Windows 2000, you could configure a set of inbound IPSec filters to block inbound traffic on UDP and TCP Ports 137, 138, And 139. However, Thesenbound Blocking Filters Werbe No Effect If The WERE Applied with The "All Traffic" Filter to A Domain Controller Running Windows 2000.

Note

The use of inbound filters to block IPSec-secured traffic on NetBT ports is provided only as an example. Some domain controller deployment scenarios might require communication using NetBT or other ports. Likewise, in some domain controller environments, additional ports might need to be used . to ensure that IPSec filters do not block traffic that is required in your environment, make sure to test your IPSec policy configuration thoroughly. For example, trust validation between two domain controllers in different domains requires the use of the Net Logon service. Because the Net Logon service can not use a single RPC port, it uses the RPC endpoint mapper and, therefore, requires that traffic be allowed over TCP port 135, UDP port 135, and a range of dynamic RPC ports that are used by the mapper. Accordingly, IF you configure a one-way trust across forests so That the domain in the perimeter network trusts the domain in the internal network, and you also configure an ipsec policy on the domain controllers to block IPSec-secured traffic over TCP or UDP port 135, or any other protocols and ports used by the Net Logon service (or dependent traffic), the Net Logon service will not validate the trust.Resources

................... ..

Windows 2000 IPSec

· For Information About Windows 2000 IPsec, See Internet Protocol Security, In The Windows 2000 Resource Kit, at http://go.microsoft.com/fwlink/?LinkId=16465.

· For Information About Windows 2000 IPsec and Other Security Features of Windows 2000, See IPsec, at http://go.microsoft.com/fwlink/?LinkId=13283.

· For information about diagnostics and troubleshooting procedures for Windows 2000 IPSec, see Step-by-Step Guide to Internet Protocol Security (IPSec), at http://go.microsoft.com/fwlink/?LinkId=269.· For procedures published by the National Security Agency (NSA) for configuring IPSec policy to secure communication among all domain controllers in a Windows 2000 domain, see "Chapter 5: Configuring IPsec Policy for Secure Domain Controller Communications," in the Microsoft Windows 2000 IPsec Guide, at http : //go.microsoft.com/fwlink/? linkid = 16470.

Windows Server 2003 IPSec

· For More Information About Windows Server 2003 Ipsec, See Help and Support Center for Windows Server 2003.

· For deployment information about Windows Server 2003 IPSec, see Chapter 6, "Deploying IPSec" in Deploying Network Services in the Windows Server 2003 Deployment Kit, on the Web at http://go.microsoft.com/fwlink/?LinkId=8195 .

Windows 2000 general

· For example configurations that show the deployment of Windows 2000 technologies on an actual network that simulates a large organization and the Internet, see Deployment Lab Scenarios, at http://go.microsoft.com/fwlink/?LinkId=504.

· For Information About TCP / IP, See Microsoft Windows 2000 TCP / IP Implementation Details, at http://go.microsoft.com/fwlink/?LinkId=16467.

Security for Windows 2000 Active Directory

· For information about how to configure IPSec blocking filters to harden domain controllers, see Chapter 7, "Hardening Specific Server Roles," in Securing Windows 2000 Server, at http://go.microsoft.com/fwlink/?LinkId=15394.

· For information about how to configure a firewall to enable replication traffic in an Active Directory environment, see Active Directory Replication over Firewalls, at http://go.microsoft.com/fwlink/?LinkId=16461.· For information about security considerations For use Active Directory In Perimeter Networks, See:

O Chapter 5, "Security Design" in The Reference Architecture Guide: Internet Data Center, at http://go.microsoft.com/fwlink/?LinkId=16468.

O Chapter 8, "Directory Services," in The Reference Architecture Guide: Enterprise Data Center, at http://go.microsoft.com/fwlink/?LinkId=16463.

Windows 2000 Certificate Services

· For Information About Windows 2000 Certificate Services, See "Step-by-Step Guide To Administering Certificate Services, at http://go.microsoft.com/fwlink/?LinkId=326.

Microsoft Knowledge Base Articles

. · To find Knowledge Base articles, see the Microsoft Knowledge Base, at http://go.microsoft.com/fwlink/?LinkId=16462 The following Knowledge Base articles are referenced and / or relevant to the subject of this appendix:

o Knowledge base article 254728, "IPsec Does Not Secure Kerberos Traffic Between Domain Controllers"

o Knowledge base article 254949, "Client-to-domain controller and domain controller-to-domain controller ipsec support"

O Knowledge base article 321169, "Slow SMB Performance When You Copy Files from Windows XP to A Windows 2000 Domain Controller"

o Knowledge base article 811832, "IPsec default exemptions can be used to bypass ipsec protection in some scenarios"

o Knowledge base article 813878, "How to block specific network protocols and ports by using ipsec"

Microsoft Downloads · To Download The Windows 2000 High Encryption Pack, See Windows 2000 High Encryption Pack, At http://go.microsoft.com/fwlink/?LinkID=7272.

If you are running Windows 2000 or Windows 2000 Service Pack 1, you must install the Windows 2000 High Encryption pack to use 3DES. If you are using Windows Service Pack 2 or later, you do not need to install the Windows 2000 High Encryption Pack to Use 3des.

· To Download The Latest version of ipsecpol.exe, See IPsecpol.exe: Internet Protocol Security Policies Tool, at http://go.microsoft.com/fwlink/?LinkID=16466.

Ipsec Hardware Offload Adapters and Hardware Compatibility

· For information about the benefits of using IPSec hardware offload adapters, see Intel PRO / 100S Network Adapter, IPSec Offload Performance and Comparison, at http://go.microsoft.com/fwlink/?LinkId=16469.

· For Information About Hardware That Is Certified for Windows 2000, See Search for Compatible Hardware Devices, at http://go.microsoft.com/fwlink/?LinkId=3787.

Appendix B: IPsecpol Sample Script

@Echo off

Echo Ad Deployment in Segment Networks Deployment WhitePaper

Echo Windows 2000 IPsec Policy Command Line Example Script

REM ################################

Rem Ad Deployment in Segment Networks Deployment WhitePaper: Windows 2000 IPsec Policy Command Line Example

REM 9APR03

REM

Rem Download Latest version of ipsecpol_setup.exe from Windows 2000 Resource Kit, Free Tools http://www.microsoft.com/windows/reskits/default.asp

Rem See Also: KB Q813878 For Additional Examples of How To Use Permit / Block Filters

REM

REM

SET SEA-NA-DC-01 = 172.16.8.5

Set SEA-PN-DC-01 = 172.16.40.5

SET ROOTCA = OU = Copyright (c) 1997 Microsoft Corp, Ou = Microsoft Corporation, CN = Microsoft Root AuthorityEcho SEA-NA-DC-01 IS% SEA-NA-DC-01% (Corp)

ECHO SEA-PN-DC-01 IS% SEA-PN-DC-01% (Perimeter)

Echo root ca IS "% rootca%"

REM

Rem Could Set Environment Variable with Policy Name

Rem Could Set Environment Variable with location

Rem make Sure IPsecpol & .dlls Are in Path

REM

echo.

echo.

Echo Deleting Prior Versions of IPsec Policy

IPsecpol -w REG -P "Sea-Pn Forest Traffic TO SEA-NA Forest, 20FEB03, " -o

Ipsecpol -w reg -p "Sea-Na Forest Traffic TO SEA-PN Forest, 20FEB03, " -o

REM ################################

Rem Perimeter Network DC's IPsec Policy

Rem created as an Empty Policy That Specifie Appropriate General Tab Security Settings

Rem Keeps Rule Settings Focused On Driver Permit / Block Filters & Ike Quick Mode Settings

REM

REM -1S 3DES-SHA-2 = Ike Main Mode Setting To Use Only 3DES, SHA1 and DH Group 2 (1024BITS)

Rem IKE MM Lifetime Must Be Set IF -1S MM Security Setting IS Used

REM-1K 3600S = IKE MM Lifetime Set as 1HR / 3600 Seconds, Unlimited Quick Modes Under 1 Main Mode, NO MM PFS

Rem: 5 = polling interval 5 min - this can be set to whatver time you think best

Rem Polling Has No Effect ON Local Store IPsec Policy After Assigned When Ipssec Snapin Changes Are Made

Rem hoope, IPsecpol scripted change

Rem you want to avoid unassigning ipsec policy and realrupt ipsec secured communications

REM POSSIBLY BREAKING TCP Connections if Too MUCH Traffic Is Lost

REM ################## echo.

echo.

Echo Create: SEA-PN Perimeter Forest Traffic To Sea-Na Corp Forest, 20FEB03, UserId

Ipsecpol -w reg -p "sea-pn forward to sea-na forest, 20feb03, ": 5 -1S 3DES-SHA-2 -1K 3600S

REM ################################

Rem Add Rule To Secure All Traffic Between DC IP Addresses Using Single IP Pair All Traffic Filter

Rem -soft = allows Soft Security Associations for Initial Rollout

Rem You Must Uncheck "Allow Unsecured Communication with Non-IPsec Aware Computer" ONCE All DCS Have IPsec Policy

Rem Ike Quick Mode Uses Only ESP 3DES, SHA1

Rem No Ike Quick Mode PFS

REM IPSecpol Cannot Specify Individual Names for Filter Lists, Filters and Filter Actions.

Rem the name of the rule is buy as the name of the filter list and the filter action.

REM

REM ################################

Echo Add Rule: SEA-PN-DC-01 TO SEA-NA-DC-01 All Traffic, ESP 3DES / Sha1, Cert Auth

IPsecpol -w REG -P "Sea-Pn Forest Traffic TO SEA-NA Forest, 20FEB03, " -r "SEA-PN-DC-01 <-> SEA-NA-DC-01 All Traffic, ESP 3DES / SHA1 "-f% SEA-PN-DC-01%: * % SEA-NA-DC-01%: *: * -N ESP [3DES, SHA] -Soft -a Cert:"% rootca% "

Rem Identical Ways to Specify The Same Filter Are:

REM 172.16.40.5 172.16.8.5

REM 172.16.40.5:0 172.16.8.5:5:0:0

REM ################################

Rem Assign The SEA-PN-DC-01 Policy Active

REM ################################

Rem Echo Assign: Sea-Pn Perimeter Forest Traffic To Sea-Na Corp Forest, 20FEB03, UserId

Rem ipsecpol -w reg -p "Sea-Pn Forest Traffic TO SEA-NA Forest, 20FEB03, " -x

Rem ############################################################# #######################################

REM ################################

REM SEA-NA-DC-01's IPsec Policy Created As Local PolicyRem General Tab Settings - Some Ike Main Mode Options Are Specified Here

REM -1S 3DES-SHA-2 = Ike Main Mode Setting To Use Only 3Des, Sha1 and DH Group 2 (1024BITS) to Secure the Ike Negotiation Itself

Rem IKE MM Lifetime Must Be Set IF -1S MM Security Setting IS Used

REM-1K 3600S = IKE MM Lifetime Set as 1HR / 3600 Seconds

REM USE DEFAULTS for unlimited Quick Modes Under 1 Main Mode, NO MM PFS

Rem: 5 = polling interval 5 min - this can be set to whatver time you think best

Rem Polling Has No Effect ON Local Store IPsec Policy After Assigned When Ipssec Snapin Changes Are Made

Rem hoope, IPsecpol scripted change

Rem you want to avoid unassigning ipsec policy because it will interrupt ipsec secured communications

REM

REM ################################

echo.

echo.

Echo Create: Sea-Na Corp Forest Traffic To Sea-Pn Perimeter Forest, 20FEB03, UserId

IPsecpol -w REG -P "Sea-Na Forest Traffic TO SEA-PN Forest, 20FEB03, ": 5 -1S 3DES-SHA-2 -1K 3600S

REM ################################

Rem Add Rule To Secure All Traffic Between DC IP Addresses Using Single IP Pair All Traffic Filter

REM -F% SEA-PN-DC-01%: * % SEA-NA-DC-01%: *: * = mirrored filter for all traffic betWeen 172.16.40.5 and 172.16.8.5

REM-N ESP [3des, SHA] = Filter Action To Negotiate Security, IKE QM Negotiates One Security Method:

Rem ESP Transport Mode with 3DES & SHA1

Rem -soft = filter action to allow Fall Back to Clear (Create a Soft SA) if peer does not reply.

Rem this actually applies to Ike main mode, but it it is a filter action settingRem -a Cert: "% rootca%" =

Rem Use this root caboth to select the computer cert to authentic and to validate the peer's cert

Rem Authentication Method Is Part of The Ike Main Mode, But Specified Here As Part of A Rule,

Rem Since Rules Are Used to Specify Filters

Rem Use default setting for no inbound unsecured traffic

Rem Use default setting for ipsec sa & Ike qm lifetimes: 100MBYTES AND 1 HOUR, NO QM PFS

REM

REM ################################

Echo Add Rule: SEA-NA-DC-01 TO SEA-PN-DC-01 All Traffic, ESP 3DES / Sha1, Cert Auth

Ipsecpol -w REG -P "Sea-Na Forest Traffic TO SEA-PN Forest, 20FEB03, " -r "SEA-NA-DC-01 <-> SEA-PN-DC-01 All Traffic, ESP 3DES / SHA1 "-f% SEA-NA-DC-01%: * % SEA-PN-DC-01%: *: * -N ESP [3DES, SHA] -SOFT -A CERT:"% rootca% "

REM ################################

Rem More Specific Filters to Block Responses from SEA-NA-DC-01 Back to SEA-PN-DC-01 IP INSIDE IPSEC SA

REM

Rem this filter must use explicit ips so it is more specific THAN THE "All Traffic" Filter Above That Secures

Rem All Other Traffic Between The Two Ips with Ipsec ESP TRANSPORT MODE

REM

Rem Outbound Responses Are Blocked Because More Specific Windows 2000 Inbound Filters Will Not Be Matched

.

REM

REM ################################

Echo Add Rule: Block NetBT UDP 137 Response from SEA-NA-DC-01 IP

Ipsecpol -w reg -p "Sea-Na Forest Traffic TO SEA-PN Forest, 20FEB03, " -r "Block NetBT UDP 137 Reply from SEA-NA-DC-01 IP" -n block -f% SEA- NA-DC-01%: 137 =% SEA-PN-DC-01%: 0: UDPECHO Add Rule: Block NetBT UDP 138 Responses from SEA-NA-DC-01 IP

IPsecpol -w REG -P "Sea-Na Forest Traffic TO SEA-PN Forest, 20FEB03, " -r "Block NetBT UDP 138 Reply from SEA-NA-DC-01 IP" -n block -f% SEA- NA-DC-01%: 138 =% SEA-PN-DC-01%: 0: UDP

Echo Add Rule: Block NetBT UDP 139 Response from SEA-NA-DC-01 IP

Ipsecpol -w reg -p "Sea-Na Forest Traffic TO SEA-PN Forest, 20FEB03, " -r "Block NetBT UDP 139 Reply from SEA-NA-DC-01 IP" -n block -f% SEA- NA-DC-01%: 139 =% SEA-PN-DC-01%: 0: UDP

Echo Add Rule: Block NetBT TCP 137 Response from SEA-NA-DC-01 IP

IPsecpol -w REG -P "Sea-Na Forest Traffic TO SEA-PN Forest, 20FEB03, " -r "Block NetBT TCP 137 Reply from SEA-NA-DC-01 IP" -n block -f% SEA- NA-DC-01%: 137 =% SEA-PN-DC-01%: 0: TCP

Echo Add Rule: Block NetBT TCP 138 Responses from SEA-NA-DC-01 IP

Ipsecpol -w reg -p "Sea-Na Forest Traffic TO SEA-PN Forest, 20FEB03, " -r "block new NetBT TCP 138 Reply from SEA-NA-DC-01 IP" -n block -f% SEA- NA-DC-01%: 138 =% SEA-PN-DC-01%: 0: TCP

Echo Add Rule: Block NetBT TCP 139 Responses from SEA-NA-DC-01 IP

Ipsecpol -w reg -p "Sea-Na Forest Traffic TO SEA-PN Forest, 20FEB03, " -r "Block NetBT TCP 139 Reply from SEA-NA-DC-01 IP" -n block -f% SEA- NA-DC-01%: 139 =% SEA-PN-DC-01%: 0: TCP

REM ################################

Rem Assign The SEA-PN-DC-01 Policy Active

REM ################################

Rem Echo Assign: Sea-Na Corp Forest Traffic TO SEA-PN Perimeter Forest, 20FEB03, Useridrem Ipsecpol -w REG -P "SEA-NA Forest Traffic TO SEA-PN Forest, 20FEB03, -x

echo.

echo.

Echo script done.

Appendix C: port punching

., Mutual authentication and the domain controller location means.

Service Port / protocol RPC endpoint mapper 135 / tcp, 135 / udp RPC static port for Active Directory replication See Appendix D Kerberos 88 / tcp, 88 / udp LDAP 389 / tcp LDAP over SSL 636 / tcp Global Catalog LDAP 3268 / tcp Global Catalog LDAP over SSL 3269 / TCP SMB Over IP (Microsoft-DS) 445 / TCP, 445 / UDP DNS 53 / TCP, 53 / UDP Network Time Protocol (NTP) 123 / UDP Other Non-Ad Network Ports Used:

NetBIOS Name Service 137 / TCP, 137 / UDP NetBIOS DataGram Service 138 / UDP NetBIOS Session Service 139 / TCP

The Following Table Describes Other Non-Ad Network Ports That Are Used.

Service

Port / Protocol

NetBIOS Name Service 137 / TCP, 137 / UDP NetBIOS DataGram Service 138 / UDP NetBIOS Session Service 139 / TCP

APPENDIX D: Using A Static Port for Active Directory Replication

For each service that needs to communicate across a firewall there is a fixed port and protocol. Normally, the directory service and FRS use dynamically allocated ports that require a firewall to have a wide range of ports open. Although FRS can not be restricted to a fixed Port, The Directory Service Can Be Restricted to Communicate ON A Static Port Which Can Be Set Using The Following Registry Entry:

[HKEY_LOCAL_MACHINE / SYSTEM / CURRENTCONTROLSET / SERVICES / NTDS / parameters]]

"TCP / IP Port" = dword: 0000C000

Changing this registry key on a domain controller and rebooting it causes the directory service to use the TCP port named in the registry entry In the case above, it is port 49152 (hexadecimal 0000c000) .Appendix E:. Limiting the Range of Dynamic RPC Ports

You can use the registry key to limit the range of the dynamic RPC ports assigned by a particular computer. This procedure can be used to limit services that normally do not have a fixed RPC port by allowing only their dynamic port to be assigned from a smaller Well-KNown Range.

It is recommended that the dynamic ports range start at or above 5000 and consist of at least 20 ports. If additional applications that use dynamic RPC are installed on a computer, increase this range. Rebooting is necessary for the registry change to take effect.

To Limit The Range of Dynamic RPC Ports, Set The Following Registry Key:

[HKEY_LOCAL_MACHINE / SOFTWARE / Microsoft / RPC / Internet]

"Ports" = reg_multi_sz: 5000-5020

The above registry key example shows adding a "Ports" value of type Multi-String and setting it to "5000-5020". The value is added under the Internet key, which is added to the default RPC key. For more information about this Procedure, See Article 154596, "Configure RPC Dynamic Port Allocation to work with firewall," in the microsoft knowledge base, at http://go.microsoft.com/fwlink/?LinkId=16462.

转载请注明原文地址:https://www.9cbs.com/read-6946.html

New Post(0)