]> The Tcpdump Group git mirrors - libpcap/commitdiff
Give more details for the _WITH_DIR types.
authorGuy Harris <[email protected]>
Tue, 25 Sep 2018 20:59:06 +0000 (13:59 -0700)
committerGuy Harris <[email protected]>
Tue, 25 Sep 2018 20:59:06 +0000 (13:59 -0700)
The original request just spoke of "sent by this host" and "received by
this host"; for X.25 LAPB and Frame Relay LAPF, "this host" is probably
a piece of Data Terminal Equipment rather than Data Communications
Equipment, so we treat "sent by this host" as DTE->DCE and "received by
this host" as DCE->DTE.

pcap-common.c
pcap/dlt.h

index 12ed4dbb03e93e6fa728aa1a6ae52c4ecbb5e176..8b7ffa5264823c648127973d0d2cb5dfb385a2ad 100644 (file)
  */
 #define LINKTYPE_LAPD          203
 
+
 /*
- * Variants of various link-layer headers, with a one-byte direction
- * pseudo-header prepended - zero means "received by this host",
- * non-zero (any non-zero value) means "sent by this host" - as per
- * Will Barker <[email protected]>.
+ * PPP, with a one-byte direction pseudo-header prepended - zero means
+ * "received by this host", non-zero (any non-zero value) means "sent by
+ * this host" - as per Will Barker <[email protected]>.
+ */
+#define LINKTYPE_PPP_WITH_DIR  204     /* Don't confuse with LINKTYPE_PPP_PPPD */
+
+/*
+ * Cisco HDLC, with a one-byte direction pseudo-header prepended - zero
+ * means "received by this host", non-zero (any non-zero value) means
+ * "sent by this host" - as per Will Barker <[email protected]>.
  */
-#define LINKTYPE_PPP_WITH_DIR  204     /* PPP */
 #define LINKTYPE_C_HDLC_WITH_DIR 205   /* Cisco HDLC */
+
+/*
+ * Frame Relay, with a one-byte direction pseudo-header prepended - zero
+ * means "received by this host" (DCE -> DTE), non-zero (any non-zero
+ * value) means "sent by this host" (DTE -> DCE) - as per Will Barker
+ */
 #define LINKTYPE_FRELAY_WITH_DIR 206   /* Frame Relay */
+
+/*
+ * LAPB, with a one-byte direction pseudo-header prepended - zero means
+ * "received by this host" (DCE -> DTE), non-zero (any non-zero value)
+ * means "sent by this host" (DTE -> DCE)- as per Will Barker
+ */
 #define LINKTYPE_LAPB_WITH_DIR 207     /* LAPB */
 
 /*
index 4ed32b972394672dcf6aaa342a0e6cdafc14ae9e..324d4a5d834a071cfad5f1f32d632a79a9a7ef38 100644 (file)
 #define DLT_LAPD               203
 
 /*
- * Variants of various link-layer headers, with a one-byte direction
- * pseudo-header prepended - zero means "received by this host",
- * non-zero (any non-zero value) means "sent by this host" - as per
- * Will Barker <[email protected]>.
- */
-#define DLT_PPP_WITH_DIR       204     /* PPP - don't confuse with DLT_PPP_WITH_DIRECTION */
-#define DLT_C_HDLC_WITH_DIR    205     /* Cisco HDLC */
-#define DLT_FRELAY_WITH_DIR    206     /* Frame Relay */
-#define DLT_LAPB_WITH_DIR      207     /* LAPB */
+ * PPP, with a one-byte direction pseudo-header prepended - zero means
+ * "received by this host", non-zero (any non-zero value) means "sent by
+ * this host" - as per Will Barker <[email protected]>.
+ */
+#define DLT_PPP_WITH_DIR       204     /* Don't confuse with DLT_PPP_WITH_DIRECTION */
+
+/*
+ * Cisco HDLC, with a one-byte direction pseudo-header prepended - zero
+ * means "received by this host", non-zero (any non-zero value) means
+ * "sent by this host" - as per Will Barker <[email protected]>.
+ */
+#define DLT_C_HDLC_WITH_DIR    205
+
+/*
+ * Frame Relay, with a one-byte direction pseudo-header prepended - zero
+ * means "received by this host" (DCE -> DTE), non-zero (any non-zero
+ * value) means "sent by this host" (DTE -> DCE) - as per Will Barker
+ */
+#define DLT_FRELAY_WITH_DIR    206
+
+/*
+ * LAPB, with a one-byte direction pseudo-header prepended - zero means
+ * "received by this host" (DCE -> DTE), non-zero (any non-zero value)
+ * means "sent by this host" (DTE -> DCE)- as per Will Barker
+ */
+#define DLT_LAPB_WITH_DIR      207
 
 /*
  * 208 is reserved for an as-yet-unspecified proprietary link-layer