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.pswp.cn/bicheng/74795.shtml
繁體地址,請注明出處:http://hk.pswp.cn/bicheng/74795.shtml
英文地址,請注明出處:http://en.pswp.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;用于預訓練在多種數據集和設置中普遍有效的模型。我們首先將架構原型與預訓練目標這兩個常被混為一談的概念進行…