实验二十三PPP协议中的CHAP和PAP验证Word格式文档下载.docx

上传人:b****6 文档编号:20297105 上传时间:2023-01-21 格式:DOCX 页数:14 大小:21.22KB
下载 相关 举报
实验二十三PPP协议中的CHAP和PAP验证Word格式文档下载.docx_第1页
第1页 / 共14页
实验二十三PPP协议中的CHAP和PAP验证Word格式文档下载.docx_第2页
第2页 / 共14页
实验二十三PPP协议中的CHAP和PAP验证Word格式文档下载.docx_第3页
第3页 / 共14页
实验二十三PPP协议中的CHAP和PAP验证Word格式文档下载.docx_第4页
第4页 / 共14页
实验二十三PPP协议中的CHAP和PAP验证Word格式文档下载.docx_第5页
第5页 / 共14页
点击查看更多>>
下载资源
资源描述

实验二十三PPP协议中的CHAP和PAP验证Word格式文档下载.docx

《实验二十三PPP协议中的CHAP和PAP验证Word格式文档下载.docx》由会员分享,可在线阅读,更多相关《实验二十三PPP协议中的CHAP和PAP验证Word格式文档下载.docx(14页珍藏版)》请在冰豆网上搜索。

实验二十三PPP协议中的CHAP和PAP验证Word格式文档下载.docx

(6)链路配置以及链路质量测试

(7)回叫(Callback)

(8)网络能力的协商选项,如:

网络层地址协商和数据压缩协商等

PPP定义了一整套的协议,包括链路控制协议(LCP)、网络层控制协议(NCP)和验证协议(PAP和CHAP)等。

 

其中,链路控制协议LCP(LinkControlProtocol):

用来协商链路的一些参数,负责创建并维护链路。

网络层控制协议NCP(NetworkControlProtocol):

用来协商网络层协议的参数。

3、PPP建立一个点到点连接的四个阶段

(1)链路的建立和配置协商

(2)链路质量确定

(3)网络层协议配置协商

(4)链路拆除

4、PPP的验证方式

PAP验证

PAP(PasswordAuthenticationProtocol,口令鉴定协议)是一种两次握手验证协议,它在网络上采用明文方式传输用户名和口令。

PAP验证的过程如下:

被验证方主动发起验证请求,将本端的用户名和口令发送到验证方;

验证方接到被验证方的验证请求后,检查此用户名是否存在以及口令是否正确。

如果此用户名存在且口令正确,验证方返回Acknowledge响应,表示验证通过;

如果此用户名不存在或口令错误。

验证方返回NotAcknowledge响应,表示验证不通过。

CHAP验证

CHAP(ChallengeHandshakeAuthenticationProtocol,质询握手鉴定协议)是一种三次握手验证协议,它只在网络上传输用户名,而用户口令并不在网络上传播。

CHAP验证过程如下:

验证方主动发起验证请求,向被验证方发送一些随机产生的报文,并同时将本端配置的用户名附带上一起发送给被验证方;

被验证方接到验证方的验证请求后,根据此报文中的用户名在本端的用户表中查找用户口令。

如找到用户表中与验证方用户名相同的用户,便利用报文ID和此用户的口令以MD5算法生成应答,随后将应答和自己的用户名送回;

验证方接收到此应答后,利用报文ID、自己保存的被验证方口令以及随机报文用MD5算法得出结果,与被验证方应答比较。

如果两者相同,则返回Acknowledge响应,表示验证通过,如果两者不相同,则返回NotAcknowledge相应,表示验证不通过。

二、实验案例

1、实验拓扑结构图:

2、配置说明:

Router1的S0:

192.168.1.10子网掩码:

255.255.255.0

Router2的S0:

192.168.1.20子网掩码:

3、具体配置:

方法一:

PAP的单向验证

Router1的配置:

[Router1]ints0

[Router1-Serial0]ipaddress192.168.10.1255.255.255.0

[Router1-Serial0]

%15:

01:

45:

LineprotocolipontheinterfaceSerial0isUP

[Router1-Serial0]link-protocolppp

