aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-ipsec.c
AgeCommit message (Collapse)AuthorFilesLines
2007-11-27strcasecmp(), strncasecmp(), g_strcasecmp(), and g_strncasecmp() delendaGuy Harris1-2/+6
est. Use g_ascii_strcasecmp() and g_ascii_strncasecmp(), and supply our own versions if they're missing from GLib (as is the case with GLib 1.x). In the code to build the list of named fields for Diameter, don't use g_strdown(); do our own g_ascii_-style upper-case to lower-case mapping in the hash function and use g_ascii_strcasecmp() in the compare function. We do this because there is no guarantee that toupper(), tolower(), and functions that use them will, for example, map between "I" and "i" in all locales; in Turkish locales, for example, there are, in both upper case and lower case, versions of "i" with and without a dot, and the upper-case version of "i" is "I"-with-a-dot and the lower-case version of "I" is "i"-without-a-dot. This causes strings that should match not to match. This finishes fixing bug 2010 - an earlier checkin prevented the crash (as there are other ways to produce the same crash, e.g. a bogus dictionary.xml file), but didn't fix the case-insensitive string matching. svn path=/trunk/; revision=23623
2007-11-08Apply yet another set of the optimization patches:Anders Broman1-2/+2
When offset parameter is 0 replace tvb_bytes_exist() with the faster tvb_length(). non heuristic dissectors svn path=/trunk/; revision=23405
2007-07-11Move packet-ipsec.c to CLEAN_DISSECTOR_SRC.Gerald Combs1-6/+6
svn path=/trunk/; revision=22287
2007-04-25The data field of an address structure is now a void *; convert it asGuy Harris1-12/+18
appropriate. svn path=/trunk/; revision=21566
2007-04-14fix MacOSX gcc-3.3 warnings about unused tfs/value_string variablesSebastien Tandel1-3/+3
most have been tagged unused (few have been deleted if dissector has not been modified since a long time) move packet-ssl-utils.c to DISSECTOR_SRC svn path=/trunk/; revision=21431
2007-04-13Fix a mis-labeled field reported in Ethereal bug 1101. Update allGerald Combs1-47/+47
of the short descriptions and fill in all of the long descriptions. Fix up whitespace. svn path=/trunk/; revision=21401
2006-10-27When key length wrong, show expected value.Martin Mathieson1-9/+13
Fix Preference label where %d was missing from specifier. svn path=/trunk/; revision=19714
2006-10-10Simplify the preference string allocation code. Shorten the comments,Gerald Combs1-90/+70
which (as Ulf pointed out) reduces the size of the prefs file significantly. svn path=/trunk/; revision=19486
2006-09-12put the ah and esp payload as its own top level expansion in the tree ↵Ronnie Sahlberg1-3/+3
instead of as an expansion inside the ah/esp layer. since source/dest/protocol/info is updated by the content of the payload it doesnt make sense to hide the actual payload inside esp/ah it just would look confusing svn path=/trunk/; revision=19206
2006-09-12prettify dissection of ESPRonnie Sahlberg1-9/+24
show the IV as a hexadecimal show the protocol name for the Next header field inside ESP svn path=/trunk/; revision=19204
2006-09-08From Frédéric Roudaut:Anders Broman1-42/+125
as requested here is a patch in order to take into account Encryption and Authentication keys for ESP in hexa. You only have to write your key with 0x first. In this case if the key is not in 8-bit unit, it will be considered as starting with a "0" (4 bits). Excepted this case, the key should be completely written, even if it starts with "0x00". svn path=/trunk/; revision=19181
2006-08-18Fix two remaining off-by-one errors. Remove a static buffer.Gerald Combs1-29/+19
svn path=/trunk/; revision=18943
2006-08-15Fix CIDs 204 - 208.Gerald Combs1-24/+31
svn path=/trunk/; revision=18915
2006-08-14Put protocol preferences in a scrolled window, in case a particularGerald Combs1-1/+1
protocol has a lot of preference items. Change the number of configurable ESP SAs to 16 (in case someone needs do decrypt many sessions in a single trace file). Fix up whitespace. svn path=/trunk/; revision=18903
2006-08-09Point to the newest (1.5.0-1) GnuTLS package. Since it containsGerald Combs1-557/+563
libgcrypt, enable it in the Windows build. In packet-ipsec.c: - Remove non-constants from variable declaration initializations. - Use ep_alloc() in a couple of places. - Fix an off-by-one error. - Reduce the number of SAs in the preferences from 4 to 2. 4 made the preferences window absolutely enormous. This is probably the wrong way to fix this. - Fix up whitespace. svn path=/trunk/; revision=18856
2006-06-14configure.in:Jörg Mayer1-68/+70
Check for libgcrypt 1.1.0 (note: I don't know which version is required, so maybe the version number needs to be changed for this test to work reliably). packet-ipsec.c: - Replace __USE_LIBGCRYPT__ by HAVE_LIBGCRYPT to follow conventions. - Warning fixes: signedness in sscanf (%i -> %u) - Warning fixes: mixed declaration and code svn path=/trunk/; revision=18460
2006-05-21change a whole bunch of ethereal into wiresharkRonnie Sahlberg1-2/+2
svn path=/trunk/; revision=18196
2006-05-02Do the ESP payload decoding, and pass it to the subdissector, regardlessGuy Harris1-672/+713
of whether we're building a protocol tree or not - you have to call subdissectors in either case. svn path=/trunk/; revision=18078
2006-04-13From Frederic Roudaut:Anders Broman1-471/+705
I updated my previous patch of ESP : * It now check authentication for (similar to the ICMP checksum): - NULL Authentication - HMAC-SHA1-96 [RFC2404] - HMAC-SHA256 - HMAC-MD5-96 [RFC2403] (2) I put aside AES-XCBC-MAC-96 [RFC3566] because I did not succeed to have a working implementation. I added a field for any authenticator of 12bytes length (without authentication process) * I also correct the printing of this authenticator field which was decrypted :-[ . Thus, with this patch if libgcrypt is linked withe ethereal you should have the availability to : - decrypt packets - check authentication at the same time or not. If noone of these options are set (or libgcrypt is not available) you also may use the previous heuristic. svn path=/trunk/; revision=17858
2006-03-27Some compilers do not handle very long lines...Luis Ontanon1-4/+20
Shouldn't this preference description be somewhere else? svn path=/trunk/; revision=17748
2006-03-27From Frederic Roudaut:Anders Broman1-244/+2175
With a change : #ifdef HAVE_LIBCRYPT #define __USE_LIBGCRYPT__ #endif >> > finally, I have updated my dissector using libgcrypt. >> > It does not use openssl anymore. >> > If gnutls is installed, all should work. >> > Thus, now it should decrypt and dissect (transport/tunnel/several >> > encapsulations ...) : >> > >> > - NULL Encryption Algorithm >> > - TripleDES-CBC [RFC2451] : keylen 192 bits. >> > - AES-CBC with 128-bit keys [RFC3602] : keylen 128 and 192/256 >> > bits. >> > - AES-CTR [RFC3686] : keylen 160/224/288 bits. The remaining >> > 32 bits will be used as nonce. >> > - DES-CBC [RFC2405] : keylen 64 bits >> > >> > I also have added : >> > >> > - BLOWFISH-CBC : keylen 128 bits. >> > - TWOFISH-CBC : keylen 128/256 bits. >> > >> > You have to indicate the Authentication algorithm even if all >> > Algorithms since it uses 12 bytes in the Auth field should work >> > (have a look to the README to understand why I put it >> > ;-) ). If you consider I have to throw it away please tell me. >> > >> > HMAC-SHA1-96 [RFC2404] >> > NULL >> > AES-XCBC-MAC-96 [RFC3566] >> > HMAC-MD5-96 [RFC2403] svn path=/trunk/; revision=17734
2005-06-26Get rid of the private "my_match_strval()" routine in many dissectors;Guy Harris1-1/+1
add a "match_strval_idx()" routine that does the same thing, and have "match_strval()" call it. Make those routines, and "val_to_str()", return a "const" pointer. Update dissectors as necessary to squelch compiler warnings produced by that. Use "val_to_str()" rather than using "match_strval()" and then, if the result is null, substituting a specific string. Clean up some other "match_strval()"/"val_to_str()" usages. Add a null pointer check in the NDPS dissector's "attribute_value()" routine, as it's not clear that "global_attribute_name" won't be null at that point. Make some global variables in the AFS4INT dissector local. Make some routines not used outside the module they're in static. Make some tables "static const". Clean up white space. Fix Gerald's address in some files. svn path=/trunk/; revision=14786
2005-03-25bugfix: prevent a negative length, if ah.ah_len is zeroUlf Lamping1-1/+1
svn path=/trunk/; revision=13902
2004-12-25a lot of warnings removed, most of them about pointer to int casts without ↵Ulf Lamping1-1/+1
using the appropriate GLib macros svn path=/trunk/; revision=12832
2004-11-12From Mark Phillips: optionally support decoding the payload of ESPGuy Harris1-3/+74
packets using null encryption (with a heuristic to detect null encryption). svn path=/trunk/; revision=12513
2004-09-29Move various tables into the epan directory.Guy Harris1-1/+1
svn path=/trunk/; revision=12130
2004-09-27Move prefs.c and prefs.h into the epan subdirectory.Guy Harris1-1/+1
svn path=/trunk/; revision=12115
2004-08-06From Albert Chin: rename resolv.{ch} to addr_resolv.{ch}, so that anGuy Harris1-1/+1
include of <resolv.h> in any system header file gets the system <resolv.h> (needed for builds on Tru64 with GTK+ 1.2[.x]). svn path=/trunk/; revision=11615
2004-07-18Move dissectors to epan/dissectors directory.Gilbert Ramirez1-0/+359
Also move ncp222.py, x11-fields, process-x11-fields.pl, make-reg-dotc, and make-reg-dotc.py. Adjust #include lines in files that include packet-*.h files. svn path=/trunk/; revision=11410