summaryrefslogtreecommitdiff
path: root/print-l2tp.c
Commit message (Collapse)AuthorAgeFilesLines
* Just use a u_char * to go through the packet data; don't try to beGuy Harris2009-08-181-18/+23
| | | | | clever and use a u_int16_t * - the generated code will be the same, and this code works even if the Offset Size field value is odd.
* remove redundant TRUE|FALSE defshannes2006-06-231-9/+1
|
* If the length is specified, check to make sure it doesn't go past theguy2005-04-201-1/+16
| | | | | | end of the packet, and isn't shorter than the header length. Control messages have to have lengths.
* Get rid of an unused variable.guy2005-04-201-6/+4
|
* Check to make sure the length of an AVP is large enough to include theguy2003-12-261-3/+12
| | | | AVP header and doesn't go past the remaining length of the packet.
* Have the configure script arrange that the Makefile define _U_guy2003-11-161-4/+4
| | | | | | | | | | appropriately, and that GNUmakefile and the MSVC++ project file define it apppriately, as we do with libpcap, rather than defining it in "interface.h". Undo the rcsid-shuffling and addition of extra #includes, as we no longer need to arrange that "interface.h" be included before using _U_ in an RCS ID or copyright.
* From Neil Spring:guy2003-11-151-4/+4
| | | | | | | | | | | use "_U_" in the definitions of "rcsid[]", to eliminate complaints about those variables being unused; move the definitions after the include of "interface.h", or add an include of "interface.h", so that "_U_" is defined. Include "config.h" before including "tcpdump-stdinc.h" in "missing/datalinks.c".
* Add a few more GCC warnings on GCC >= 2 for ".devel" builds.guy2002-09-051-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | From Neil T. Spring: fixes for many of those warnings: addrtoname.c, configure.in: Linux needs netinet/ether.h for ether_ntohost print-*.c: change char *foo = "bar" to const char *foo = "bar" to appease -Wwrite-strings; should affect no run-time behavior. print-*.c: make some variables unsigned. print-bgp.c: plen ('prefix len') is unsigned, no reason to validate by comparing to zero. print-cnfp.c, print-rx.c: use intoa, provided by addrtoname, instead of inet_ntoa. print-domain.c: unsigned int l; (l=foo()) < 0 is guaranteed to be false, so check for (u_int)-1, which represents failure, explicitly. print-isakmp.c: complete initialization of attrmap objects. print-lwres.c: "if(x); print foo;" seemed much more likely to be intended to be "if(x) { print foo; }". print-smb.c: complete initialization of some structures. In addition, add some fixes for the signed vs. unsigned comparison warnings: extract.h: cast the result of the byte-extraction-and-combining, as, at least for the 16-bit version, C's integral promotions will turn "u_int16_t" into "int" if there are other "int"s nearby. print-*.c: make some more variables unsigned, or add casts to an unsigned type of signed values known not to be negative, or add casts to "int" of unsigned values known to fit in an "int", and make other changes needed to handle the aforementioned variables now being unsigned. print-isakmp.c: clean up the handling of error/status indicators in notify messages. print-ppp.c: get rid of a check that an unsigned quantity is >= 0. print-radius.c: clean up some of the bounds checking. print-smb.c: extract the word count into a "u_int" to avoid the aforementioned problems with C's integral promotions. print-snmp.c: change a check that an unsigned variable is >= 0 to a check that it's != 0. Also, fix some formats to use "%u" rather than "%d" for unsigned quantities.
* Added support for Win32, based on WinPcap.risso2002-08-011-5/+3
|
* whitespace cleanupitojun2002-06-111-25/+25
|
* From Rick Watson <watsonrick@users.sourceforge.net>: useguy2002-05-251-57/+60
| | | | | unaligned-extraction macros to fetch 16-bit and 32-bit big-endian quantities.
* Squelch a compiler warning.guy2001-11-101-2/+2
|
* L2TP dissector changes, from Motonori Shindo:guy2001-11-051-390/+370
| | | | | | | | | o completely TCHECK()-ified o PPP disconnect cause info AVP support added (RFC3145) o use u_int16_t/u_int32_t instead of u_short/u_int o use tok2str() to better support discrete array o fixed bug (Authen Name AVP is now decoded as a string) o code clean up
* more detailed output in ppp/pppoe/l2tp.itojun2000-08-181-6/+2
| | | | From: Motonori Shindo <mshindo@mshindo.net>
* updates/bug fixes from Motonori Shindo <mshindo@mshindo.net>assar2000-07-011-17/+24
|
* * print-rt6.c: make IPv6 routing header printing work with new 2292bisitojun1999-12-221-13/+19
| | | | | | | | | | | API. * print-bgp.c: improve options printing. ugly code exists for unaligned option parsing (need some fix). * const poisoning in SMB decoder. * make dump format back to original. someone may want to add an option to do ascii printing, but keep the default behavior as is for scripts used in many places. * -Wall -Werror clean checks.
* Include stdio.h and fix up printf formats.fenner1999-12-151-3/+4
|
* Switch to config.h instead of passing defines in DEFS.fenner1999-11-211-1/+5
|
* fixes to make ansi-pedantic compilers happier. no char types for bit fields ↵assar1999-11-171-3/+3
| | | | and minor type correctness
* HP-UX 10.20 build fix <http://www.sics.se/~assar/tcpdump_patches/13>itojun1999-10-301-1/+3
| | | | #ifdef h_errno, snprintf -> sprintf, arpa/inet.h for [hn]to[hn][sl]
* Bring in KAME IPv6 tcpdump. replaces esp/ah/isakmp decoder.itojun1999-10-301-0/+703
Hope I did not break anything. Portability on IPv4-only node needs checking, I'll do this very soon. (sorry for rather jumbo commit) XXx what is _FAVOR_BSD?