📄 rfc2114.txt
字号:
3.2. Header Format The DCAP header is used to identify the message type and the length of the frame. This is a general purpose header used for each frame that is passed between the DCAP server and the client. More information is needed for frames like CAN_U_REACH and I_CAN_REACH, therefore, it is passed to the peer as DCAP data. The structure of the DCAP data depends on the type of frames, and will be discussed in detail in later sections. The DCAP Header is given below: +-------------------------------------------+ | DCAP Packet Header (Each row is one byte) | +===========================================+ 0 | Protocol ID / Version Number | +-------------------------------------------+ 1 | Message Type | +-------------------------------------------+ 2 | Packet Length | + - - - - - - - - - - - - - - - - - - - - - + 3 | | +-------------------------------------------+ Figure 3-2. DCAP Header FormatChiang, et. al. Informational [Page 6]RFC 2114 DCAP February 1997 o The Protocol ID uses the first 4 bits of this field and is set to "1000". o The Version Number uses the next 4 bits in this field and is set to "0001". o The message type is the DCAP message type. o The Total Packet length is the length of the packet including the DCAP header, DCAP data and User Data. The minimum size of the packet is 4, which is the length of the header.3.3. DCAP Messages Most of the DCAP frames are based on the existing DLSw frames and corresponding frames have similar names. The information in the corresponding DCAP and DLSw frames may differ; but the functionalities are the same. Thus the DLSw State Machine is used to handle these DCAP frames. Some new DCAP frames were created to handle special DCAP functions. For example, the new DCAP frames, I_CANNOT_REACH and START_DL_FAILED provide negative acknowledgment. The DLSw frames not needed for DCAP, are dropped. The following table lists and describes all available DCAP messages: DCAP Frame Name Code Function --------------- ---- -------- CAN_U_REACH 0x01 Find if the station given is reachable I_CAN_REACH 0x02 Positive response to CAN_U_REACH I_CANNOT_REACH 0x03 Negative response to CAN_U_REACH START_DL 0x04 Setup session for given addresses DL_STARTED 0x05 Session Started START_DL_FAILED 0x06 Session Start failed XID_FRAME 0x07 XID Frame CONTACT_STN 0x08 Contact destination to establish SABME STN_CONTACTED 0x09 Station contacted - SABME mode set DATA_FRAME 0x0A Connectionless Data Frame for a link INFO_FRAME 0x0B Connection oriented I-Frame HALT_DL 0x0C Halt Data Link session HALT_DL_NOACK 0x0D Halt Data Link session without ack DL_HALTED 0x0E Session Halted FCM_FRAME 0x0F Data Link Session Flow Control Message DGRM_FRAME 0x11 Connectionless Datagram Frame for a circuitChiang, et. al. Informational [Page 7]RFC 2114 DCAP February 1997 CAP_XCHANGE 0x12 Capabilities Exchange Message CLOSE_PEER_REQUEST 0x13 Disconnect Peer Connection Request CLOSE_PEER_RESPONSE 0x14 Disconnect Peer Connection Response PEER_TEST_REQ 0x1D Peer keepalive test request PEER_TEST_RSP 0x1E Peer keepalive response Table 3-1. DCAP Frames3.4. DCAP Data formats The DCAP data is used to carry information required for each DCAP frame. This information is used by the Server or the Client and it does not contain any user data. The DCAP data frame types are listed in the following sections. Please note that the sender should set the reserved fields to zero and the receiver should ignore these fields.3.4.1. CAN_U_REACH, I_CAN_REACH, and I_CANNOT_REACH Frames These frame types are used to locate resources in a network. A CAN_U_REACH frame is sent to the server to determine if the resource is reachable. When a server receives a CAN_U_REACH frame, it should send out an LLC explorer frame to locate the destination specified in the CAN_U_REACH frame. If the destination is reachable, the server responds to the client with an I_CAN_REACH frame. If the server does not receive a positive acknowledgment within a recommended threshold value of 5 seconds, the server should send an LLC explorer to locate the destination again. If the server does not receive any response after sending out 5 explorers (recommended retry value), the destination is considered not reachable and an I_CANNOT_REACH frame is sent back to the client. The client should decide if retry CAN_U_REACH is necessary after the I_CANNOT_REACH frame is received from the server. When a server is in the process of searching a destination and receives another I_CAN_REACH with the same destination, the server should not send out another LLC explorer for that destination. The server should not send the CAN_U_REACH frame to the clients in a TCP session. When a server receives an LLC explorer whose destination is a known client, the server should respond to it directly.Chiang, et. al. Informational [Page 8]RFC 2114 DCAP February 1997 +---------------+-----------------------+ | Field Name | Information | +---------------+-----------------------+ | Message Type | 0x01, 0x02, or 0x03 | +---------------+-----------------------+ | Packet Length | 0x0C | +---------------+-----------------------+ Figure 3-3. CAN_U_REACH, I_CAN_REACH, and I_CANNOT_REACH Header +-----------------------------------+ | Field Name (Each row is one byte) | +===================================+ 0 | Target MAC Address | + - - - - - - - - - - - - - - - - - + 1 | | + - - - - - - - - - - - - - - - - - + 2 | | + - - - - - - - - - - - - - - - - - + 3 | | + - - - - - - - - - - - - - - - - - + 4 | | + - - - - - - - - - - - - - - - - - + 5 | | +-----------------------------------+ 6 | Source SAP | +-----------------------------------+ 7 | Reserved | +-----------------------------------+ Figure 3-4. CAN_U_REACH, I_CAN_REACH, and I_CANNOT_REACH Data The MAC Address field carries the MAC address of the target workstation that is being searched. This is a six-byte MAC Address field. The same MAC Address is returned in the I_CAN_REACH and the I_CANNOT_REACH frames. Byte 6 is the source SAP. The destination SAP is set to zero when an explorer frame is sent to the network.3.4.2. START_DL, DL_STARTED, and START_DL_FAILED Frames These frame types are used by DCAP to establish a link station (circuit). The START_DL frame is sent directly to the server that responds to the CAN_U_REACH frame. When the server receives this frame, it establishes a link station using the source and destination addresses and saps provided in the START_DL frame. If the circuit establishment is successful, a DL_STARTED frame is sent back as a response. If the attempt fails within a recommended value, 5 seconds, the server should retry again. If the server fails to establish aChiang, et. al. Informational [Page 9]RFC 2114 DCAP February 1997 circuit for a recommended retry value, 5 times, a START_DL_FAILED frame should be sent back to the client. If the client receives a START_DL_FAILED frame from the server, it is up to the client to decide if a START_DL frame needs to be sent to the server again. The server can also send START_DL frames to clients to establish circuits. +---------------+-----------------------+ | Field Name | Information | +---------------+-----------------------+ | Message Type | 0x04, 0x05, or 0x06 | +---------------+-----------------------+ | Packet Length | 0x18 | +---------------+-----------------------+ Figure 3-5. START_DL, DL_STARTED, and START_DL_FAILED HeaderChiang, et. al. Informational [Page 10]RFC 2114 DCAP February 1997 +-----------------------------------+ | Field Name (Each row is one byte) | +===================================+ 0 | Host MAC Address | + - - - - - - - - - - - - - - - - - + 1 | | + - - - - - - - - - - - - - - - - - + 2 | | + - - - - - - - - - - - - - - - - - + 3 | | + - - - - - - - - - - - - - - - - - + 4 | | + - - - - - - - - - - - - - - - - - + 5 | | +-----------------------------------+ 6 | Host SAP | +-----------------------------------+ 7 | Client SAP | +-----------------------------------+ 8 | Origin Session ID | +-----------------------------------+ 9 | | + - - - - - - - - - - - - - - - - - + 10| | + - - - - - - - - - - - - - - - - - + 11| | +-----------------------------------+ 12| Target Session ID | + - - - - - - - - - - - - - - - - - + 13| | + - - - - - - - - - - - - - - - - - + 14| | + - - - - - - - - - - - - - - - - - + 15| | +-----------------------------------+ 16| Largest Frame Size | +-----------------------------------+ 17| Initial Window size | +-----------------------------------+ 18| Reserved | + - - - - - - - - - - - - - - - - - + 19| | +-----------------------------------+ Figure 3-6. START_DL, DL_STARTED, and START_DL_FAILED Data The Host MAC address is the address of the target station if the session is initiated from the client, or it is the address of the originating station if the session is initiated from the server.Chiang, et. al. Informational [Page 11]
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -