| Wireshark 4.7.0 The Wireshark network protocol analyzer

Loading...
Searching...
No Matches
packet-ipx.h
1/* packet-ipx.h
2 * Routines for NetWare's IPX
3 * Gilbert Ramirez <gram@alumni.rice.edu>
4 * NDPS support and SPX Defragmentation added by Greg Morris (gmorris@novell.com)
5 *
6 * Portions Copyright (c) by Gilbert Ramirez 2000-2002
7 * Portions Copyright (c) Novell, Inc. 2002-2003
8 *
9 * Wireshark - Network traffic analyzer
10 * By Gerald Combs <gerald@wireshark.org>
11 * Copyright 1998 Gerald Combs
12 *
13 * SPDX-License-Identifier: GPL-2.0-or-later
14 */
15
16/*
17 * ipxlib.h
18 *
19 * Copyright (C) 1995 by Volker Lendecke
20 *
21 */
22
23#ifndef __PACKET_IPX_H__
24#define __PACKET_IPX_H__
25
26#define IPX_NODE_LEN 6
27
28 typedef uint32_t IPXNet;
29 typedef uint16_t IPXPort;
30 typedef uint8_t IPXNode[IPX_NODE_LEN];
31 typedef const uint8_t CIPXNode[IPX_NODE_LEN];
32
33#define IPX_USER_PTYPE (0x00)
34#define IPX_RIP_PTYPE (0x01)
35#define IPX_SAP_PTYPE (0x04)
36#define IPX_AUTO_PORT (0x0000)
37#define IPX_SAP_PORT (0x0452)
38#define IPX_RIP_PORT (0x0453)
39
40#define IPX_SAP_GENERAL_QUERY (0x0001)
41#define IPX_SAP_GENERAL_RESPONSE (0x0002)
42#define IPX_SAP_NEAREST_QUERY (0x0003)
43#define IPX_SAP_NEAREST_RESPONSE (0x0004)
44
45#define IPX_SAP_FILE_SERVER (0x0004)
46
47 struct sap_query
48{
49 uint16_t query_type; /* net order */
50 uint16_t server_type; /* net order */
51};
52
53#define IPX_RIP_REQUEST (0x1)
54#define IPX_RIP_RESPONSE (0x2)
55
56 typedef struct _ipx_rt_def
57{
58 uint32_t network ;
59 uint16_t hops ;
60 uint16_t ticks ;
61} ipx_rt_def_t;
62
63 struct ipx_rip_packet
64{
65 uint16_t operation ;
66 ipx_rt_def_t rt[1] ;
67};
68
69#define IPX_BROADCAST_NODE ("\xff\xff\xff\xff\xff\xff")
70#define IPX_THIS_NODE ("\0\0\0\0\0\0")
71#define IPX_THIS_NET (0)
72
73#ifndef IPX_NODE_LEN
74#define IPX_NODE_LEN (6)
75#endif
76
77/*
78 * From:
79 *
80 * http://alr.base2co.com:457/netguide/dipxD.ipx_packet_struct.html
81 *
82 * which is part of SCO's "Network Programmer's Guide and Reference".
83 *
84 * It calls type 20 "NetBIOS name packet". Microsoft Network Monitor
85 * calls it "WAN Broadcast"; it's also used for SMB browser announcements,
86 * i.e. NetBIOS (broadcast) datagrams.
87 */
88#define IPX_PACKET_TYPE_IPX 0
89#define IPX_PACKET_TYPE_RIP 1
90#define IPX_PACKET_TYPE_ECHO 2
91#define IPX_PACKET_TYPE_ERROR 3
92#define IPX_PACKET_TYPE_PEP 4
93#define IPX_PACKET_TYPE_SPX 5
94#define IPX_PACKET_TYPE_NCP 17
95#define IPX_PACKET_TYPE_WANBCAST 20 /* propagated NetBIOS packet? */
96
97/* info on these sockets can be found in this listing from Novell:
98
99 http://developer.novell.com/engsup/sample/tids/dsoc1b/dsoc1b.htm
100*/
101
102#define IPX_SOCKET_PING_CISCO 0x0002 /* In cisco this is set with: ipx ping-default cisco */
103#define IPX_SOCKET_NCP 0x0451
104#define IPX_SOCKET_SAP 0x0452
105#define IPX_SOCKET_IPXRIP 0x0453
106#define IPX_SOCKET_NETBIOS 0x0455
107#define IPX_SOCKET_DIAGNOSTIC 0x0456
108#define IPX_SOCKET_SERIALIZATION 0x0457
109#define IPX_SOCKET_NWLINK_SMB_SERVER 0x0550
110#define IPX_SOCKET_NWLINK_SMB_NAMEQUERY 0x0551
111#define IPX_SOCKET_NWLINK_SMB_REDIR 0x0552
112#define IPX_SOCKET_NWLINK_SMB_MAILSLOT 0x0553
113#define IPX_SOCKET_NWLINK_SMB_MESSENGER 0x0554
114#define IPX_SOCKET_NWLINK_SMB_BROWSE 0x0555 /* ? not sure on this
115 but I guessed based on the content of the packet I saw */
116#define IPX_SOCKET_ATTACHMATE_GW 0x055d
117#define IPX_SOCKET_IPX_MESSAGE 0x4001
118#define IPX_SOCKET_IPX_MESSAGE1 0x4003
119#define IPX_SOCKET_ADSM 0x8522 /* www.tivoli.com */
120#define IPX_SOCKET_EIGRP 0x85be /* cisco ipx eigrp */
121#define IPX_SOCKET_NLSP 0x9001 /* NetWare Link Services Protocol */
122#define IPX_SOCKET_IPXWAN 0x9004 /* IPX WAN (RFC 1362, NLSP spec) */
123#define IPX_SOCKET_SNMP_AGENT 0x900F /* RFC 1906 */
124#define IPX_SOCKET_SNMP_SINK 0x9010 /* RFC 1906 */
125#define IPX_SOCKET_PING_NOVELL 0x9086 /* In cisco this is set with: ipx ping-default novell */
126#define IPX_SOCKET_TCP_TUNNEL 0x9091 /* RFC 1791 */
127#define IPX_SOCKET_UDP_TUNNEL 0x9092 /* RFC 1791 */
128#define SPX_SOCKET_PA 0x90b2 /* NDPS Printer Agent */
129#define SPX_SOCKET_BROKER 0x90b3 /* NDPS Broker */
130#define SPX_SOCKET_SRS 0x90b4 /* NDPS Service Registry Service */
131#define SPX_SOCKET_ENS 0x90b5 /* NDPS Event Notification Service */
132#define SPX_SOCKET_RMS 0x90b6 /* NDPS Remote Management Service */
133#define SPX_SOCKET_NOTIFY_LISTENER 0x90b7 /* NDPS Notify Listener */
134
135 extern value_string_ext ipx_socket_vals_ext;
136 extern value_string_ext novell_server_vals_ext;
137
138/*
139 * Structure passed to SPX subdissectors, containing information from
140 * the SPX header that might be useful to the subdissector.
141 */
142 typedef struct {
143 bool eom; /* end-of-message flag in SPX header */
144 uint8_t datastream_type; /* datastream type from SPX header */
145} spx_info;
146
147
148
149/* handed off to tap listeners, expand it as is required by what any
150 tap listeners needs */
151 typedef struct _ipxhdr_t
152{
153 uint16_t ipx_ssocket;
154 uint16_t ipx_dsocket;
155 uint16_t ipx_length;
156 uint8_t ipx_type;
157 address ipx_src;
158 address ipx_dst;
159} ipxhdr_t;
160
161
162#endif
_address
Definition address.h:58
_ipx_rt_def
Definition packet-ipx.h:57
_ipxhdr_t
Definition packet-ipx.h:151
_value_string_ext
Extended metadata for a value_string array.
Definition value_string.h:325
ipx_rip_packet
Definition packet-ipx.h:64
sap_query
Definition packet-ipx.h:48
spx_info
Definition packet-ipx.h:141