summaryrefslogtreecommitdiff
path: root/print-eigrp.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix spaces before tabs in indentationFrancois-Xavier Le Bail2023-02-151-1/+1
|
* EIGRP: Modernize packet parsing style.Denis Ovsienko2021-01-101-27/+22
| | | | | | | | Enable ND_LONGJMP_FROM_TCHECK. Report invalid packets as invalid. Remove two redundant ND_TCHECK_*() instances. When giving up on a packet for whatever reason, test that the rest of it is within the buffer. Do the header length check before accessing any header data and refine the TLV length checks. Update a test.
* EIGRP: Get the packet header fields right.Denis Ovsienko2021-01-091-5/+9
| | | | | | | In the spec the packet diagram instead of a 32-bit AS number shows a 16-bit virtual router ID followed by a 16-bit AS number, implement that. Also add two missing flag values and use bittok2str() to print the bitmask. Lose a stale comment and update some tests.
* EIGRP: Use %zu to print sizeof valuesFrancois-Xavier Le Bail2020-11-031-20/+20
|
* Use the Wayback Machine for some removed documentsFrancois-Xavier Le Bail2020-02-061-1/+1
|
* More bounds checking when fetching addresses and converting to strings.Guy Harris2020-01-191-5/+5
| | | | | | | | | | | | | | Replace more calls to ipaddr_string()/ip6addr_string() with calls to GET_IPADDR_STRING()/GET_IP6ADDR_STRING() macros performing bounds checking. Add similar bounds-checking inline functions and macros to wrap linkaddr_string(), etheraddr_string(), and isonsap_string() and convert calls to them to use the macros as well. Shuffle the inline functions in addrtoname.h around a bit, so that the inline functions, external declarations, and macros are all in the same order.
* EIGRP: Use GET_CPY_BYTES to do bounds checkingFrancois-Xavier Le Bail2019-09-101-4/+2
|
* EIGRP: Add two missing bounds checksFrancois-Xavier Le Bail2019-04-281-0/+2
|
* Use the new GET_ macros instead of the EXTRACT_ onesFrancois-Xavier Le Bail2019-03-261-76/+77
| | | | | | | The exceptions are currently: Some EXTRACT_ in print-juniper.c, not used on packet buffer pointer. An EXTRACT_BE_U_3 in addrtoname.c, not always used on packet buffer pointer.
* Print truncations with nd_print_trunc() instead of tstr[] stringsFrancois-Xavier Le Bail2018-05-041-2/+1
| | | | | | | | Remove the tstr[] strings. Update the output of some tests accordingly. Moreover: Add or update some ndo_protocol fields.
* Add the ndo_protocol field in the netdissect_options structureFrancois-Xavier Le Bail2018-03-161-0/+1
| | | | | Update this field in printer entry functions. It will be used for some printings.
* Add and use tstr[]Francois-Xavier Le Bail2018-02-131-1/+3
| | | | Update the output of some tests accordingly.
* Remove unneeded '&' when getting a pointer to a nd_ipv4 typeFrancois-Xavier Le Bail2018-01-311-3/+5
|
* Always include <config.h> rather than "config.h".Guy Harris2018-01-211-1/+1
| | | | | | | | This can prevent bizarre failures if, for example, you've done a configuration in the top-level source directory, leaving behind one config.h file, and then do an out-of-tree build in another directory, with different configuration options. This way, we always pick up the same config.h, in the build directory.
* Use quoted include netdissect-stdinc.h instead of angle-bracketed oneFrancois-Xavier Le Bail2018-01-211-1/+1
|
* Update ND_PRINT() as a variadic macroFrancois-Xavier Le Bail2018-01-071-64/+64
|
* Use ND_TTEST_SIZE()/ND_TCHECK_SIZE() macros (1/n)Francois-Xavier Le Bail2018-01-031-1/+1
|
* Use nd_ types, add EXTRACT_ calls.Guy Harris2017-12-301-151/+152
|
* Remove all storage class specifier 'register'Francois-Xavier Le Bail2017-12-131-1/+1
| | | | | | Let the compiler do the optimizations (or not) based on build options. Avoid 'value has been optimized out' messages in gdb using '-O0'.
* Replace ND_TTEST2()/ND_TCHECK2() macros by macros using pointers (1/n)Francois-Xavier Le Bail2017-12-111-2/+2
| | | | | ND_TTEST2(var, l) -> ND_TTEST_LEN(p, l) ND_TCHECK2(var, l) -> ND_TCHECK_LEN(p, l)
* Rename EXTRACT_ macrosFrancois-Xavier Le Bail2017-11-221-42/+42
| | | | | | | | | | | | | | | | Now all the macros have a name meaning a count in bytes. With _S_: signed, _U_: unsigned e.g.: EXTRACT_BE_32BITS -> EXTRACT_BE_U_4 EXTRACT_LE_32BITS -> EXTRACT_LE_U_4 ... EXTRACT_BE_INT32 -> EXTRACT_BE_S_4 and have: EXTRACT_8BITS -> EXTRACT_U_1 EXTRACT_INT8 -> EXTRACT_S_1
* Rename EXTRACT_nBITS() macros to EXTRACT_BE_nBITS()Francois-Xavier Le Bail2017-11-181-42/+42
| | | | | It indicates clearly that these macros are used to extract big-endian integral values.
* Don't specify struct as "const" within sizeof().Denis Ovsienko2017-09-131-1/+1
| | | | | The only difference the const qualifier makes in this context is visual, make it consistent with the rest of the source code.
* CVE-2017-12901/EIGRP: Do more length checks.Guy Harris2017-09-131-0/+47
| | | | | | | This fixes a buffer over-read discovered by Forcepoint's security researchers Otto Airamo & Antti Levomäki. Add a test using the capture file supplied by the reporter(s).
* zero change: update Hannes Gredler's emailHannes Gredler2017-07-281-1/+1
|
* Add a summary comment in all other printersFrancois-Xavier Le Bail2016-08-151-0/+2
| | | | | | | Moreover: Remove some redundant comments Update some summary comments Update the specification URL for ATA over Ethernet (AoE) protocol
* Rename 'tcpdump-stdinc.h' to 'netdissect-stdinc.h'Francois-Xavier Le Bail2015-09-101-1/+1
| | | | Get the full log via: git log --follow netdissect-stdinc.h
* Printers must include 'netdissect.h', not 'interface.h'Francois-Xavier Le Bail2015-09-051-1/+1
|
* dismiss NETDISSECT_REWORKED macroDenis Ovsienko2015-03-221-1/+0
| | | | | | | The purpose of this macro was to enable the file-by-file switch to NDO, after which only tcpdump.c had a use of it and the definitions guarded by it. Update tcpdump.c not to require them any more and dismiss the unused definitions.
* clean K&R style up in function declarations a bitDenis Ovsienko2015-03-051-2/+2
| | | | The function body should have its opening brace on the next line.
* u_intN_t is dead, long live uintN_t.Guy Harris2014-04-231-77/+77
| | | | | | | | | And, as we require at least autoconf 2.61, and as autoconf 2.61 and later have AC_TYPE_UINTn_T and AC_TYPE_INTn_T macros, we use them to define the uintN_t and intN_t macros if the system doesn't define them for us. This lets us get rid of bitypes.h as well.
* Netdissectify the to-name resolution routines.Guy Harris2014-04-041-5/+5
| | | | | | | | Have them take a netdissect_options * argument, and get the "no name resolution" flag from it. Move the declaration of dnaddr_string to addrtoname.h, along with the other XXX-to-string routines.
* NDOize EIGRP, ICMP, L2TP, STP and UDP decodersDenis Ovsienko2014-03-151-58/+57
|
* remove tcpdump's own CVS keywordsDenis Ovsienko2014-01-031-5/+0
| | | | | | Remove lots of $Header's and a few $Id's that all belong to the former CVS repository of tcpdump itself. These keywords have been frozen since the migration to git in late 2008.
* ndo-ize print-ascii: hex_print_with_offset()Michael Richardson2014-01-011-3/+3
|
* whitespace changesMichael Richardson2014-01-011-5/+5
|
* Fix a bunch of "sizeof(sizeof(XXX))".Sascha Wildner2011-12-071-2/+2
| | | | | | | | In some places, there was one too many levels of sizeof() - sizeof(sizeof(XXX)) is sizeof(size_t), but we wanted the size of type XXX. Reviewed-By: Guy Harris <guy@alum.mit.edu>
* Use TCHECK2() rather than "if(!TTEST()) goto trunc".guy2005-05-061-9/+8
| | | | | | | Make some length and type values unsigned, as they can't be negative. Don't check for them being negative. Check for a TLV length less than the TLV header length.
* "ipaddr_string()" takes, as an argument, a pointer to the bytes of anguy2005-04-201-3/+3
| | | | IPv4 address, not an extracted IPv4 address value.
* add support for Appletalk TLVshannes2004-05-121-4/+105
|
* add support for dissecting the IP_EXT TLVhannes2004-05-011-3/+75
|
* add support for the TLV_IP_INT dissector, changed header flag processinghannes2004-05-011-11/+64
|
* add support for the GENERAL_PARM and SW_VERSION TLVhannes2004-04-301-8/+51
|
* -add baseline support for dissecting EIGRP-IP and EIGRP-IPX messageshannes2004-04-301-0/+212
-FIXME: complete TLV dissection (today we just show the TLV name and hexdump the TLV value)