華為 路由交換之PPPoE


CHAP

CHAP
挑戰握手協議,通過3次握手發送MD5之后的校驗值來進行認證。
發送的是MD5之后的校驗值,但是配置依舊需要配置用戶名和密碼

PPPoE概述

發現階段:獲取對方以太網地址,以及確定唯一的PPPoE會話。
會話階段:包括兩部分,PPP街上階段和PPP報文傳輸階段
會話終結階段:會話建立以后任意時刻,發送報文結束PPPoE會話

一、客戶端會以廣播形式發送PADI的報文來發現接入的服務器
二、所有的PPPoE服務器在收到PADI報文之后,將客戶端請求的服務於自己能夠提供的服務進行比較,如果可以提供,則單播回復PADO報文
三、PPPoE客戶端選擇最優先收到的PADO報文對應的PPPoE服務器,並單播發送一個PADR報文
四、PPPoE服務器生成唯一的PPPoE Session ID,並發送PADS報文給客戶端,會話建立成功

PPPoE實現

1、服務器端:

aaa
[Server-R2-aaa]local-user hcie1 password cipher hcie1
[R2-aaa]local-user hcie1 service-type ppp
!
ip pool PPPoE1 //創建地址池
network 202.100.1.0 mask 255.255.255.0 //分配的IP地址
dns-list 114.114.114.114 8.8.8.8
!
interface Virtual-Template1 //創建邏輯的虛擬模版接口
ppp authentication-mode chap
remote address pool PPPoE1
ip address 202.100.1.1 255.255.255.0
#
interface GigabitEthernet0/0/0
pppoe-server bind Virtual-Template 1

2、客戶端(傳統VPN中的VPDN):

dialer-rule
dialer-rule 1 ip permit
!
interface Dialer1 //創建撥號接口
link-protocol ppp
ppp chap user hcie1
ppp chap password cipher heic1
ip address ppp-negotiate //地址的獲取方式從對端服務器得到
dialer user QYT
dialer bundle 1
dialer-group 1
!
interface GigabitEthernet0/0/0
pppoe-client dial-bundle-number 1 //物理接口和邏輯接口綁定
<R1-Gateway>display ip int bri
*down: administratively down
^down: standby
(l): loopback
(s): spoofing
The number of interface that is UP in Physical is 5
The number of interface that is DOWN in Physical is 2
The number of interface that is UP in Protocol is 3
The number of interface that is DOWN in Protocol is 4

Interface IP Address/Mask Physical Protocol
Dialer1 202.100.1.254/32 up up(s)       // 重點在於邏輯接口是否工作,物理接口在協議上是down的是正確的!
GigabitEthernet0/0/0 unassigned up down
GigabitEthernet0/0/1 unassigned down down
GigabitEthernet0/0/2 unassigned up down
NULL0 unassigned up up(s)
Serial1/0/0 unassigned up up
Serial1/0/1 unassigned down down
<R1-Gateway>display pppoe-client session summary
PPPoE Client Session:
ID Bundle Dialer Intf Client-MAC Server-MAC State
1 1 1 GE0/0/0 00e0fcc246b1 00e0fc8e7a48 UP

PPPoE的優化:

1)MTU

mtu 1492

2)MSS

tcp adjust-mss 1200

3)DNS
撥號接口下:

ppp ipcp dns admit-any
ppp ipcp dns request

4)靜態默認路由

[R1-Gateway]ip route-static 0.0.0.0 0.0.0.0 Dialer 1 // 由於dial1接口是一個PPP的接口


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM