L2TP实验

一、实验拓扑

二、实验内容

手工部署IPec VPN

三、实验步骤

1、配置接口IP和安全区域

[PPPoE Client]firewall zone trust 
[PPPoE Client-zone-trust]add int g 1/0/0[NAS]firewall zone untrust 
[NAS-zone-untrust]add int g 1/0/1	
[NAS]firewall zone trust 
[NAS-zone-trust]add int g 1/0/0[LNS]firewall zone untrust 
[LNS-zone-untrust]add int g 1/0/0
[LNS]firewall zone trust 
[LNS-zone-trust]add int g 1/0/1

2、配置公网路由

[FW1]ip route-static 0.0.0.0 0 1.1.1.2[FW2]ip route-static 0.0.0.0 0 1.1.2.2

3、L2TP配置

(1)PPPoE Client

[PPPoE Client]int Dialer 1
[PPPoE Client-Dialer1]dialer user user1
[PPPoE Client-Dialer1]dialer-group 1
[PPPoE Client-Dialer1]ip address ppp-negotiate 
[PPPoE Client-Dialer1]ppp chap user user1
[PPPoE Client-Dialer1]ppp chap password cipher Password123
[PPPoE Client]dialer-rule 1 ip permit 
[PPPoE Client]int g 1/0/0
[PPPoE Client-GigabitEthernet1/0/0]pppoe-client dial-bundle-number 1

(2)NAS

[LAC]interface Virtual-Template 1	
[LAC-Virtual-Template1]ppp authentication-mode chap The command is used to configure the PPP authentication mode on the local end. 
Confirm that the peer end adopts the corresponding PPP authentication. Continue[
Y/N]:y
[LAC-Virtual-Template1]ip address 2.2.2.2 24
[LAC]firewall zone dmz	
[LAC-zone-dmz]add interface Virtual-Template 1[LAC]int g 1/0/0	
[LAC-GigabitEthernet1/0/0]pppoe-server bind virtual-template 1
[LAC-GigabitEthernet1/0/0]q[LAC]aaa
Info: The domain default is for common users.
[LAC-aaa-domain-default]service-type l2tp[LAC]user-manage user user1 domain default 
[LAC-localuser-user1]password Password123

4、建立L2TP隧道

[LAC]l2tp enable 
[LAC]l2tp-group 1
[LAC-l2tp-1]tunnel authentication 	
[LAC-l2tp-1]tunnel password cipher 
[LAC-l2tp-1]tunnel password cipher Hello123
[LAC-l2tp-1]tunnel name lac
[LAC-l2tp-1]start l2tp ip 20.1.1.2 fullusername user1

5、LNS配置

[LNS]ip pool l2tp
[LNS-ip-pool-l2tp]section 0 172.16.1.2 172.16.1.100 
[LNS-aaa]service-scheme l2tp
Info: Create a new service scheme.
[LNS-aaa-service-l2tp]ip-pool l2tp
[LNS-aaa]domain default 
Info: The domain default is for common users.
[LNS-aaa-domain-default]
[LNS-aaa-domain-default]service-type l2tp
[LNS]user-manage user user1 domain default 
[LNS-localuser-user1]password Password123
[LNS]interface Virtual-Template 1
[LNS-Virtual-Template1]ppp authentication-mode chap
[LNS-Virtual-Template1]ip address 172.16.0.1 24
[LNS-Virtual-Template1]remote service-scheme l2tp
[LNS]firewall zone dmz	
[LNS-zone-dmz]add interface Virtual-Template 1
[LNS]l2tp enable 
[LNS]l2tp-group 1
[LNS-l2tp-1]allow l2tp 
[LNS-l2tp-1]allow l2tp virtual-template 1 remote lac domain default
[LNS-l2tp-1]tunnel authentication 
[LNS-l2tp-1]tunnel password cipher Hello123

6、路由补充

[PPPoE Client]ip route-static 0.0.0.0 0 Dialer 1  出接口方式[PPPoE Client]firewall zone dmz  将Dialer 1接口划分到dmz区域,方便发包:
[PPPoE Client-zone-dmz]add interface Dialer 1

7、将所有设备的默认安全策略放通

[PPPoE Client]security-policy
[PPPoE Client-policy-security]default action permit[LAC]security-policy
[LAC-policy-security]default action permit[LNS]security-policy	
[LNS-policy-security]default action permit 

8、安全策略配置

(1)NAS

