summaryrefslogtreecommitdiffstats
path: root/isisd/isis_lsp.c
Commit message (Collapse)AuthorAgeFilesLines
* isisd: handle lsp confusion (ISO/IEC 10589:2002 7.3.16.2)Christian Franke2015-12-081-1/+13
| | | | | Signed-off-by: Christian Franke <chris@opensourcerouting.org> Acked-by: Donald Sharp <sharpd@cumulusnetworks.com>
* isisd: fix IPv6 mask applicationChristian Franke2015-12-081-5/+5
| | | | | Signed-off-by: Christian Franke <chris@opensourcerouting.org> Acked-by: Donald Sharp <sharpd@cumulusnetworks.com>
* isisd: add support to import routes from other protocolsChristian Franke2015-12-081-2/+132
| | | | Signed-off-by: Christian Franke <chris@opensourcerouting.org>
* isisd: fix assertion in LSP refresh timer calculationChristian Franke2015-12-081-1/+4
| | | | | Signed-off-by: Christian Franke <chris@opensourcerouting.org> Acked-by: Donald Sharp <sharpd@cumulusnetworks.com>
* isisd: add a slight delay to lsp_regenerate_scheduleChristian Franke2015-12-081-35/+106
| | | | | | | | | | | | | | | | | | | | | | | isisd implements a holdoff interval and will refrain from regenerating an lsp if the difference between the current time and its last refresh is less than the holdoff interval. Instead, it will schedule a timer to regenerate the lsp after the holdoff interval has passed. This implementation has one disadvantage in the case where there is a succession of calls to lsp_regenerate_schedule. In such a case, the first call will trigger an immediate regeneration of the lsp, while the other calls will only schedule the regeneration timer. This leads to cases where it takes holdoff interval time for information to propagate, just because the information was only available e.g. at the second call of lsp_regenerate_schedule in such a succession of calls. By not immediately regenerating an lsp if the last generation time is sufficiently long ago, but instead scheduling the regeneration with a very small delay, we allow all information from such a succession of calls to be considered. Signed-off-by: Christian Franke <chris@opensourcerouting.org> Acked-by: Donald Sharp <sharpd@cumulusnetworks.com>
* isisd: add a debug mode that traces LSP constructionChristian Franke2015-12-081-5/+112
| | | | Signed-off-by: Christian Franke <chris@opensourcerouting.org>
* isisd: purge on correct levelChristian Franke2015-12-081-3/+3
| | | | | Signed-off-by: Christian Franke <chris@opensourcerouting.org> Acked-by: Donald Sharp <sharpd@cumulusnetworks.com>
* isisd: allow to adjust lsp-mtuChristian Franke2015-12-081-12/+12
| | | | | Signed-off-by: Christian Franke <chris@opensourcerouting.org> Acked-by: Donald Sharp <sharpd@cumulusnetworks.com>
* isisd: don't corrupt memory for long hostnamesChristian Franke2015-12-081-3/+10
| | | | | Signed-off-by: Christian Franke <chris@opensourcerouting.org> Acked-by: Donald Sharp <sharpd@cumulusnetworks.com>
* isisd: remove superfluous checks after XMALLOC etc.Christian Franke2015-12-081-6/+1
| | | | Signed-off-by: Christian Franke <chris@opensourcerouting.org>
* isisd: Fix LSPs not being regenerated after adjacency changeMichael Zingg2015-10-271-1/+12
| | | | | | | | | | In isisd LSP's are not regenerated after a change in adjacency if lsp-gen-interval has expired. I have tested this on Debian 6.0 with zebra and level1 isisd with point to point links. This problem is also listed in Test ISIS-18.3 on the opensourcerouting.org wiki: http://confluence.isc.org/display/osr/ANVL+ISIS+Compliance+Test+Plan http://confluence.isc.org/display/osr/ANVL+ISIS+Results
* isisd: Attached-bit in LSP headerAmritha Nambiar2015-09-031-11/+22
| | | | | | | | | | | | | | | | | | | | | | | | Set/reset attached-bit in LSP header: This patch provides support for set/reset attached_bit in the LSP header. In IS-IS networks, routing inter-area traffic from L1 areas is accomplished by sending the traffic to the nearest L1/L2 router. A L1/L2 router identifies itself by setting an attach-bit (ATT-bit) in its (LSP). The ATT-bit in LSP can be changed using the set-attached-bit or no-set-attached-bit commands (similar to ‘set-overload-bit’ and 'no set-overload-bit’) using telnet terminal in router configuration mode. Steps: enable configure terminal router isis <Routing area> set-attached-bit V2: Removed looping through area list as this well set the bit for all areas in the list. This implementation now looks exactly like the current overload bit implementation. Signed-off-by: Amritha Nambiar <amritha.nambiar@intel.com>
* isisd: assorted fixes (unused variables, static)David Lamparter2015-04-211-2/+2
| | | | | | This just mops up a few warnings in isisd. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
* isisd: fix minor & vs. && mix-upDavid Lamparter2015-04-211-1/+1
| | | | | | apparently we were displaying all IPv6 reachabilities as external. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
* *: fix signedness mix-upsDavid Lamparter2015-04-211-1/+1
| | | | Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
* isisd: address Coverity warningsDavid Lamparter2012-12-121-1/+3
| | | | | | | | | | | | | | | | | this fixes a bunch of issues found by Coverity SCAN and flagged as "high" impact -- although, they're all rather minute issues. * isisd/isis_adjacency.c: one superfluous check, one possible NULL deref * isisd/isis_circuit.c: two prefix memory leaks * isisd/isis_csm.c: one missing break * isisd/isis_lsp.c: one possible NULL deref * isisd/isis_pfpacket.c: one error-case fd leak * isisd/isis_route.c: one isis_route_info memory leak * isisd/isis_routemap.c: one... fnord * isisd/isis_tlv.c: one infinite loop Reported-by: Coverity SCAN Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
* isisd: fix typo in topology generator (BZ#731)David Lamparter2012-06-211-1/+1
| | | | | | | | There was a "lsp->" missing before "level" in line 2416. (introduced by git commit e38e0df) Reported-by: Seblu <seblu@seblu.net> Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
* isisd: couple of bug fixesSubbaiah Venkata2012-04-071-16/+26
|
* isisd: add Google's changes to IS-ISJosh Bailey2012-04-071-634/+883
|
* [cleanup] convert bzero() deprecated by POSIX to memset()Jeremy Jackson2009-06-191-1/+1
| | | | | autoscan 2.62 complains about bzero(), so a good fix nowadays is to just replace it.
* [ospfd/isisd] Switch to lib/ Fletcher checksum, fixing bug in isisdJingjing Duan2008-08-221-4/+4
| | | | | | | | | | 2008-08-13 Jingjing Duan <Jingjing.Duan@sun.com> * ospfd/: Remove the old checksum implementation and use the consolidated version. * isisd/: ditto, thus fixing isisd checksuming on big-endian. Signed-off-by: Paul Jakma <paul@quagga.net>
* [isisd] Fix compiler warnings and allow v4-only compilationPaul Jakma2006-12-081-1/+1
| | | | | | | | | | | 2006-12-08 Hannes Gredler <hannes@gredler.at> * isis_adjacency.c: (isis_new_adj) Allow NULL snpa argument. * isis_pdu.c: (various) Update calls to isis_new_adj() to pass NULL and use default. * (general) Add forward declarations where required. Fix up const char *'s. Allow V4-only compilation.
* [isisd] remove includes of common system headers.paul2005-11-201-2/+0
| | | | | | | | | | | 2005-11-20 Paul Jakma <paul.jakma@sun.com> * (general) remove includes of very common system headers, these are already picked up by zebra.h. Further, including them before zebra.h messes up all our lovely (sarcasm) autoconf'd detecting of platform specific things. Recent addition of stdint.h to configure.ac and zebra.h appears particularly to throw up this problem.
* * *.c: Massive cleanup of lists loops. Stop abusing ALL_LIST_ELEMENTS.hasso2005-09-281-34/+27
| | | | | | Replace XMALLOC + memset with XCALLOC. Fix some indentation issues. The only really significant change is simplified isis_delete_adj function in isis_adjacency.c.
* * isis_dynh.c, isisd.h: Implement dynamic hostname cache cleanup.hasso2005-09-281-0/+4
| | | | | * isis_lsp.c: Refresh dynamic hostname in the cache while refreshing topology LSP.
* * isis_lsp.c: Make topology generator generate TE TLVs if necessary.hasso2005-09-281-13/+51
| | | | | Also take care of inserting dynamic hostname of topology TLVs into cache.
* * isis_lsp.c: Put correct metric info into TE TLV's. Wide metric ishasso2005-09-261-4/+20
| | | | used only if only wide metric style (extended TLV's) is in use.
* * isis_tlv.[ch]: New function tlv_add_in_addr() to put just one IPv4hasso2005-09-261-13/+15
| | | | | | address into TLV. Used for IPv4 address TLV (in case of LSP) and TE router ID TLV. * isis_lsp.c: Use tlv_add_in_addr() and include router ID in LSP.
* * isis_lsp.c: Support for originating TE IS and IPv4 TLV's. No any subhasso2005-09-261-40/+174
| | | | TLV handling yet.
* * isis_lsp.c, isis_pdu.c, isis_spf.c: Remove some old unused code.hasso2005-09-191-307/+0
|
* * isis_lsp.c: Better output of detailed LSP printout and fixed TE IPv4hasso2005-09-191-9/+10
| | | | reachibility metric display.
* * isis_lsp.h: Added backpointer to the area from LSP. For now it's usedhasso2005-09-191-95/+126
| | | | | | | | | | | | | only in generated topology LSPs. * isisd.[ch]: Cleanup CLI commands related to topology generation and added command to specify base fo dynamic hostname for topology LSPs. * isis_lsp.c: Rewrite almost all code related to generation topology LSPs (top_lsp_refresh(), generate_topology_lsps() and build_topology_lsp_data() functions). Topology is connected to own LSP now (lsp_build_nonpseudo). Commented out lsppdu_realloc functions, it's not used any more hopefully. Topology generation feature is actually useful now.
* * isis_lsp.c (lsp_update): Fix previous commit - manipulate the righthasso2005-09-181-5/+6
| | | | database and only if LSP is really in the database (sanity check).
* * isis_lsp.c (lsp_update): Remove LSP from database before updatinghasso2005-09-161-1/+10
| | | | | | its data and put it back after. Database entry MUST contain at least correct pointers to the sysid to get correct compare results. * isis_lsp.[ch], isis_pdu.c: Pass level to the lsp_update() function.
* * *.c: Try to be less verbose by default (without any debug optionshasso2005-09-041-9/+7
| | | | | | | on). * isis_lsp.c (lsp_build_nonpseudo): Use stream_reset() instead of touching endp directly. * isis_lsp.c (lsp_build_pseudo): Ditto.
* * isis_lsp.c: Yet another regression introduced by stream cleanup.hasso2005-09-031-0/+4
| | | | | Similar fix to the one commited to lsp_build_nonpseudo() some days ago.
* * isis_lsp.c: Less TLV leaking.hasso2005-09-021-1/+7
|
* * isis_adjacency.c, isis_lsp.c, isisd.c: Replace XMALLOC && memsethasso2005-09-011-26/+22
| | | | | | | | | with XCALLOC. * isis_lsp.c (lsp_build_pseudo): Fix adding ES neighbour. * isis_tlv.c: More compact free_tlvs() function. * isis_lsp.c (lsp_build_nonpseudo) : Try to fix one more regression introduced by stream cleanup. Seek enp to the right place before starting to fill stream with TLVs.
* 2005-05-03 Paul Jakma <paul@dishone.st>paul2005-05-031-20/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * (general) More cleaning up of stream abuse, isisd should be back to previous functionality. Replace various XMALLOC+memset's with XCALLOC * isis_tlv.c: (tlv_add_padding) use stream_put to clear the stream rather than forward endp, as isisd reuses streams. * isis_pdu.c: (process_lsp) cleanup direct reference to stream endp (send_lsp) manual copy of a stream cleaned up to use stream_copy. * isis_network.c: (isis_recv_pdu_bcast) replace direct memcpy with stream_write (isis_recv_pdu_p2p) replace recvfrom directly into stream with stream_recvfrom. Remove dangerous and now unneeded manual update of endp. (isis_recv_pdu_bcast / non-GNU_LINUX) Replace direct memcpy with stream_write. (isis_recv_pdu_p2p) replace read direct into stream with stream_read_try, and hence remove the manual update of endp. * isis_lsp.c: (lsp_update_data) manual stream dup replaced with stream_dup. (lsppdu_realloc) mempcy into stream data replaced with stream_put. (lsp_build_nonpseudo) remove mysterious stream_forward_endp's - which were originally stream_set_putp - shouldn't be needed now that all the manual fiddling of private stream data has been corrected. (build_topology_lsp_data) remove unneeded twiddling of endp, appears to be due to lsppdu_realloc(), but it appears to sort of do the right thing wrt streams.
* 2005-04-10 Paul Jakma <paul@dishone.st>paul2005-04-101-3/+3
| | | | | | | | | | * Makefile.am: topology should not be a conditional SUBDIR, otherwise make dist breaks. * topology/Makefile.am: remove EXTRA_DIST of files which dont exist in that directory, broke make dist. * isisd.c: (show_isis_generated_topology_cmd) convert LIST_LOOP * isis_lsp.c: (generate_topology_lsps) ditto (build_topology_lsp_data) ditto
* 2005-04-07 Paul Jakma <paul.jakma@sun.com>quagga_post_listloop_cleanuppaul2005-04-071-58/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * (global): Fix up list loops to match changes in lib/linklist, and some basic auditing of usage. * configure.ac: define QUAGGA_NO_DEPRECATED_INTERFACES * HACKING: Add notes about deprecating interfaces and commands. * lib/linklist.h: Add usage comments. Rename getdata macro to listgetdata. Rename nextnode to listnextnode and fix its odd behaviour to be less dangerous. Make listgetdata macro assert node is not null, NULL list entries should be bug condition. ALL_LIST_ELEMENTS, new macro, forward-referencing macro for use with for loop, Suggested by Jim Carlson of Sun. Add ALL_LIST_ELEMENTS_RO for cases which obviously do not need the "safety" of previous macro. LISTNODE_ADD and DELETE macros renamed to ATTACH, DETACH, to distinguish from the similarly named functions, and reflect their effect better. Add a QUAGGA_NO_DEPRECATED_INTERFACES define guarded section with the old defines which were modified above, for backwards compatibility - guarded to prevent Quagga using it.. * lib/linklist.c: fix up for linklist.h changes. * ospf6d/ospf6_abr.c: (ospf6_abr_examin_brouter) change to a single scan of the area list, rather than scanning all areas first for INTER_ROUTER and then again for INTER_NETWORK. According to 16.2, the scan should be area specific anyway, and further ospf6d does not seem to implement 16.3 anyway.
* * configure.ac: Add --enable-isis-topology to enable isisd topologyhasso2005-04-021-2/+0
| | | | | | | | | | | | generator code. * isisd/Makefile.am: Variables to handle conditonal compiling of topology generator code. * isisd/isis_lsp.c: lsppdu_realloc() is used by topology generator. * isisd/isisd.c: Rename show_isis_topology_cmd to not conflict the one in the isis_spf.c. * isisd/isisd.h: Remove TOPOLOGY_GENERATE define, it will be defined in toplevel config.h if topology generator is enabled. * isisd/topology/Makefile.am: Handle the libtoolized Quagga libraries.
* 2005-02-09 Paul Jakma <paul.jakma@sun.com>paul2005-02-091-9/+7
| | | | | | | | | | | | | * (global) Update code to match stream.h changes. stream_get_putp effectively replaced with stream_get_endp. stream_forward renamed to stream_forward_getp. stream_forward_endp introduced to replace some previous setting/manual twiddling of putp by daemons. * lib/stream.h: Remove putp. Update reference to putp with endp. Add stream_forward_endp, which daemons were doing manually. Rename stream_forward to stream_forward_getp. lib/stream.c: Remove/update references to putp. introduce stream_forward_endp.
* * *.c: Changed many functions to static. Some commented outhasso2005-01-181-21/+25
| | | | functions and some tiny related fixes. No functional changes.
* zlog_* cleanup. Level of debug messages to LOG_DEBUG.hasso2004-12-241-55/+55
|
* Argh, fix typo.hasso2004-10-081-1/+1
|
* No warnings here any more.hasso2004-10-071-145/+32
|
* Common router id.hasso2004-10-031-0/+26
|
* Compiler warnings fixes.hasso2004-09-261-5/+5
|
* * isisd.c: thread_master *master is already defined in isis_main.c.hasso2004-09-241-0/+3
| | | | | * isis_misc.[c|h], isis_lsp.[c|h]: Move static variables out of header files.