Ethereal-users: Re: [ethereal-users] Capturing on Linux ATM interfaces

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Guy Harris <gharris@xxxxxxxxxxxx>
Date: Sun, 20 Aug 2000 21:09:21 -0700
Try applying the following patch, and building Ethereal using whatever
version of libpcap makes it capable of seeing the ATM interfaces.
Index: wiretap/libpcap.c
===================================================================
RCS file: /usr/local/cvsroot/ethereal/wiretap/libpcap.c,v
retrieving revision 1.37
diff -c -r1.37 wiretap/libpcap.c
*** libpcap.c	2000/07/30 16:54:11	1.37
--- libpcap.c	2000/08/21 04:07:17
***************
*** 82,113 ****
  #else
  	WTAP_ENCAP_FDDI,
  #endif
! 	WTAP_ENCAP_ATM_RFC1483,	/* or, on BSD/OS, Frame Relay */
! 	WTAP_ENCAP_RAW_IP,	/* or, on OpenBSD, DLT_LOOP, and on BSD/OS,
  				   Cisco HDLC */
! 	WTAP_ENCAP_UNKNOWN,	/* In LBL BPF and FreeBSD, BSD/OS SLIP;
! 				   on OpenBSD, DLT_ENC; on BSD/OS,
! 				   DLT_ATM_RFC1483 */
! 	WTAP_ENCAP_UNKNOWN,	/* In LBL BPF and FreeBSD, BSD/OS PPP;
! 				   on OpenBSD and BSD/OS, DLT_RAW */
! 	WTAP_ENCAP_UNKNOWN,	/* In OpenBSD and BSD/OS, BSD/OS SLIP,
! 				   but the BSD/OS header says "internal
! 				   to libpcap", whatever that means;
! 				   in Linux with the ISDN4Linux patches
  				   applied to libpcap, DLT_I4L_RAWIP,
  				   which looks just like DLT_RAW but
  				   is given a different DLT_ code for
! 				   no obvious good reason */
! 	WTAP_ENCAP_UNKNOWN,	/* In OpenBSD and BSD/OS, BSD/OS PPP,
! 				   but the BSD/OS header says "internal
! 				   to libpcap", whatever that means;
! 				   in Linux with the ISDN4Linux patches
  				   applied to libpcap, DLT_I4L_IP,
  				   which provides only a 2-octet
  				   Ethernet type as a link-layer header,
  				   with a type of 0xFFFF meaning
  				   ETH_P_802_3, a "Dummy type for 802.3
! 				   frames" */
  	WTAP_ENCAP_UNKNOWN,
  	WTAP_ENCAP_UNKNOWN,
  	WTAP_ENCAP_LINUX_ATM_CLIP
--- 82,141 ----
  #else
  	WTAP_ENCAP_FDDI,
  #endif
! 	WTAP_ENCAP_ATM_RFC1483,	/* or, in BSD/OS, Frame Relay */
! 	WTAP_ENCAP_RAW_IP,	/* or, in OpenBSD, DLT_LOOP, and in BSD/OS,
  				   Cisco HDLC */
! 	WTAP_ENCAP_UNKNOWN,	/* In LBL BPF, FreeBSD, and NetBSD, BSD/OS
! 				   SLIP, but I don't think any systems
! 				   other than BSD/OS produce DLT_SLIP_BSDOS,
! 				   and BSD/OS uses 15 for it.
! 
! 				   In OpenBSD, DLT_ENC; on BSD/OS,
! 				   DLT_ATM_RFC1483. */
! 	WTAP_ENCAP_UNKNOWN,	/* In LBL BPF, FreeBSD, and NetBSD, BSD/OS
! 				   PPP, but I don't think any systems
! 				   other than BSD/OS produce DLT_PPP_BSDOS,
! 				   and BSD/OS uses 16 for it.
! 
! 				   In OpenBSD and BSD/OS, DLT_RAW, but I
! 				   don't think any BSDs generate DLT_RAW.
! 
! 				   I.e., I don't think this value is ever
! 				   generated. */
! 	WTAP_ENCAP_UNKNOWN,	/* In OpenBSD and BSD/OS, BSD/OS SLIP.
! 
! 				   In Linux with the ISDN4Linux patches
  				   applied to libpcap, DLT_I4L_RAWIP,
  				   which looks just like DLT_RAW but
  				   is given a different DLT_ code for
! 				   no obvious good reason.
! 
! 				   In Linux with the Kuznetzov patches
! 				   applied to libpcap, DLT_LANE8023,
! 				   which appears to have a 2-byte LANE
! 				   header followed by an Ethernet header. */
! 	WTAP_ENCAP_LINUX_ATM_CLIP, /* In OpenBSD and BSD/OS, BSD/OS PPP.
! 
! 				   In Linux with the ISDN4Linux patches
  				   applied to libpcap, DLT_I4L_IP,
  				   which provides only a 2-octet
  				   Ethernet type as a link-layer header,
  				   with a type of 0xFFFF meaning
  				   ETH_P_802_3, a "Dummy type for 802.3
! 				   frames".
! 
! 				   In Linux with the Kuznetzov patches
! 				   applied to libpcap, DLT_CIP, which
! 				   appears to be the same as DLT_ATM_CLIP,
! 				   which should be mapped to
! 				   WTAP_ENCAP_LINUX_ATM_CLIP.
! 
! 				   For now, we map it to
! 				   WTAP_ENCAP_LINUX_ATM_CLIP, as we don't
! 				   support the other encapsulations.
! 				   Once we do, we may have to throw in
! 				   The Usual Heuristics to figure out
! 				   what we've been handed. */
  	WTAP_ENCAP_UNKNOWN,
  	WTAP_ENCAP_UNKNOWN,
  	WTAP_ENCAP_LINUX_ATM_CLIP