Here are two routers connected through point-to-point , Configured for use ppp The agreement doesn't work right away , But through the following three steps .

LCP The protocol is used to negotiate some parameters of the port , For example, the maximum receiving unit supported by the router port is 2000, Require authentication ,PAP It is the authentication of account password plaintext transmission .

Then the opposite port returns the message , To tell the sender whether these parameters are supported
, If parameter return is not supported NCK message , The sender sends the modified parameters to the opposite port , Send confirmation message to the opposite port , That's a good deal .

 CP Negotiation is also used PPP Frame of , But the information part is not IP message ,
The information part is the negotiation parameters, as shown above .(LCP Message is PPP Frame of , When LCP When negotiating , The protocol field is 0xC021, It represents the information part, which is not the data of the network layer , It is the content of negotiation parameters , You can see that the fields are different , Frames represent different types of messages )

There are codes in the information section code, Different codes represent different content .

Finally, there is the data part , Type length included , Sum value . 

When LCP After negotiating the parameters of the message, the authentication starts , The fields of the authentication message need to be changed . It means that this is the content of authentication .

You can negotiate without authentication PAP The certification phase can be removed .

NCP stage :NCP Is a general term . Network configuration protocol , If it is specific TCP/IP So it's IPCP Negotiation stage . Once the authentication is passed, the network parameters are negotiated , Negotiation between the two sides IP Is the address correct . Interface will own IP Address sent to the peer interface , Interface to interface inspection IP Address conflict , And also at a network end , Then give it a confirmation .

These are the three stages above . Negotiate parameters first LCP-------> Authentication PAP---------> Address negotiation IPCP.

These are all negotiated , To transfer the above network layer protocol .

Negotiation parameters LCP 

ppp Two kinds of authentication supported by the protocol PAP authentication

pap Authentication is based on account and password , This account password is transmitted in clear text on the Internet  

ppp Two kinds of authentication supported by the protocol PAP authentication

 

IPCP consult

Authentication passed , Then we should negotiate IP Address , If both ends are static IP address , The address will be sent to the opposite end . Two addresses do not conflict , And in a network segment , Then it's legal . The opposite end will return a confirmation message . 

IP Address auto configuration

ppp The protocol supports automatic address assignment , Computer dial-up Internet access , Assign a computer to an operator IP address , This is automatic address assignment .

 

  Packet capture is as follows : It can be seen that we have to go through the first three stages , The network is unblocked in the back , It's inside IP data packet . Otherwise, the network layer cannot transmit data .

 

 

Technology
©2019-2020 Toolsou All rights reserved,
evo Tool usage problems ——Degenerate covariance rank, Umeyama alignment is not possible Experiment 4 Automated test tools - software test mysql Export data sql sentence _mysql according to sql Query statement export data Create a thread ——— Javaweb (3) Data structure experiment ( three )—— Stacks and queues TS stay vue2 Writing in the project web Front end signature plug-in _signature_pad Plug in implements electronic signature function docker Where is the image stored Qt Getting Started tutorial 【 Basic controls 】QCalendarWidget calendar control springboot How to get reality in ip address