[LAC]security-policy
[LAC-policy-security]default action deny   先恢复默认策略为拒绝Warning: Setting the default interzone packet filtering to deny may affect actu
al data traffic. You are advised to configure the security policy based on the a
ctual services. Are you sure you want to continue? [Y/N]y
[LAC-policy-security]rule name local_to_untrust
[LAC-policy-security-rule-local_to_untrust]source-zone local
[LAC-policy-security-rule-local_to_untrust]destination-zone untrust
[LAC-policy-security-rule-local_to_untrust]source-address 20.1.1.1 mask 255.255.
255.255
[LAC-policy-security-rule-local_to_untrust]destination-zone
[LAC-policy-security-rule-local_to_untrust]destination-address 20.1.1.2 mask255.
255.255.255
[LAC-policy-security-rule-local_to_untrust]service l2tp
[LAC-policy-security-rule-local_to_untrust]service protocol udp source-port 0 to65535 destination-port 1701	
[LAC-policy-security-rule-local_to_untrust]action permit 

(2)LNS

[LNS]security-policy 	
[LNS-policy-security]default action deny 
[LNS-policy-security]dis this
security-policyrule name untrust_to_localsource-zone untrustdestination-zone localsource-address 20.1.1.1 mask 255.255.255.255destination-address 20.1.1.2 mask 255.255.255.255service l2tpservice protocol udp destination-port 1701action permitrule name dmz_to_trustsource-zone dmzdestination-zone trustsource-address 172.16.1.0 mask 255.255.255.0destination-address 192.168.1.0 mask 255.255.255.0action permit

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/bicheng/74795.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

青少年编程与数学 02-012 SQLite 数据库简介 01课题、数据库概要

青少年编程与数学 02-012 SQLite 数据库简介 01课题、数据库概要) 一、特点二、功能 课题摘要:SQLite 是一种轻量级的嵌入式关系型数据库管理系统。 一、特点 轻量级 它不需要单独的服务器进程来运行。不像 MySQL 或 PostgreSQL 这样的数据库系统需要一个专门的服务…

分布式系统面试总结:3、分布式锁(和本地锁的区别、特点、常见实现方案)

仅供自学回顾使用,请支持javaGuide原版书籍。 本篇文章涉及到的分布式锁,在本人其他文章中也有涉及。 《JUC:三、两阶段终止模式、死锁的jconsole检测、乐观锁(版本号机制CAS实现)悲观锁》:https://blog.…

Ubuntu 系统上完全卸载 Docker

以下是在 Ubuntu 系统上完全卸载 Docker 的分步指南 一.卸载验证 二.卸载步骤 1.停止 Docker 服务 sudo systemctl stop docker.socket sudo systemctl stop docker.service2.卸载 Docker 软件包 # 移除 Docker 核心组件 sudo apt-get purge -y \docker-ce \docker-ce-cli …

Postman 版本信息速查:快速定位版本号

保持 Postman 更新至最新版本是非常重要的,因为这能让我们享受到最新的功能,同时也保证了软件的安全性。所以,如何快速查看你的 Postman 版本信息呢? 如何查看 Postman 的版本信息教程

EF Core 异步方法

文章目录 前言一、为什么使用异步方法二、核心异步方法1)查询数据2)保存数据3)事务处理 三、异步查询最佳实践1)始终使用 await2)组合异步操作3)并行查询(谨慎使用) 四、异常处理五、…

装饰器模式介绍和典型实现

装饰器模式(Decorator Pattern)是一种结构型设计模式,它允许你通过将对象放入包含行为的特殊封装对象中来为原对象添加新的功能。装饰器模式的主要优点是可以在运行时动态地添加功能,而不需要修改原对象的代码。这使得代码更加灵活…

【 <二> 丹方改良:Spring 时代的 JavaWeb】之 Spring Boot 中的日志管理:Logback 的集成

<前文回顾> 点击此处查看 合集 https://blog.csdn.net/foyodesigner/category_12907601.html?fromshareblogcolumn&sharetypeblogcolumn&sharerId12907601&sharereferPC&sharesourceFoyoDesigner&sharefromfrom_link <今日更新> 一、开篇整…

神经网络知识点整理

目录 ​一、深度学习基础与流程 二、神经网络基础组件 三、卷积神经网络&#xff08;CNN&#xff09;​编辑 四、循环神经网络&#xff08;RNN&#xff09;与LSTM 五、优化技巧与调参 六、应用场景与前沿​编辑 七、总结与展望​编辑 一、深度学习基础与流程 机器学习流…

【sql优化】where 1=1

文章目录 where 11问题描述错误实现正确实现性能对比测试 where 11 问题描述 在动态 SQL 拼接场景中&#xff0c;开发者常使用 WHERE 11 简化条件拼接逻辑&#xff08;避免处理首个条件的 AND&#xff09;。理论上&#xff0c;数据库优化器会忽略 11&#xff0c;但字符串拼接…