[Router1-Serial0]ppppaplocal-usersunkepasswordsimplesunke

[Router1]discur

Nowcreateconfiguration...

Currentconfiguration

version1.74

sysnameRouter1

firewallenable

aaa-enable

aaaaccounting-schemeoptional

interfaceAux0

asyncmodeflow

link-protocolppp

interfaceEthernet0

interfaceEthernet1

interfaceSerial0

clockDTECLK1

ppppaplocal-usersunkepasswordsimplesunke

ipaddress192.168.10.1255.255.255.0

interfaceSerial1

interfaceSerial2

interfaceSerial3

Return

Router2的配置:

[Router2]ints0

[Router2-Serial0]ipaddress192.168.10.2255.255.255.0

[Router2-Serial0]

12:

53:

[Router2-Serial0]link-protocolppp

[Router2]local-usersunkeservice-typeppppasswordsimplesunke

[Router2-Serial0]pppauthentication-modepap

[Router2]dsicur

Incorrectcommand

[Router2]discur

local-usersunkeservice-typeppppasswordsimplesunke

sysnameRouter2

pppauthentication-modepap

ipaddress192.168.10.2255.255.255.0

测试结果:

[Router1]ping192.168.10.2

PING192.168.10.2:

56databytes,pressCTRL_Ctobreak

Replyfrom192.168.10.2:

bytes=56Sequence=0ttl=255time=27ms

bytes=56Sequence=1ttl=255time=26ms

bytes=56Sequence=2ttl=255time=26ms

bytes=56Sequence=3ttl=255time=26ms

bytes=56Sequence=4ttl=255time=26ms

---192.168.10.2pingstatistics---

5packetstransmitted

5packetsreceived

0.00%packetloss

round-tripmin/avg/max=26/26/27ms

[Router2]ping192.168.10.1

PING192.168.10.1:

Replyfrom192.168.10.1:

bytes=56Sequence=0ttl=255time=26ms

---192.168.10.1pingstatistics---

round-tripmin/avg/max=26/26/26ms

PAP的双向验证

Router2添加的配置:

[Router2-Serial0]ppppaplocal-userdjwpasswordsimpledjw

Router1添加的配置:

[Router1]local-userdjwservice-typeppppasswordsimpledjw

[Router1-Serial0]pppauthentication-modepap

[Router1-Serial0]discur

local-userdjwservice-typeppppasswordsimpledjw

再次测试结果:

round-tripmin/avg/max=26/26/26ms

ING192.168.10.1:

5packetsreceived

方法二:

CHAP的单向验证

[Router1-Serial0]ipaddress192.168.1.10255.255.255.0

[Router1-Serial0]pppchapusersunke

[Router1-Serial0]pppchappasswordsimplesunke

pppchapusersunke

pppchappasswordsimplesunke

ipaddress192.168.1.10255.255.255.0

[Router]sysRouter2

[Router2-Serial0]ipaddress192.168.1.20255.255.255.0

%16:

18:

40:

[Router2-Serial0]pppauthentication-modechap

[Router2-Serial0]pppchapuserdjw

pppauthentication-modechap

pppchapuserdjw

ipaddress192.168.1.20255.255.255.0

[Router2]ping192.168.1.10

PING192.168.1.10:

Replyfrom192.168.1.10:

bytes=56Sequence=0ttl=255time=25ms

bytes=56Sequence=1ttl=255time=25ms

bytes=56Sequence=3ttl=255time=25ms

bytes=56Sequence=4ttl=255time=25ms

---192.168.1.10pingstatistics---

round-tripmin/avg/max=25/25/26ms

[Router1]ping192.168.1.20

PING192.168.1.20:

Replyfrom192.168.1.20:

bytes=56Sequence=4ttl=255time=30ms

---192.168.1.20pingstatistics---

round-tripmin/avg/max=25/26/30ms

CHAP的双向验证

[Router1]local-userdjwservice-typeppppasswordsimplequidway

[Router1-Serial0]pppauthentication-modechap

local-userdjwservice-typeppppasswordsimplequidway

ipad

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 高等教育 > 研究生入学考试

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1