"ssn_range" needs to be a copy of "global_ssn_range", so that it's not
[obnox/wireshark/wip.git] / randpkt.c
index 9bc769796ec18bd6a443aa9acd15edc5a2cfe417..d88637215a1746ef90e5aaef58a447b408a9c80e 100644 (file)
--- a/randpkt.c
+++ b/randpkt.c
@@ -4,7 +4,7 @@
  * Creates random packet traces. Useful for debugging sniffers by testing
  * assumptions about the veracity of the data found in the packet.
  *
- * $Id: randpkt.c,v 1.16 2002/10/15 02:29:54 gerald Exp $
+ * $Id$
  *
  * Copyright (C) 1999 by Gilbert Ramirez <gram@alumni.rice.edu>
  *
 #include "config.h"
 #endif
 
+#ifdef NEED_GETOPT_H
+#include "getopt.h"
+#endif
+
 #ifdef HAVE_UNISTD_H
 #include <unistd.h>
 #endif
@@ -64,6 +68,7 @@ enum {
        PKT_NCP2222,
        PKT_GIOP,
        PKT_BGP,
+       PKT_TDS
 };
 
 typedef struct {
@@ -288,7 +293,26 @@ guint8 pkt_bgp[] = {
        0xff, 0xff, 0xff, 0xff,
        0xff, 0xff, 0xff, 0xff,
        0xff, 0xff, 0xff, 0xff,
+};
 
+/* Ethernet+IP+TCP, indicating TDS NetLib */
+guint8 pkt_tds[] = {
+       0x00, 0x50, 0x8b, 0x0d,
+       0x7a, 0xed, 0x00, 0x08,
+       0xa3, 0x98, 0x39, 0x81,
+       0x08, 0x00,
+
+       0x45, 0x00, 0x03, 0x8d,
+       0x90, 0xd4, 0x40, 0x00,
+       0x7c, 0x06, 0xc3, 0x1b,
+       0xac, 0x14, 0x02, 0x22,
+       0x0a, 0xc2, 0xee, 0x82,
+
+       0x05, 0x99, 0x08, 0xf8,
+       0xff, 0x4e, 0x85, 0x46,
+       0xa2, 0xb4, 0x42, 0xaa,
+       0x50, 0x18, 0x3c, 0x28,
+       0x0f, 0xda, 0x00, 0x00,
 };
 
 /* This little data table drives the whole program */
@@ -341,6 +365,9 @@ pkt_example examples[] = {
        { "bgp", "Border Gateway Protocol",
                PKT_BGP,        pkt_bgp,        WTAP_ENCAP_ETHERNET,    array_length(pkt_bgp) },
 
+       { "tds", "TDS NetLib",
+               PKT_TDS,        pkt_tds,        WTAP_ENCAP_ETHERNET,    array_length(pkt_tds) },
+
 };