Last updated: 25 Nov 2002 |
Comments/corrections to: x25@witchfield.fsnet.co.uk |
X.25(1984) FACTS
In this document, hexadecimal numbers are shown by preceding them with '@'.
This is a distillation of information taken from ISO/IEC 8208:1990 - basically a collection of tables. It should allow you determine the protocol elements within a packet to help debug problems. It will not tell you whether the packet should have been transmitted - read the full document for that!
Note that ISO/IEC 8208 is more of a description of the end system (DTE) and the CCITT document X.25 is more a description of the network (DCE). They should not contradict each other!
The General Format ldentifier (GFI) is the first 4 bits of a packet.
The bits are QDmm, where:
The Logical Channel Number (LCN) is given by the next twelve bits
The Packet Type Identifier is the third octet of a packet, coded as follows:
First hex digit |
Second hex digit |
Packet Type |
any |
even |
Data |
even |
1 |
Receive Ready |
even |
5 |
Receive Not Ready |
even |
9 |
Reject |
0 |
B |
Call Request/Incoming Call |
0 |
F |
Call Accepted/Call Connected |
1 |
3 |
Clear Request/Clear Indication |
1 |
7 |
Clear Confirmation |
2 |
3 |
Interrupt |
2 |
7 |
Interrupt Confirmation |
1 |
B |
Reset Request/Reset Indication |
1 |
F |
Reset Confirmation |
F |
B |
Restart Request/Restart Indication |
F |
F |
Restart Confirmation |
F |
1 |
Diagnostic |
F |
3 |
Registration Request |
F |
7 |
Registration Confirmation |
Following octets depend on the packet type idenitified.
For each packet type, the format of the packet is shown below.
The number above each item in a packet shows the number of bits taken by that item.
Packet items in italics are optional according to CCITT.
Packet items in bold are optional according to ISO/IEC.
Packet items in bold italics are optional in both CCITT and ISO/IEC.
4 | 12 | 8 | 4 | 4 | k*8 | 8 | m*8 | n*8 |
GFI (0Dxx) | LCN | @0B | Calling Address Length | Called Address Length | Called & Calling Addresses | Facility Length (=m) | Facilities | Call User Data |
Call User Data is limited to 16 bytes unless Fast Select is used, when the limit becomes 128 bytes.
CALL ACCEPTED
CALL CONNECTED
4 | 12 | 8 | 4 | 4 | k*8 | 8 | m*8 | n*8 |
GFI (0Dxx) | LCN | @0F | Calling Address Length | Called Address Length | Called & Calling Addresses | Facility Length (=m) | Facilities | Call User Data |
Call User Data is only permitted in conjunction with Fast Select (128 bytes).
CLEAR REQUEST
CLEAR
INDICATION
4 | 12 | 8 | 8 | 8 | 4 | 4 | k*8 | 8 | m*8 | n*8 |
GFI (0Dxx) | LCN | @13 | Clear Cause | Diagnostic Code | Calling Address Length | Called Address Length | Called & Calling Addresses | Facility Length (=m) | Facilities | Call User Data |
The Diagnostic Code is optional in CCITT Clear Request
There should be no
addresses unless CLAM used.
Call User Data is only permitted in conjunction
with Fast Select (128 bytes)
4 | 12 | 8 | 8 | 4 | 4 | k*8 | 8 | m*8 |
GFI (0Dxx) | LCN | @17 | Clear Cause | Calling Address Length | Called Address Length | Called & Calling Addresses | Facility Length (=m) | Facilities |
Address Lengths (and k) = 0.
The only facility permitted is Charging
Information
DATA (modulo 8)
4 | 12 | 3 | 1 | 3 | 1 | n*8 |
GFI (QD01) | LCN | P(R) | M | P(S) | 0 | User Data |
DATA (modulo 128)
4 | 12 | 7 | 1 | 7 | 1 | n*8 |
GFI (QD10) | LCN | P(S) | 0 | P(R) | M | User Data |
4 | 12 | 8 | n*8 |
GFI (00xx) | LCN | @23 | Interrupt User Data |
4 | 12 | 8 |
GFI (00xx) | LCN | @27 |
RECEIVE READY (modulo 8)
4 | 12 | 3 | 5 |
GFI (0001) | LCN | P(R) | 1 |
RECEIVE READY (modulo 128)
4 | 12 | 8 | 7 | 1 |
GFI (0010) | LCN | @01 | P(R) | 0 |
RECEIVE NOT READY (modulo 8)
4 | 12 | 3 | 5 |
GFI (0001) | LCN | P(R) | 5 |
RECEIVE NOT READY (modulo 128)
4 | 12 | 8 | 7 | 1 |
GFI (0010) | LCN | @05 | P(R) | 0 |
RESET REQUEST
RESET
INDICATTON
4 | 12 | 8 | 8 | 8 |
GFI (00xx) | LCN | @1B | Resetting Cause | Diagnostic Code |
The Diagnostic Code is optional in CCITT Reset Request
4 | 12 | 8 |
GFI (00xx) | LCN | @1F |
RESTART REQUEST
RESTART
INDICATTON
4 | 12 | 8 | 8 | 8 |
GFI (00xx) | @000 | @FB | Restarting Cause | Diagnostic Code |
The Diagnostic Code is optional in CCITT Restart Request
4 | 12 | 8 |
GFI (00xx) | @000 | @FF |
4 | 12 | 8 | 8 | k*8 |
GFI (00xx) | @000 | @F1 | Diagnostic Code | Diagnostic Explanation |
REJECT (modulo 8)
4 | 12 | 3 | 5 |
GFI (0001) | LCN | P(R) | 9 |
REJECT (modulo 128)
4 | 12 | 8 | 7 | 1 |
GFI (0010) | LCN | @09 | P(R) | 0 |
4 | 12 | 8 | 4 | 4 | k*8 | 8 | l*8 |
GFI (00xx) | @000 | @F3 | DTE Address Length | DXE Address Length | DXE & DTE Addresses | Registration Length | Registration |
4 | 12 | 8 | 8 | 8 | 4 | 4 | k*8 | 8 | l*8 |
GFI (00xx) | @000 | @F7 | Cause | Diagnostic Code | DTE Address Length | DXE Address Length | DXE & DTE Addresses | Registration Length | Registration |
Code(s) |
Reason |
@00 |
DTE Originated (standard diagnostic code) |
@80 |
DTE Originated (non-standard diagnostic code) |
@01 |
Local Procedure Error |
@03 |
Network Congestion |
@07 |
Network Operational |
@7F |
Registration/Cancellation Confirmed |
REGISTRATION CONFIRMATION CAUSE CODES
Code(s) |
Reason |
@7F |
Registration/Cancellation Confirmed |
@03 |
Invalid Facility Request |
@13 |
Local Procedure Error |
@05 |
Network Congestion |
Code(s) |
Reason |
@00 |
DTE Originated (standard diagnostic code) |
@80 |
DTE Originated (non-standard diagnostic code) |
@01,@81 |
Number Busy |
@09,@89 |
Out Of Order |
@l 1,@91 |
Remote Procedure Error |
@l 9,@99 |
Reverse Charging Acceptance Not Subscribed |
@21,@Al |
Incompatible Destination |
@29,@A9 |
Fast Select Acceptance Not Subscribed |
@39,@B9 |
Ship Absent |
@03,@83 |
Invalid Facility Request |
&0B,@8B |
Access Barred |
@l 3,@93 |
Local Procedure Error |
@05,@85 |
Network Congestion |
@0D,@8D |
Not Obtainable |
@l 5,@95 |
RPOA Out Of Order |
@C1 |
Gateway-detected Procedure Error |
@C3 |
Gateway Congestion |
Where two codes are shown, the higher is generated by private networks.
Code(s) |
Reason |
@00 |
DTE Originated (standard diagnostic code) |
@80 |
DTE Originated (non-standard diagnostic code) |
@01,@81 |
Out Of Order(PVC) |
@03,@83 |
Remote Procedure Error |
@05,@85 |
Local Procedure Error |
@07,@87 |
Network Congestion |
@09,C@89 |
Remote DTE Operational(PVC) |
@0F,@8F |
Network Operational(PVC) |
@l1,@91 |
Incompatible Destination |
@l D,@9D |
Network Out Of Order(PVC) |
@C1 |
Gateway-detected Procedure Error |
@C3 |
Gateway Congestion |
@C7 |
Gateway Operational(PVC) |
Where two codes are shown, the higher is generated by private networks.
Code | Facility |
@06 | Non-negotiable Facilities Values (Conf only) |
@46 | Availability of Facilities (Conf only) |
@45 | Facilities That May Be Negotiated At Any Time |
@05 | Facilities That May Be Negotiated Only When All Logical Channels Used
For Virtual Calls Are In State p1 |
@42 | Nonstandard Default Packet Sizes |
@43 | Nonstandard Default Window Sizes |
@02 | Default Throughput Classes Assignment |
@C8 | Logical Channel Types Ranges |
FACILITY CODES AND THEIR FIELDS
Facilites are in four groupings:
Code | Packet | Facility | Parameter field(s) |
@00 | CX DR DI | Facility Marker | One octet:
|
Facility code @FF is reserved for future extension of the facility
codes.
Code |
Packet | Facility | Parameter field(s) |
@42 |
CX | Flow Control Parameter Negotiation - packet size | Two octets, first from called, second from calling. Values range from @04 (size = 16) to @0C (size = 4096) |
@43 |
CX | Flow Control Parameter Negotiation - window size | Two octets, first from called, second from calling. Values range from @0l (1) to @7F (127) Values of 8 and above are only valid with the Extended Packet Sequence Numbering Facility |
@02 |
CX | Throughput Class Negotiation | One octet = @RO, R = from responder (called) O = from originator (calling). Values range from @03 (75 bps) to @C0 (48000 bps) |
@03 |
CO | Closed User Group Selection - basic format | One octet = BCD encoding of (two digit) index |
@47 |
CO | Closed User Group Selection - extended format | Two octets = BCD encoding of (four digit) index |
@09 |
CO | Closed User Group With Outgoing Access Selection - basic format | One octet = BCD encoding of (two digit) index |
@48 |
CO | Closed User Group With Outgoing Access Selection - extended format | Two octets BCD encoding of (four digit) index |
@41 |
CO | Bilateral Closed User Group Selection | Two octets = BCD encoding of (four digit) index |
@01 |
CO | Fast Select and Reverse Charging | One octet, sum of:
|
@C6 |
CR CA | Network User Identification | First octet = number of octets following which contain the NUI |
@04 |
CR CA | Charging Information - requesting service | One octet, sum of:
|
@C5 @C2 @C1 |
DI DC | Charging Information - indications | First octet = number of octets following which describe the usage of the connection |
@44 |
CR | RPOA Selection - basic format | Two octets containing the BCD encoding of the DNIC for the requested RPOA network |
@C4 |
CR | RPOA Selection - extended format | First octet = number of following octets. The following octets are the BCD encodings of the RPOA networks in the order in which they are to be traversed |
@08 |
CA CC DR DI | Called Line Address Modified Notification | One octet. Value >= @80 if the modification occurred in a private
network. Value mod @80 is one of:
|
@C3 |
CI | Call Redirection Notification | First octet = length of following:
Octet value, one of:
Octet = length of originally-called DTE (=<15) BCD encoding of originally-called DTE address |
@49 |
CO CC | Transit Delay Selection And Indication | Two octets transit delay in milliseconds |
CCITT-Specified DTE facilities
Code | Packets | Facility | Parameter field(s) |
@CB | CO | Calling Address Extension | First octet = length of following:
value of octet:
BCD encoding of address extension |
@C9 | CX DR DI | Called Address Extension | As Calling Address Extension |
@0A | CX | Minimum Throughput Class Negotiation | One octet, @RO (R= from called, O= from calling). Values range from @3 (75 bps) to @C (48000 bps). |
@CA | CX | End-to-End Transit Delay Negotiation | First octet = length of following (=2, 4 or 6)
Two octets = Cumulative Delay The following are not in CA or CC packets. Two octets = Target Delay (optional) Two octets = Maximum Delay (optional) |
@0B | CX | Expedited Data | One octet, sum of: @01 Use expedited data |
Packet Types are coded as follows:
The diagnostic codes are taken from Table 25. Remember that Table 24 tells you when Table 25 has the value you want! In particular, Cause Code @80 when originated by a DTE does not use Table 25 for the Diagnostic Code. Also Diagnostic Codes between 128 and 255 generated by a Public Network are given by Annex E of X.25, rather than those here.
DIAGNOSTIC |
Hex Value |
Decimal Value |
Applicable Packets (Note 1) |
No Additional Information |
@00 |
0 |
D, Rr, C, Re, Rg |
invalid P(S) |
@01 |
1 |
Re |
invalid P(R) |
@02 |
2 |
Re |
Packet Type Invalid |
@10 |
16 |
Rr, C, Re |
Packet Type Invalid for state rl |
@11 |
17 |
Rr, C, Re |
Packet Type Invalid for state r2 |
@12 |
18 |
Rr, C, Re |
Packet Type Invalid for state r3 |
@13 |
19 |
Rr, C, Re |
Packet Type Invalid for state pl |
@14 |
20 |
C |
Packet Type Invalid for state p2 |
@15 |
21 |
C |
Packet Type Invalid for state p3 |
@16 |
22 |
C |
Packet Type Invalid for state p4 |
@17 |
23 |
C |
Packet Type Invalid for state p5 |
@18 |
24 |
C |
Packet Type Invalid for state p6 |
@19 |
25 |
C |
Packet Type Invalid for state p7 |
@1A |
26 |
C |
Packet Type Invalid for state d1 |
@1B |
27 |
Re |
Packet Type Invalid for state d2 |
@1C |
28 |
Re |
Packet Type Invalid for state d3 |
@1D |
29 |
Re |
Packet Not Allowed |
@20 |
32 |
D,Rr,C,Re |
unidentifiable packet |
@21 |
33 |
Rr,C,Re |
call on one-way logical channel |
@22 |
34 |
C |
invalid packet type on a Permanent Virtual Circuit |
@23 |
35 |
Re |
packet on an unassigned logical channel |
@24 |
36 |
D |
REJECT not subscribed to |
@25 |
37 |
Re |
packet too short |
@26 |
38 |
D,Rr,C,Rc,R |
packet too long |
@27 |
39 |
D,Rr,C,Re,R |
invalid General Format Identifier |
@28 |
40 |
D |
Restart or Registration packet with nonzero Logical Channel Identifier |
@29 |
41 |
C,Re |
Packet type not compatible with facility |
@2A |
42 |
C |
unauthorized INTERRUPT CONFIRMATION |
@2B |
43 |
Re |
unauthorized INTERRUPT |
@2C |
44 |
Re |
unauthorized INTERRUPT REJECT |
@2D |
45 |
Re |
Timer Expired |
@30 |
48 |
D,Rr,C,Re |
Timer Expired for INCOMING CALL (or for DTE timer expired for CALL REQUEST) |
@31 |
49 |
C |
Timer Expired for CLEAR INDICATION (or for DTE timer expired or retransmission count surpassed for CLEAR REQUEST) |
@32 |
50 |
D,C |
Timer Expired or RESET INDICATION (or for DTE timer expired or retransmission count surpassed for RESET REQUEST) |
@33 |
51 |
D,C,Re |
Timer Expired for RESTART INDICATION (or for DTE timer expired or retransmission count surpassed for RESTART REQUEST) |
@34 |
52 |
D,Rr,C,Re |
Timer Expired for call deflection |
@35 |
53 |
C |
Call Setup, Call Clearing, or Registration Problem |
@40 |
64 |
C,Rg |
facility/registration code not allowed |
@41 |
65 |
C,Rg |
facility parameter not allowed |
@42 |
66 |
C,Rg |
invalid called DTE address |
@43 |
67 |
C |
invalid calling DTE address |
@44 |
68 |
C |
invalid facility/registrafion length |
@45 |
69 |
C,Rg |
incoming call barred |
@46 |
70 |
C |
no logical channel available |
@47 |
71 |
C |
call collision |
@48 |
72 |
C |
duplicate facility requested |
@49 |
73 |
C,Rg |
nonzero address length |
@4A |
74 |
C,Rg |
nonzero facility length |
@4B |
75 |
C |
facility not provided when expected |
@4C |
76 |
C,Rg |
invalid CCITT-specified DTE facility |
@4D |
77 |
C |
maximum number of call redirections or call deflections exceeded |
@4E |
78 |
C |
Miscellaneous |
@50 |
80 |
Rr,C,Re |
improper cause code from DTE |
@51 |
81 |
D,Rr,C,Re |
nonoctet aligned |
@52 |
82 |
D,Rr,C,Re |
inconsistent Q-bit settings |
@53 |
83 |
Re |
NUI problem |
@54 |
84 |
C |
Not Assigned |
@60 |
96-111 |
|
International Problem |
@70 |
112 |
Rr,C,Re |
remote network problem |
@71 |
113 |
C,Re |
international protocol problem |
@72 |
114 |
C,Re |
international link out of order |
@73 |
115 |
C,Re |
international link busy |
@74 |
116 |
C |
transit network facility problem |
@75 |
117 |
C |
remote network facility problem |
@76 |
118 |
C |
international routing problem |
@77 |
119 |
C |
temporary routing problem |
@78 |
120 |
C |
unknown called DNIC |
@79 |
121 |
C |
maintenance action (Note 5) |
@7A |
122 |
Rr,C,Re |
Reserved for DTE-defined Diagnostic Information |
@80 |
128 |
|
Timer Expired or Retransmission Count Surpassed |
@90 |
144 |
Re |
for INTERRUPT |
@91 |
145 |
Re |
for DATA packet transmission |
@92 |
146 |
Re |
for REJECT |
@93 |
147 |
Re |
DTE-Specific Signals |
@A0 |
160 |
Rr,C,Re |
DTE operational |
@A1 |
161 |
Rr,Re |
DTE not operational |
@A2 |
162 |
Rr,C,Re |
DTE resource constraint |
@A3 |
163 |
Rr,C,Re |
Fast Select not subscribed |
@A4 |
164 |
C |
invalid partially full DATA packet |
@A5 |
165 |
Re |
D-bit procedure not supported |
@A6 |
166 |
C,Re |
Registration/Cancellation confirmed |
@A7 |
167 |
Rg |
Not Assigned |
@B0 |
176-223 |
|
OSI Network Service Problem |
@E0 |
224 |
C,Re |
disconnection (transient condition) |
@E1 |
225 |
C |
disconnection (permanent condition) |
@E2 |
226 |
C |
connection rejection - reason unspecified (transient condition) |
@E3 |
227 |
C |
connection rejection - reason unspecified (permanent condition) |
@E4 |
228 |
C |
connection rejection - quality of service not available (transient condition) |
@E5 |
229 |
C |
connection rejection - quality of service not available (permanent condition) |
@E6 |
230 |
C |
connection rejection - NSAP unreachable (transient condition) |
@E7 |
231 |
C |
connection rejection - NSAP unreachable (permanent condition) |
@E8 |
232 |
C |
reset - reason unspecified |
@E9 |
233 |
Re |
reset - congestion |
@EA |
234 |
Re |
connection rejection - NSAP address unknown (permanent condition) |
@EB |
235 |
C |
Higher Layer Initiated |
@F0 |
240 |
Rr,C,Re |
disconnection-normal |
@F1 |
241 |
C |
disconnection - abnormal |
@F2 |
242 |
C |
disconnection-incompatible information in user data |
@F3 |
243 |
C |
connection rejection - reason unspecified (transient condition) |
@F4 |
244 |
C |
connection rejection - reason unspecified (permanent condition) |
@F5 |
245 |
C |
connection rejection - quality of service not available (transient condition) |
@F6 |
246 |
C |
connection rejection - quality of service not available (permanent condition) |
@F7 |
247 |
C |
connection rejection - incompatible information in user data |
@F8 |
248 |
C |
connection rejection - unrecognizable protocol identifier in user data |
@F9 |
249 |
C |
reset-user resynchronization |
@FA |
250 |
Re |
1 A given diagnostic need not apply to all packet types. The packet type(s) to which each diagnostic may apply is shown (D=DIAGNOSTIC; Rr=RESTART REQUEST and RESTART INDICATION; C=CLEAR REQUEST and CLEAR INDICATION; Re=RESET REQUEST and RESET INDICATION; Rg=REGISTRATTON CONFIRMATION). Since a DTE is permitted to use a "stronger' error action (i.e., restarting the Packet Layer instead of clearing a Virtual Call, and restarting the Packet Layer or clearing a Virtual Call instead of resetting):
a) the applicable packets for diagnostic codes 0-223, when transmitted by a DTE, also include C=RESTART REQUEST, Re=CLEAR REQUEST (Virtual Call only) and RESTART REQUEST;
b) hence, the applicable packets for diagnostic codes 0-223, when received by a DTE, also include C=RESTART INDICATION (DTE/DTE environment only), Re=CLEAR INDICATION (Virtual Call only) and RESTART INDICATION (DTE/DTE environment only).
2 Not all diagnostics need be implemented but those used are as coded in the table. The first diagnostic in each grouping is a generic diagnostic and can be used in place of the more specific diagnostics within the grouping. The decimal 0 diagnostic code can be used in situations where no additional information is available (e.g., where the more specific diagnostics are not implemented).
3 Diagnostics 224 through 255 support the OSI Network Service Definition.
4 In certain situations, multiple diagnostic codes may apply. For example, if a timcr has expired and a (RESTART, CLEAR, or RESET) REQUEST packet is to be retransmitted, then the DTE may use the diagnostic code associated with the original error or the corresponding "timer expired" diagnostic code.
5 This diagnostic may also apply to a maintenance action within a national network.
Last updated: 25 Nov 2002 |
Comments/corrections to: x25@witchfield.fsnet.co.uk |