I have a patch that solves one problem, but am not familiar enough
with tcpdump/libpcap to be sure it's the Right Way to make the fix.

This pertains to SBE (formerly Lan Media) LMC5245P and LMC1200P cards,
running any recent (<= 6 mos old) OpenBSD and NetBSD, These are DS-3
and DS-1 interfaces with integrated CSU/DSU, based on the DEC tulip
chip.

When connected to a line using Cisco HDLC, running tcpdump on the lmc
interface works if no filter is specified, but gives no output if any
filter expression at all is used. Similarly, you can dump to a file
with no filter; then if you do tcpdump with filter offline on the
file, there will be no output.


What follows is based on the CVS daily snaps from yesterday for
tcpdump and libpcap.

Examining the dumpfile shows it is written with a linktype in the file
header of 0x32, or LINKTYPE_PPP_HDLC, which is mapped to
DLT_PPP_SERIAL. Packets are recorded with the usual 16-byte pcap
header, followed by a 4-byte Cisco HDLC header, then the IP packet.

Tcpdump filters seem to work if gencode.c is changed as follows in the
libpcap code:


*** gencode.c.orig      Mon Feb 26 04:18:04 2001
--- gencode.c   Mon Feb 26 04:18:15 2001
***************
*** 1145,1153 ****
                 */
                switch (proto) {
  
                case ETHERTYPE_IP:
!                       proto = PPP_IP;                 /* XXX was 0x21 */
                        break;
  
  #ifdef INET6
                case ETHERTYPE_IPV6:
--- 1145,1153 ----
                 */
                switch (proto) {
  
                case ETHERTYPE_IP:
!                       return gen_true();              /* always true */
                        break;
  
  #ifdef INET6
                case ETHERTYPE_IPV6:


Does this look right?
-
This is the TCPDUMP workers list. It is archived at
http://www.tcpdump.org/lists/workers/index.html
To unsubscribe use mailto:[EMAIL PROTECTED]?body=unsubscribe

Reply via email to