当前位置: 首页 > news >正文

华为VPN技术

1.启动设备

2.配置IP地址

[FW1]int g1/0/0

[FW1-GigabitEthernet1/0/0]ip add 192.168.1.254 24

[FW1-GigabitEthernet1/0/0]int g1/0/1

[FW1-GigabitEthernet1/0/1]ip add 100.1.1.1 24

[FW1-GigabitEthernet1/0/1]service-manage ping permit

[FW2]int g1/0/0

[FW2-GigabitEthernet1/0/0]ip add 192.168.2.254 24

[FW2-GigabitEthernet1/0/0]int g1/0/1

[FW2-GigabitEthernet1/0/1]ip add 200.1.1.2 24

[FW2-GigabitEthernet1/0/1]service-manage ping permit

[AR1]int g0/0/0

[AR1-GigabitEthernet0/0/0]ip add 100.1.1.2 24

[AR1-GigabitEthernet0/0/0]int g0/0/1

[AR1-GigabitEthernet0/0/1]ip add 200.1.1.1 24

3.配置Tunnel接口

[FW1]int Tunnel 0

[FW1-Tunnel0]ip add 172.16.1.1 24

[FW1-Tunnel0]tunnel-protocol gre

[FW1-Tunnel0]source 100.1.1.1

[FW1-Tunnel0]destination 200.1.1.2

[FW2]int Tunnel 0

[FW2-Tunnel0]ip add 172.16.1.2 24

[FW2-Tunnel0]tunnel-protocol gre

[FW2-Tunnel0]source 200.1.1.2

[FW2-Tunnel0]destination 100.1.1.1

4.将防火墙接口加入指定区域

[FW1]firewall zone trust

[FW1-zone-trust]add int g1/0/0

[FW1-zone-trust]q

[FW1]firewall zone untrust

[FW1-zone-untrust]add int g1/0/1

[FW1-zone-untrust]add int Tunnel 0

[FW2]firewall zone trust

[FW2-zone-trust]add int g1/0/0

[FW2-zone-trust]q

[FW2]firewall zone untrust

[FW2-zone-untrust]add int g1/0/1

[FW2-zone-untrust]add int Tunnel 0

5.配置OSPF

[FW1]ospf 1

[FW1-ospf-1]area 0

[FW1-ospf-1-area-0.0.0.0]network 100.1.1.0 0.0.0.255

[AR1]ospf 1

[AR1-ospf-1]area 0

[AR1-ospf-1-area-0.0.0.0]network 100.1.1.0 0.0.0.255

[AR1-ospf-1-area-0.0.0.0]network 200.1.1.0 0.0.0.255

[FW2]ospf 1

[FW2-ospf-1]area 0

[FW2-ospf-1-area-0.0.0.0]network 200.1.1.0 0.0.0.255

6.配置路由条目

[FW1]ip route-static 192.168.2.0 24 Tunnel 0

[FW2]ip route-static 192.168.1.0 24 Tunnel 0

7.配置防火墙策略

[FW1]security-policy

[FW1-policy-security]rule name local-untrust

[FW1-policy-security-rule-local-untrust]source-zone local

[FW1-policy-security-rule-local-untrust]destination-zone untrust

[FW1-policy-security-rule-local-untrust]source-address 100.1.1.0 0.0.0.255

[FW1-policy-security-rule-local-untrust]destination-address 200.1.1.0 0.0.0.255

[FW1-policy-security-rule-local-untrust]action permit

[FW1-policy-security-rule-local-untrust]q

[FW1-policy-security]rule name untrust-local

[FW1-policy-security-rule-untrust-local]source-zone untrust

[FW1-policy-security-rule-untrust-local]destination-zone local

[FW1-policy-security-rule-untrust-local]source-address 200.1.1.0 0.0.0.255

[FW1-policy-security-rule-untrust-local]destination-address 100.1.1.0 0.0.0.255

[FW1-policy-security-rule-untrust-local]action permit

[FW1-policy-security-rule-untrust-local]q

[FW1-policy-security]rule name trust-untrust

[FW1-policy-security-rule-trust-untrust]source-zone trust

[FW1-policy-security-rule-trust-untrust]destination-zone untrust

[FW1-policy-security-rule-trust-untrust]source-address 192.168.1.0 0.0.0.255

[FW1-policy-security-rule-trust-untrust]action permit

[FW1-policy-security-rule-trust-untrust]q

[FW1-policy-security]rule name untrust-trust

[FW1-policy-security-rule-untrust-trust]source-zone untrust

[FW1-policy-security-rule-untrust-trust]destination-zone trust

[FW1-policy-security-rule-untrust-trust]action permit

[FW2]security-policy

[FW2-policy-security]rule name untrust-local

[FW2-policy-security-rule-untrust-local]source-zone untrust

