创建公司分部到总部远程访问站点的网络规则和防火墙策略
我们现在需要为公司分部和总部远程站点之间的访问创建网络规则和允许访问的防火墙策略。
右击配置下的网络,然后点击新建,选择网络规则;
在新建网络规则向导页,输入规则名称,在此我命名为Internal to Main,点击下一步;
在网络通讯源页,点击添加,选择网络目录下的内部,点击下一步;
在网络通讯目标页,点击添加,选择网络目录下的Main,点击下一步;
在网络关系页,根据你自己的需要进行选择,在此我选择路由,然后点击下一步;
在正在完成新建网络规则向导页,点击完成;
此时,网络规则就创建好了。我们还需要创建允许内部和远程站点之间互访的访问规则,在此我忽略具体创建步骤,创建好的访问规则如下图所示:
点击应用保存修改和更新防火墙策略,根据ISA的警告来决定是否重启ISA服务器计算机。
测试PPTP模式下的站点到站点的VPN连接
我们首先在公司分部的Client上Ping公司总部网络中的服务器Denver,
/*Client 的IP地址设置*/
C:/Documents and Settings/admin>ipconfig /all
Windows IP Configuration
Host Name . . . . . . . . . . . . : mine Primary Dns Suffix . . . . . . . : Node Type . . . . . . . . . . . . : Unknown IP Routing Enabled. . . . . . . . : No WINS Proxy Enabled. . . . . . . . : No
Ethernet adapter Loopback: Connection-specific DNS Suffix . : Description . . . . . . . . . . . : Microsoft Loopback Adapter Physical Address. . . . . . . . . : 02-00-4C-4F-4F-50 Dhcp Enabled. . . . . . . . . . . : No IP Address. . . . . . . . . . . . : 10.2.1.9 Subnet Mask . . . . . . . . . . . : 255.255.255.0 Default Gateway . . . . . . . . . : 10.2.1.8
/*Ping Berlin的内部接口*/
C:/Documents and Settings/admin>ping 10.2.1.8 -n 1
Pinging 10.2.1.8 with 32 bytes of data:
Reply from 10.2.1.8: bytes=32 time=53ms TTL=128
Ping statistics for 10.2.1.8: Packets: Sent = 1, Received = 1, Lost = 0 (0% loss), Approximate round trip times in milli-seconds: Minimum = 53ms, Maximum = 53ms, Average = 53ms
/*Ping Denver的IP*/ C:/Documents and Settings/admin>ping 10.1.1.5 -n 2
Pinging 10.1.1.5 with 32 bytes of data:
Request timed out. Request timed out.
Ping statistics for 10.1.1.5: Packets: Sent = 2, Received = 0, Lost = 2 (100% loss),
C:/Documents and Settings/admin>ping 10.1.1.5 -t
Pinging 10.1.1.5 with 32 bytes of data:
Request timed out. Reply from 10.1.1.5: bytes=32 time=251ms TTL=126 Reply from 10.1.1.5: bytes=32 time=122ms TTL=126 Reply from 10.1.1.5: bytes=32 time=132ms TTL=126
Ping statistics for 10.1.1.5: Packets: Sent = 4, Received = 3, Lost = 1 (25% loss), Approximate round trip times in milli-seconds: Minimum = 122ms, Maximum = 251ms, Average = 168ms Control-C ^C
此时,站点到站点的VPN已经连接成功了。我们在Berlin上看看当前的IP地址和路由表:
C:/Documents and Settings/Administrator>ipconfig /all
Windows IP Configuration
Host Name . . . . . . . . . . . . : Berlin Primary Dns Suffix . . . . . . . : Node Type . . . . . . . . . . . . : Unknown IP Routing Enabled. . . . . . . . : Yes WINS Proxy Enabled. . . . . . . . : Yes
PPP adapter RAS Server (Dial In) Interface:
Connection-specific DNS Suffix . : Description . . . . . . . . . . . : WAN (PPP/SLIP) Interface Physical Address. . . . . . . . . : 00-53-45-00-00-00 DHCP Enabled. . . . . . . . . . . : No IP Address. . . . . . . . . . . . : 192.168.1.1 Subnet Mask . . . . . . . . . . . : 255.255.255.255 Default Gateway . . . . . . . . . :
Ethernet adapter Internal Connection:
Connection-specific DNS Suffix . : Description . . . . . . . . . . . : Intel 21140-Based PCI Fast Ethernet Adapt er (Generic) Physical Address. . . . . . . . . : 00-03-FF-1C-C7-2E DHCP Enabled. . . . . . . . . . . : No IP Address. . . . . . . . . . . . : 10.2.1.8 Subnet Mask . . . . . . . . . . . : 255.255.255.0 Default Gateway . . . . . . . . . :
Ethernet adapter External Connection:
Connection-specific DNS Suffix . : Description . . . . . . . . . . . : Intel 21140-Based PCI Fast Ethernet Adapt er (Generic) #2 Physical Address. . . . . . . . . : 00-03-FF-82-4B-61 DHCP Enabled. . . . . . . . . . . : No IP Address. . . . . . . . . . . . : 39.1.1.8 Subnet Mask . . . . . . . . . . . : 255.255.255.0 Default Gateway . . . . . . . . . : 39.1.1.1
/*远程站点拨入Florence后获得的IP地址*/ PPP adapter Main:
Connection-specific DNS Suffix . : Description . . . . . . . . . . . : WAN (PPP/SLIP) Interface Physical Address. . . . . . . . . : 00-53-45-00-00-00 DHCP Enabled. . . . . . . . . . . : No IP Address. . . . . . . . . . . . : 192.168.0.2 Subnet Mask . . . . . . . . . . . : 255.255.255.255 Default Gateway . . . . . . . . . :
/*显示本机的路由表,红色的为拨入Florence后所添加的路由*/ C:/Documents and Settings/Administrator>route print
IPv4 Route Table ================================================ Interface List 0x1 ........................... MS TCP Loopback interface 0x10002 ...00 53 45 00 00 00 ...... WAN (PPP/SLIP) Interface 0x10003 ...00 03 ff 1c c7 2e ...... Intel 21140-Based PCI Fast Ethernet Adap (Generic) 0x10004 ...00 03 ff 82 4b 61 ...... Intel 21140-Based PCI Fast Ethernet Adap (Generic) #2 0x20005 ...00 53 45 00 00 00 ...... WAN (PPP/SLIP) Interface =================================================== =================================================== Active Routes: Network Destination Netmask Gateway Interface Metric 0.0.0.0 0.0.0.0 39.1.1.1 39.1.1.8 20 10.1.1.0 255.255.255.0 192.168.1.2 192.168.0.2 1 10.2.1.0 255.255.255.0 10.2.1.8 10.2.1.8 20 10.2.1.8 255.255.255.255 127.0.0.1 127.0.0.1 20 10.255.255.255 255.255.255.255 10.2.1.8 10.2.1.8 20 39.1.1.0 255.255.255.0 39.1.1.8 39.1.1.8 20 39.1.1.1 255.255.255.255 39.1.1.8 39.1.1.8 20 39.1.1.8 255.255.255.255 127.0.0.1 127.0.0.1 20 39.255.255.255 255.255.255.255 39.1.1.8 39.1.1.8 20 127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1 192.168.0.2 255.255.255.255 127.0.0.1 127.0.0.1 50 192.168.0.255 255.255.255.255 192.168.0.2 192.168.0.2 50 192.168.1.1 255.255.255.255 127.0.0.1 127.0.0.1 50 192.168.1.2 255.255.255.255 192.168.0.2 192.168.0.2 1 224.0.0.0 240.0.0.0 10.2.1.8 10.2.1.8 20 224.0.0.0 240.0.0.0 39.1.1.8 39.1.1.8 20 224.0.0.0 240.0.0.0 192.168.0.2 192.168.0.2 50 255.255.255.255 255.255.255.255 10.2.1.8 10.2.1.8 1 255.255.255.255 255.255.255.255 39.1.1.8 39.1.1.8 1 Default Gateway: 39.1.1.1 =================================================== Persistent Routes: None
同样的,我们在Florence上看看当前的IP地址和路由表:
Windows IP Configuration Host Name . . . . . . . . . . . . : Florence Primary Dns Suffix . . . . . . . : Node Type . . . . . . . . . . . . : Unknown IP Routing Enabled. . . . . . . . : Yes WINS Proxy Enabled. . . . . . . . : Yes
PPP adapter RAS Server (Dial In) Interface: Connection-specific DNS Suffix . : Description . . . . . . . . . . . : WAN (PPP/SLIP) Interface Physical Address. . . . . . . . . : 00-53-45-00-00-00 DHCP Enabled. . . . . . . . . . . : No IP Address. . . . . . . . . . . . : 192.168.0.1 Subnet Mask . . . . . . . . . . . : 255.255.255.255 Default Gateway . . . . . . . . . :
Ethernet adapter Perimeter Connection: Connection-specific DNS Suffix . : Description . . . . . . . . . . . : Intel 21140-Based PCI Fast Ethernet Adapter (Generic) #2 Physical Address. . . . . . . . . : 00-03-FF-20-09-A4 DHCP Enabled. . . . . . . . . . . : No IP Address. . . . . . . . . . . . : 23.1.1.1 Subnet Mask . . . . . . . . . . . : 255.255.255.0 Default Gateway . . . . . . . . . :
Ethernet adapter Internal Connection: Connection-specific DNS Suffix . : Description . . . . . . . . . . . : Intel 21140-Based PCI Fast Ethernet Adapter (Generic) Physical Address. . . . . . . . . : 00-03-FF-6B-DC-62 DHCP Enabled. . . . . . . . . . . : No IP Address. . . . . . . . . . . . : 10.1.1.1 Subnet Mask . . . . . . . . . . . : 255.255.255.0 Default Gateway . . . . . . . . . :
Ethernet adapter External Connection: Connection-specific DNS Suffix . : Description . . . . . . . . . . . : Intel 21140-Based PCI Fast Ethernet Adapter (Generic) #3 Physical Address. . . . . . . . . : 00-03-FF-F2-16-38 DHCP Enabled. . . . . . . . . . . : No IP Address. . . . . . . . . . . . : 39.1.1.1 Subnet Mask . . . . . . . . . . . : 255.255.255.0 Default Gateway . . . . . . . . . : 39.1.1.7
PPP adapter : Connection-specific DNS Suffix . : Description . . . . . . . . . . . : WAN (PPP/SLIP) Interface Physical Address. . . . . . . . . : 00-53-45-00-00-00 DHCP Enabled. . . . . . . . . . . : No IP Address. . . . . . . . . . . . : 192.168.1.2 Subnet Mask . . . . . . . . . . . : 255.255.255.255 Default Gateway . . . . . . . . . :
/*显示本机的路由表,红色的为Berlin拨入后所添加的路由*/
IPv4 Route Table =================================================== Interface List 0x1 ........................... MS TCP Loopback interface 0x10002 ...00 53 45 00 00 00 ...... WAN (PPP/SLIP) Interface 0x10003 ...00 03 ff 20 09 a4 ...... Intel 21140-Based PCI Fast Ethernet Adapter (Generic) #2 0x10004 ...00 03 ff 6b dc 62 ...... Intel 21140-Based PCI Fast Ethernet Adapter (Generic) 0x10005 ...00 03 ff f2 16 38 ...... Intel 21140-Based PCI Fast Ethernet Adapter (Generic) #3 0x20006 ...00 53 45 00 00 00 ...... WAN (PPP/SLIP) Interface ========================================= ========================================= Active Routes: Network Destination Netmask Gateway Interface Metric 0.0.0.0 0.0.0.0 39.1.1.7 39.1.1.1 20 10.1.1.0 255.255.255.0 10.1.1.1 10.1.1.1 20 10.1.1.1 255.255.255.255 127.0.0.1 127.0.0.1 20 10.2.1.0 255.255.255.0 192.168.0.2 192.168.1.2 1 10.255.255.255 255.255.255.255 10.1.1.1 10.1.1.1 20 23.1.1.0 255.255.255.0 23.1.1.1 23.1.1.1 20 23.1.1.1 255.255.255.255 127.0.0.1 127.0.0.1 20 23.255.255.255 255.255.255.255 23.1.1.1 23.1.1.1 20 39.1.1.0 255.255.255.0 39.1.1.1 39.1.1.1 20 39.1.1.1 255.255.255.255 127.0.0.1 127.0.0.1 20 39.1.1.8 255.255.255.255 39.1.1.1 39.1.1.1 20 39.255.255.255 255.255.255.255 39.1.1.1 39.1.1.1 20 127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1 192.168.0.1 255.255.255.255 127.0.0.1 127.0.0.1 50 192.168.0.2 255.255.255.255 192.168.1.2 192.168.1.2 1 192.168.0.51 255.255.255.255 23.1.1.2 23.1.1.1 1 192.168.0.52 255.255.255.252 23.1.1.2 23.1.1.1 1 192.168.0.56 255.255.255.248 23.1.1.2 23.1.1.1 1 192.168.0.64 255.255.255.224 23.1.1.2 23.1.1.1 1 192.168.0.96 255.255.255.252 23.1.1.2 23.1.1.1 1 192.168.0.100 255.255.255.255 23.1.1.2 23.1.1.1 1 192.168.1.2 255.255.255.255 127.0.0.1 127.0.0.1 50 192.168.1.255 255.255.255.255 192.168.1.2 192.168.1.2 50 224.0.0.0 240.0.0.0 10.1.1.1 10.1.1.1 20 224.0.0.0 240.0.0.0 23.1.1.1 23.1.1.1 20 224.0.0.0 240.0.0.0 39.1.1.1 39.1.1.1 20 224.0.0.0 240.0.0.0 192.168.1.2 192.168.1.2 50 255.255.255.255 255.255.255.255 10.1.1.1 10.1.1.1 1 255.255.255.255 255.255.255.255 23.1.1.1 23.1.1.1 1 255.255.255.255 255.255.255.255 39.1.1.1 39.1.1.1 1 Default Gateway: 39.1.1.7 ========================================= Persistent Routes: None
现在,我们在Client上试试访问Denver的Web服务,访问成功;
在Florence上可以看到Client的访问活动。
修改VPN连接模式为L2TP/IPSec后进行测试
L2TP/IPSec模式和PPTP模式基本一致,我们可以直接在远程站点的属性中进行修改。由于目前此站点到站点的VPN连接是活动的,我们最好先禁用再启用它后再进行修改,在Florence上右击远程站点branch,然后点击禁用;
再次右击branch,然后点击启用;
再次右击branch,然后点击属性;
在弹出的branch属性对话框,点击协议标签,修改为L2TP/IPsec,然后点击确定;
点击应用保存修改和更新防火墙策略,最后重启ITALY阵列的所有服务器。
同样,在Berlin上右击远程站点Main,选择属性;
同样将连接所用的协议修改为L2TP/IPsec,然后点击确定;
点击应用保存修改和更新防火墙策略,根据ISA服务器的警告来决定是否重启ISA服务器计算机。
现在,我们在Denver上来Ping分部网络中的Client:
/*显示本机IP地址*/
C:/Documents and Settings/Administrator>ipconfig /all
Windows IP Configuration
Host Name . . . . . . . . . . . . : Denver Primary Dns Suffix . . . . . . . : contoso.com Node Type . . . . . . . . . . . . : Unknown IP Routing Enabled. . . . . . . . : No WINS Proxy Enabled. . . . . . . . : No DNS Suffix Search List. . . . . . : contoso.com
Ethernet adapter Local Area Connection:
Connection-specific DNS Suffix . : Description . . . . . . . . . . . : Intel 21140-Based PCI Fast Ethernet Adap er (Generic) Physical Address. . . . . . . . . : 00-03-FF-BA-80-BD DHCP Enabled. . . . . . . . . . . : No IP Address. . . . . . . . . . . . : 10.1.1.5 Subnet Mask . . . . . . . . . . . : 255.255.255.0 Default Gateway . . . . . . . . . : 10.1.1.1 DNS Servers . . . . . . . . . . . : 10.1.1.5
/*Ping 分部网络中的Client*/
C:/Documents and Settings/Administrator>ping 10.2.1.9 -t
Pinging 10.2.1.9 with 32 bytes of data:
Request timed out. Request timed out. Request timed out. Reply from 10.2.1.9: bytes=32 time=56ms TTL=62 Reply from 10.2.1.9: bytes=32 time=37ms TTL=62 Reply from 10.2.1.9: bytes=32 time=30ms TTL=62
Ping statistics for 10.2.1.9: Packets: Sent = 6, Received = 3, Lost = 3 (50% loss), Approximate round trip times in milli-seconds: Minimum = 30ms, Maximum = 56ms, Average = 41ms Control-C
此时,站点到站点的VPN连接已经连接成功了。
在Client上访问Denver的Web服务,访问成功,
在Florence上,你也可以看到Client访问的记录。
此时,基于PPTP和L2TP/IPSec的站点到站点的VPN连接就成功完成了。
在公司总部阵列ITALY上配置分部的IPSec模式的远程访问站点、相应的网络规则和防火墙策略
对于IPSec模式的VPN站点到站点的连接,你需要在连接两端的站点上安装IPSec证书。证书申请的具体过程我们就不介绍了,三台服务器上申请好的证书如下图所示,我已将用于L2TP/IPSec连接的身份验证证书删除:
在公司总部的任何一台ISA服务器上打开ISA管理控制台,点击虚拟专用网络,在中部的细节面板点击远程站点,再点击右边任务面板中的添加远程站点网络;
在欢迎使用网络创建向导页,输入远程站点的名字,在此我们依然使用branch(原建立的远程站点已经删除),点击下一步;
在VPN协议页,选择IP安全协议(IPSec)隧道模式,点击下一步;
在连接所有者页,选择Florence,点击下一步;
在远程站点网关页,输入远程VPN网关和本地网关的IP地址,远程网关的地址我们输入远程站点Berlin的外部IP地址39.1.1.8,本地网关的IP地址输入用于和远程站点连接的Florence的外部IP地址39.1.1.1,点击下一步;
在IPSec认证页,选择使用由此CA发布的证书,点击浏览;
在弹出的证书选择对话框,选择发布所使用的IPSec证书的Denver CA,点击确定;
在IPSec认证页点击下一步;
在网络地址页,点击添加范围来添加此远程网络包含的网络地址范围。对于IPSec模式的站点到站点的VPN连接,这个地方非常关键。除了包含远程网络的网络地址范围外,还必须包含远程站点的端点地址,否则你创建的IPSec模式的站点到站点的VPN连接可能不能正常工作;在此我添加分部的网络地址范围10.2.1.0~10.2.1.255,以及远程站点的端点地址39.1.1.8~39.1.1.8;点击下一步;
在正在完成新建网络向导页,点击完成;此对应公司分部网络的IPSec远程站点就创建好了。
我们还需要创建对应的网络规则和防火墙策略,在此我忽略具体过程,创建好的网络规则和防火墙策略如下图所示:
点击应用保存修改和更新防火墙策略,等到阵列中全部服务器配置文件同步后,根据ISA的警告来决定是否需要重启ISA服务器计算机。
在公司分部阵列GERMAN上配置总部的IPSec模式的远程访问站点、相应的网络规则和防火墙策略
在分公司配置IPSec远程站点和总部部署步骤基本一致,在公司分部的ISA服务器Berlin上打开ISA管理控制台,点击虚拟专用网络,在中部的细节面板点击远程站点,再点击右边任务面板中的添加远程站点网络;
在欢迎使用网络创建向导页,输入远程站点的名字,在此我们依然使用Main(原建立的远程站点已经删除),点击下一步;
在VPN协议页,选择IP安全协议(IPSec)隧道模式,点击下一步;
在连接所有者页,选择Berlin,点击下一步;
在远程站点网关页,输入远程VPN网关和本地网关的IP地址,远程网关的地址我们输入远程站点Florence的外部IP地址39.1.1.1,本地网关的IP地址输入用于和远程站点连接的Berlin的外部IP地址39.1.1.8,点击下一步;
在IPSec认证页,选择使用Denver CA发布的证书,点击下一步;
在网络地址页,点击添加范围来添加此远程网络包含的网络地址范围。在此我添加总部的网络地址范围10.1.1.0~10.1.1.255,以及远程站点的端点地址39.1.1.1~39.1.1.1;点击下一步;
在正在完成新建网络向导页,点击完成;此对应公司总部网络的IPSec远程站点就创建好了。同样我们也需要创建对应的网络规则和防火墙策略,创建好的网络规则和防火墙策略如下所示:
点击应用保存修改和更新防火墙策略,等到阵列中全部服务器配置文件同步后,根据ISA的警告来决定是否需要重启ISA服务器计算机。
测试IPSec模式下的站点到站点的VPN连接
同样的,我们先通过Ping来激活站点到站点的VPN连接。在分部网络中的客户机Client上运行Ping 10.1.1.5 -n 5,你会发现结果均为请求超时。因为在接收到客户的访问请求后,Berlin会向Florence进行站点到站点连接的连接初始化,协商安全性连接,此时还不能访问此远程站点。
在Berlin上打开事件查看器,在安全日志中,你可以发现如下图的IKE安全协商建立的事件日志,这表明Berlin和Florence之间的IKE安全协商建立成功;
在Florence上也有同样的事件日志:
在Florence上监控远程站点Branch的访问,然后在Client上,使用浏览器访问Denver上的Web服务,访问成功;
在Florence上的监视中,你可以看到Client的访问活动;
如果你在VPN连接的两个端点的任何一方使用IP安全监视器来查看,你可以看到当前IPSec连接的活动信息。
 【转自世纪安全网 http://www.21safe.com】
|