aboutsummaryrefslogtreecommitdiffstats
path: root/packet-isakmp.c
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2001-11-05 21:36:07 +0000
committerGuy Harris <guy@alum.mit.edu>2001-11-05 21:36:07 +0000
commita968373a7a1f69ce5e895b1ffbbe4a61406938bb (patch)
treed646a163d87a2da10dd178c587bac52518188763 /packet-isakmp.c
parentd5727068bbfd7586122b5637fb05ceaf6cd682d9 (diff)
IPCOMP transformation and ID_IPV4_ADDR_SUBNET for ISAKMP, from
<a.stockmeier[AT]avm.de>. svn path=/trunk/; revision=4162
Diffstat (limited to 'packet-isakmp.c')
-rw-r--r--packet-isakmp.c26
1 files changed, 24 insertions, 2 deletions
diff --git a/packet-isakmp.c b/packet-isakmp.c
index 789d3e5516..9ae6252a7b 100644
--- a/packet-isakmp.c
+++ b/packet-isakmp.c
@@ -4,7 +4,7 @@
* for ISAKMP (RFC 2407)
* Brad Robel-Forrest <brad.robel-forrest@watchguard.com>
*
- * $Id: packet-isakmp.c,v 1.47 2001/10/26 10:30:16 guy Exp $
+ * $Id: packet-isakmp.c,v 1.48 2001/11/05 21:36:06 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
@@ -156,6 +156,18 @@ static const char *esp_transtypestr[NUM_ESP_TRANS_TYPES] = {
"AES"
};
+#define NUM_IPCOMP_TRANS_TYPES 5
+#define ipcomp_trans2str(t) \
+ ((t < NUM_IPCOMP_TRANS_TYPES) ? ipcomp_transtypestr[t] : "UNKNOWN-IPCOMP-TRANS-TYPE")
+
+static const char *ipcomp_transtypestr[NUM_IPCOMP_TRANS_TYPES] = {
+ "RESERVED",
+ "OUI",
+ "DEFLATE",
+ "LZS",
+ "LZJH"
+};
+
#define NUM_ID_TYPES 12
#define id2str(t) \
((t < NUM_ID_TYPES) ? idtypestr[t] : "UNKNOWN-ID-TYPE")
@@ -614,6 +626,11 @@ dissect_transform(tvbuff_t *tvb, int offset, int length, proto_tree *tree,
"Transform ID: %s (%u)",
esp_trans2str(transform_id), transform_id);
break;
+ case 4: /* IPCOMP */
+ proto_tree_add_text(tree, tvb, offset, 1,
+ "Transform ID: %s (%u)",
+ ipcomp_trans2str(transform_id), transform_id);
+ break;
}
offset += 3;
length -= 3;
@@ -706,7 +723,6 @@ dissect_id(tvbuff_t *tvb, int offset, int length, proto_tree *tree,
switch (id_type) {
case 1:
- case 4:
proto_tree_add_text(tree, tvb, offset, length,
"Identification data: %s",
ip_to_str(tvb_get_ptr(tvb, offset, 4)));
@@ -717,6 +733,12 @@ dissect_id(tvbuff_t *tvb, int offset, int length, proto_tree *tree,
"Identification data: %.*s", length,
tvb_get_ptr(tvb, offset, length));
break;
+ case 4:
+ proto_tree_add_text(tree, tvb, offset, length,
+ "Identification data: %s/%s",
+ ip_to_str(tvb_get_ptr(tvb, offset, 4)),
+ ip_to_str(tvb_get_ptr(tvb, offset+4, 4)));
+ break;
default:
proto_tree_add_text(tree, tvb, offset, length, "Identification Data");
break;