[FW2-policy-security-rule-untrust-local]destination-zone local

[FW2-policy-security-rule-untrust-local]action permit

[FW2-policy-security-rule-untrust-local]q

[FW2-policy-security]rule name local-untrust

[FW2-policy-security-rule-local-untrust]source-zone local

[FW2-policy-security-rule-local-untrust]destination-zone untrust

[FW2-policy-security-rule-local-untrust]action permit

[FW2-policy-security-rule-local-untrust]q

[FW2-policy-security]rule name trust-untrust

[FW2-policy-security-rule-trust-untrust]source-zone trust

[FW2-policy-security-rule-trust-untrust]destination-zone untrust

[FW2-policy-security-rule-trust-untrust]source-address 192.168.2.0 0.0.0.255

[FW2-policy-security-rule-trust-untrust]action permit

[FW2-policy-security-rule-trust-untrust]q

[FW2-policy-security]rule name untrust-trust

[FW2-policy-security-rule-untrust-trust]source-zone untrust

[FW2-policy-security-rule-untrust-trust]destination-zone trust

[FW2-policy-security-rule-untrust-trust]source-address 192.168.1.0 0.0.0.255

[FW2-policy-security-rule-untrust-trust]action permit

8.配置NAT策略

[FW1]nat-policy

[FW1-policy-nat]rule name trust-untrust

[FW1-policy-nat-rule-trust-untrust]source-zone trust

[FW1-policy-nat-rule-trust-untrust]destination-zone untrust

[FW1-policy-nat-rule-trust-untrust]source-address 192.168.1.0 0.0.0.255

[FW1-policy-nat-rule-trust-untrust]action source-nat easy-ip

[FW2]nat-policy

[FW2-policy-nat]rule name trust-untrust

[FW2-policy-nat-rule-trust-untrust]source-zone trust

[FW2-policy-nat-rule-trust-untrust]destination-zone untrust

[FW2-policy-nat-rule-trust-untrust]source-address 192.168.2.0 0.0.0.255

[FW2-policy-nat-rule-trust-untrust]action source-nat easy-ip

验证:

1.pc2ping通pc1

2.查看FW2防火墙会话表(看GRE协议的数据包走向)

3.查看NAT地址转换(pc2ping100.1.1.1时,查看防火墙会话表,可以看到私网地址转换成200.1.1.2后访问100.1.1.1)

4.抓FW2G1/0/1端口的包查看(GRE的端口是47)

相关文章:

华为VPN技术