车载以太网网络测试 -24【SOME/IP概述】

目录 1 摘要2 车载SOME/IP 概述2.1发展背景以及应用2.1.1车载 SOME/IP 背景2.1.2 车载 SOME/IP 应用场景 2.3 什么是SOME/IP2.3.1 SOME/IP定义2.3.2 SOME/IP在协议栈中的位置 3 SOA是什么4 SOME/IP主要功能5 SOME/IP标准 1 摘要 本文主要介绍SOME/IP的背景以及在车载行业的发展…

vue3中,route4,获取当前页面路由的问题

首先应用场景如下&#xff1a; 在main.js里面&#xff0c;引入的是路由的配置文件&#xff0c;如下&#xff1a; import {router} from /router; app.use(router); 路由配置文件router.js如下&#xff1a; import { createRouter, createWebHistory } from vue-router; imp…

ip改变导致的数据库连接不上

前言 需要用到路由器&#xff0c;所以先把家里的路由器给拆了先用着。新的路由器到了之后&#xff0c;更换上新的路由器之后&#xff0c;调用到服务会有报错&#xff0c;记录一下更换路由器之后ip重新分配服务可能会报的错. 进一步可以看到有关网路在服务当中的影响。 正文 …

Chrome 开发环境快速屏蔽 CORS 跨域限制!

Chrome 开发环境快速屏蔽 CORS 跨域限制【详细教程】 ❓ 为什么需要临时屏蔽 CORS&#xff1f; 在前后端开发过程中&#xff0c;我们经常会遇到 跨域请求被浏览器拦截 的问题。例如&#xff0c;你在 http://localhost:3000 调用 https://api.example.com 时&#xff0c;可能会…

【力扣hot100题】(009)和为K的子数组

还是太菜了&#xff08;我&#xff09;&#xff0c;写了半天滑动窗口&#xff0c;然后看了答案又写了半天时间超限…… 总之就是记录每前n个子串的和&#xff0c;然后使用hash存储和为某个值出现的次数&#xff0c;每次求得新和就看看是否存在前面新和-k的字符&#xff0c;有的…

使用 rsync 进行服务器文件同步与优化

使用 Rsync 工具在两台 Linux 服务器之间同步文件 Rsync 是一种高效的文件同步工具&#xff0c;它可以在本地或远程服务器之间同步文件和目录。Rsync 通过仅传输文件的变化部分来减少数据传输量&#xff0c;因此特别适合用于定期备份或同步大量数据。本文将详细介绍如何将 A 服…

卷积神经网络 - 微步卷积、空洞卷积

一、微步卷积 微步卷积&#xff08;Fractionally Strided Convolution&#xff09;&#xff0c;通常也称为转置卷积&#xff08;Transposed Convolution&#xff09;或反卷积&#xff08;Deconvolution&#xff09;&#xff0c;是深度学习&#xff08;尤其是卷积神经网络&…

详解java体系实用知识总结

0.java技术能力框架 基础模块应用模块综合模块技术岗位与面试流程常用工具集系统架构设计计算机基础常用框架微服务架构jvm原理缓存容器化多线程队列云计算&#xff08;阿里云/aws&#xff09;设计模式数据库数据结构与算法 1.常用设计模式与应用场景 工厂模式&#xff1a;s…

设计模式之创建型5种

设计模式 为什么设计模式是23种创建型 对象创建为什么设计模式是23种 设计模式之所以被归纳为23种,而非其他数量,源于GoF(Gang of Four)在1994年的系统性总结和分类。这一数量的确定并非偶然,而是基于以下核心原因: 他们遵循“大三律”(Rule of Three),即只有经过三个…

Oracle 23ai Vector Search 系列之2 ONNX(Open Neural Network Exchange)

文章目录 Oracle 23ai Vector Search 系列之2 ONNX(Open Neural Network Exchange)ONNX基本概念ONNX(Open Neural Network Exchange)ONNX Runtime ONNX Runtime 在Oracle数据库中的集成参考 Oracle 23ai Vector Search 系列之2 ONNX(Open Neural Network Exchange) 我们在看【…

统一语言学习范式

摘要 现有的预训练模型通常针对特定类别的问题。迄今为止&#xff0c;关于何种架构和预训练设置应为最佳似乎仍未达成共识。本文提出了一个统一的框架&#xff0c;用于预训练在多种数据集和设置中普遍有效的模型。我们首先将架构原型与预训练目标这两个常被混为一谈的概念进行…