1.启动设备 2.配置IP地址 [FW1]int g1/0/0 [FW1-GigabitEthernet1/0/0]ip add 192.168.1.254 24 [FW1-GigabitEthernet1/0/0]int g1/0/1 [FW1-GigabitEthernet1/0/1]ip add 100.1.1.1 24 [FW1-GigabitEthernet1/0/1]service-manage ping permit [FW2]int g1/0/0 [FW2-Gi…...

CommonsBeanutils与Shiro发序列化利用的学习

一、前言 前面的学习中,过了一遍cc1-cc7的利用链,在CC2的利用链中,学习了 java.util.PriorityQueue,它在Java中是一个优先队列,队列中每一个元素都有自己的优先级。在反序列化这个对象时,为了保证队列顺序…...

运维云计算SRE-第2周

1. 总结学过的权限,属性及ACL相关命令及选项,示例。 一、Linux安全模型 (一)资源分派 Authentication(认证):验证用户身份,确保登录系统的用户是合法的。 Authorization&#xff08…...

React Native 全栈开发实战班 - 用户界面进阶之响应式设计实践

在移动应用开发中,响应式设计 是确保应用在不同设备、屏幕尺寸和方向下都能提供良好用户体验的关键。React Native 提供了多种工具和技巧来实现响应式设计,包括 Flexbox 布局、动态样式、屏幕尺寸适配等。本章节将详细介绍如何在 React Native 中进行响应…...

SlickGrid点击/双击事件

分析 SlickGrid提供了点击事件方法grid.onClick和grid.onDblClick用于捕获用户对表格列的点击,捕获到点击事件之后,修改表格数据,然后使用grid.updateRow方法将修改后的数据更新到表格中。 展示 代码 创建grid(HTML)…...

一文详细深入总结服务器选型

1. 题记: 服务器选型工作是项目规划检讨的一项非常重要的工作,本文详细深入总结服务器选型。 2. 服务器基础知识概览 2.1 服务器的定义与功能 2.1 .1 定义 服务器是一种高性能计算机,其设计目的是在网络中提供服务。它可以处理来自多个客…...

一、Nginx反向代理(七层代理)二、Nginx的TCP/UDP调度器(四层代理)

一、Nginx反向代理(七层代理) 实验要求 使用Nginx实现Web反向代理功能,实现如下功能: 后端Web服务器两台,可以使用httpd实现Nginx采用轮询的方式调用后端Web服务器两台Web服务器的权重要求设置为不同的值最大失败次数为…...

CSS+JQuery 实现弹力球效果,碰到屏幕边框弹回

实现弹力球效果&#xff0c;碰到屏幕边框弹回&#xff0c;效果如下 代码如下&#xff1a; <img src"../image/ball.png" alt"" class"ball"> <style>.ball {position: fixed;top: 50vh;left: 50vw;width: 15vw;height: 15vw;border…...

shell编程规范和脚本变量

什么是shell 人和计算机内核之间的中介&#xff1a; 计算机的语言是二进制&#xff0c;把人类的语言翻译成计算机能够识别的语言&#xff0c;然后让内核来处理 内核完成之后要把结果反馈给用户&#xff0c;要把计算机的翻译成人类能够识别的语言 命令解释器&#xff0c;pyc…...

jspm美容院管理系统

摘要 首先,论文一开始便是清楚的论述了系统的研究内容。其次,剖析系统需求分析,弄明白“做什么”,分析包括业务分析和业务流程的分析以及用例分析,更进一步明确系统的需求。然后在明白了系统的需求基础上需要进一步地设计系统,主要包罗软件架构模式、整体功能模块、数据库设计…...

Prometheus结合K8s(二)使用

上一篇介绍了如何搭建 Prometheus结合K8s&#xff08;一&#xff09;搭建-CSDN博客&#xff0c;这章介绍使用 页面访问 kubectl get svc -n prom 看promeheus和granfana的端口访问页面 Prometheus 点击status—target&#xff0c;可以看到metrics的数据来源&#xff0c;即各…...

【虚幻引擎】UE5数字人开发实战教程

本套课程将会交大家如何去开发属于自己的数字人&#xff0c;包含大模型接入&#xff0c;流式输出&#xff0c;语音识别&#xff0c;语音合成&#xff0c;口型驱动&#xff0c;动画蓝图&#xff0c;语音唤醒等功能。 课程介绍视频如下&#xff1a; 【虚幻引擎】UE5 历时一个多月…...

深入分析:固定参考框架在RViz中的作用与对数据可视化的影响 ros ubuntu20.04

深入分析&#xff1a;固定参考框架在RViz中的作用与对数据可视化的影响 RViz (Robot Visualization) 是 ROS (Robot Operating System) 中一种重要的三维可视化工具&#xff0c;主要用于实时观察和分析传感器数据、机器人状态信息以及环境模型。RViz的核心功能之一是固定参考框…...

Android:时间选择器(最下面有效果图)

1.创建DateUtil类 /*** Created by wangshuai on 2024/11/19.*/ public class DateUtil {public final static String PATTERN_ALL"yyyy-MM-dd HH:mm:ss";public final static String PATTERN_DEFAULT"yyyy-MM-dd";/*** 获取当前时间* return yyyy-MM-dd*…...

第十六届蓝桥杯模拟赛(第一期)-c++/c

c/c蓝桥杯模拟赛题解&#xff0c;非常详细 质因数 1、填空题 【问题描述】 如果一个数 p 是个质数&#xff0c;同时又是整数 a 的约数&#xff0c;则 p 称为 a 的一个质因数。 请问 2024 有多少个质因数。 【答案提交】 这是一道结果填空的题&#xff0c;你只需要算出结果后提…...

如何挑选路由器?需要看哪些参数?

挑选路由器时&#xff0c;选择合适的型号和参数对于确保家庭或办公网络的速度、稳定性和覆盖范围至关重要。以下是挑选路由器时需要考虑的关键参数和因素&#xff1a; 1. 无线标准 (Wi-Fi标准) 无线标准是衡量路由器性能的核心指标。不同的无线标准提供不同的速率、范围和技术…...

mysql-备份(二)

前章介绍了MySQL的内部数据结构btree&#xff0c;这章讲述mysql的备份 1&#xff1a;环境 ubuntu22.04 LST mysql5.7.42 or win10 mysql5.7.44 (这里图简单直接windows部署) download:https://downloads.mysql.com/archives/community/ 2:install 1> unzip mysql-5.7.44-w…...

Tailwind CSS 和 UnoCSS简单比较

UnoCSS 和 Tailwind CSS 都是流行的原子化 CSS 框架&#xff0c;但它们在设计理念、性能和使用方式上有一些重要的区别。下面是对它们的详细对比&#xff1a; 1. 概述 Tailwind CSS&#xff1a;Tailwind 是一个原子化的 CSS 框架&#xff0c;提供了大量的预定义类&#xff08;…...

unity3d————范围检测

目录 知识点一&#xff1a;什么是范围检测 知识点二&#xff1a;如何进行范围检测 问题&#xff1a; Physics.queriesHitTriggers 怎么查看是不是true&#xff1f; QueryTriggerInteraction.UseGlobal 参数意味着是否检测触发器将依据全局设置 Physics.queriesHitTrigge…...

修改this.$confirm的按钮位置、图标、文字及标题

在Vue.js项目中&#xff0c;this.$confirm 通常是基于某些UI库&#xff08;如Element UI或Ant Design Vue&#xff09;的对话框确认方法。 以下是基于Element UI的this.$confirm的用法示例。 在此之前&#xff0c;你的项目要已经安装了Element UI&#xff0c;如果没安装话就打…...

【杂谈】-递归进化:人工智能的自我改进与监管挑战

递归进化&#xff1a;人工智能的自我改进与监管挑战 文章目录 递归进化&#xff1a;人工智能的自我改进与监管挑战1、自我改进型人工智能的崛起2、人工智能如何挑战人类监管&#xff1f;3、确保人工智能受控的策略4、人类在人工智能发展中的角色5、平衡自主性与控制力6、总结与…...

Linux链表操作全解析

Linux C语言链表深度解析与实战技巧 一、链表基础概念与内核链表优势1.1 为什么使用链表&#xff1f;1.2 Linux 内核链表与用户态链表的区别 二、内核链表结构与宏解析常用宏/函数 三、内核链表的优点四、用户态链表示例五、双向循环链表在内核中的实现优势5.1 插入效率5.2 安全…...

Debian系统简介

目录 Debian系统介绍 Debian版本介绍 Debian软件源介绍 软件包管理工具dpkg dpkg核心指令详解 安装软件包 卸载软件包 查询软件包状态 验证软件包完整性 手动处理依赖关系 dpkg vs apt Debian系统介绍 Debian 和 Ubuntu 都是基于 Debian内核 的 Linux 发行版&#xff…...

使用分级同态加密防御梯度泄漏

抽象 联邦学习 &#xff08;FL&#xff09; 支持跨分布式客户端进行协作模型训练&#xff0c;而无需共享原始数据&#xff0c;这使其成为在互联和自动驾驶汽车 &#xff08;CAV&#xff09; 等领域保护隐私的机器学习的一种很有前途的方法。然而&#xff0c;最近的研究表明&…...

连锁超市冷库节能解决方案:如何实现超市降本增效

在连锁超市冷库运营中&#xff0c;高能耗、设备损耗快、人工管理低效等问题长期困扰企业。御控冷库节能解决方案通过智能控制化霜、按需化霜、实时监控、故障诊断、自动预警、远程控制开关六大核心技术&#xff0c;实现年省电费15%-60%&#xff0c;且不改动原有装备、安装快捷、…...

《用户共鸣指数(E)驱动品牌大模型种草:如何抢占大模型搜索结果情感高地》

在注意力分散、内容高度同质化的时代&#xff0c;情感连接已成为品牌破圈的关键通道。我们在服务大量品牌客户的过程中发现&#xff0c;消费者对内容的“有感”程度&#xff0c;正日益成为影响品牌传播效率与转化率的核心变量。在生成式AI驱动的内容生成与推荐环境中&#xff0…...

【SQL学习笔记1】增删改查+多表连接全解析(内附SQL免费在线练习工具)

可以使用Sqliteviz这个网站免费编写sql语句&#xff0c;它能够让用户直接在浏览器内练习SQL的语法&#xff0c;不需要安装任何软件。 链接如下&#xff1a; sqliteviz 注意&#xff1a; 在转写SQL语法时&#xff0c;关键字之间有一个特定的顺序&#xff0c;这个顺序会影响到…...

【android bluetooth 框架分析 04】【bt-framework 层详解 1】【BluetoothProperties介绍】

1. BluetoothProperties介绍 libsysprop/srcs/android/sysprop/BluetoothProperties.sysprop BluetoothProperties.sysprop 是 Android AOSP 中的一种 系统属性定义文件&#xff08;System Property Definition File&#xff09;&#xff0c;用于声明和管理 Bluetooth 模块相…...

css的定位(position)详解:相对定位 绝对定位 固定定位

在 CSS 中&#xff0c;元素的定位通过 position 属性控制&#xff0c;共有 5 种定位模式&#xff1a;static&#xff08;静态定位&#xff09;、relative&#xff08;相对定位&#xff09;、absolute&#xff08;绝对定位&#xff09;、fixed&#xff08;固定定位&#xff09;和…...

2023赣州旅游投资集团

单选题 1.“不登高山&#xff0c;不知天之高也&#xff1b;不临深溪&#xff0c;不知地之厚也。”这句话说明_____。 A、人的意识具有创造性 B、人的认识是独立于实践之外的 C、实践在认识过程中具有决定作用 D、人的一切知识都是从直接经验中获得的 参考答案: C 本题解…...