summaryrefslogtreecommitdiff
path: root/isisd
AgeCommit message (Collapse)Author
2007-08-08[isisd] Commit new files which should have been part of previous commit..Paul Jakma
2007-08-07[isisd] Add support for Solaris DLPIPaul Jakma
2007-08-07 James Carlson <james.d.carlson@sun.com> * configure.ac: Added support for separate link-layer access mechanisms in isisd. * isis_network.c: split up into isis_bpf.c, isis_dlpi.c, and isis_pfpacket.c, selected by autoconf, and added DLPI support. * (general) Fixed to allow compilation and use on Solaris.
2007-05-10[autoconf] bugs 162,303,178: Fix 'present but can not be compiled' warningsPaul Jakma
2007-05-09 Paul Jakma <paul.jakma@sun.com> * configure.ac: sys/conf.h depends on sys/param.h, at least on FBSD 6.2. (bug #363) Should check for in_pktinfo for IRDP 2006-05-27 Paul Jakma <paul.jakma@sun.com> * configure.ac: General cleanup of header and type checks, introducing an internal define, QUAGGA_INCLUDES, to build up a list of stuff to include so as to avoid 'present but cant be compiled' warnings. Misc additional checks of things missing according to autoscan. Add LIBM, for bgpd's use of libm, so as to avoid burdening LIBS, and all the binaries, with libm linkage. Remove the bad practice of using m4 changequote(), just quote the []'s in the case statements properly. This should fix bugs 162, 303 and 178. * */*.{c,h}: Update all HAVE_* to the standard autoconf namespaced HAVE_* defines. I.e. HAVE_SA_LEN -> HAVE_STRUCT_SOCKADDR_SA_LEN, * bgpd/Makefile.am: Add LIBM to bgpd's LDADD, for pow().
2006-12-08[isisd] Fix compiler warnings and allow v4-only compilationPaul Jakma
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.
2006-10-15[daemon startup] Add --dry-run/-C argument to daemons, to check config file ↵Paul Jakma
syntax 2006-10-04 Oliver Hookins <ohookins@gmail.com> * bgpd/bgp_main.c: Add configuration check option, with '-C' rather than '-c' for consistency between daemons. * isisd/isis_main.c: ditto * ospf6d/ospf6_main.c: ditto * ospfd/ospf_main.c: ditto * ripngd/ripng_main.c: ditto * vtysh/vtysh_main.c: ditto * ripd/rip_main.c: Change the config check option to '-C' and tidy up the code. * zebra/main.c: ditto 2006-10-04 Stergiakis Alexandros <astergiakis@antcor.com> * ripd/rip_main.c: This trivial patch introduces a new command-line option '-c', which instructs zebra/ripd to check its configuration file for validity, print any error message, and then exit. This is useful when the configuration file is edited by hand or otherwise, and you simply want to validate it without any other effect. * zebra/main.c: ditto
2006-01-17[zserv] fix up custom isisd and bgpd Zserv functions for new format.paul
2006-01-17 Paul Jakma <paul.jakma@sun.com> * bgp_nexthop.c: (zlookup_read*) convert to new Zserv format. (zlookup_query_ipv6) ditto. (bgp_import_check) ditto. * isis_zebra.c: (isis_zebra_route_add_ipv4) fix for new zserv format.
2005-11-20[isisd] remove includes of common system headers.paul
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.
2005-10-01 * isis_adjacency.c: Stop expire timer while deleting adjacency.hasso
* isis_events.c: Stop pseudo LSP thread while resigning circuit from level. * isis_route.c: Fix compiling with EXTREME_DEBUG. Mark route as not in sync with zebra if it's changed. * isis_spf.c: Schedule route validating etc even if tent was empty. It's probably because we just don't have any adjacencies. * isisd.c: Write minimum spf interval into configuration.
2005-10-012005-09-30 Vincent Jardin <vincent.jardin@6wind.com>jardin
* isis_route.c: fix EXTREME_DEBUG compilation
2005-09-292005-09-29 Paul Jakma <paul.jakma@sun.com>paul
* configure.ac: Add the test for Solaris least-privileges. Set defines for whether capabilities are supported and whether of the linux or solaris variety. Add missing-prototypes, missing-declarations, char-subscripts and cast-qual warnings to default cflags, cause Hasso enjoys warnings, and we really should clean the remaining ones up. (ie isisd..). * (*/*main.c) Update the zebra_capabilities_t arrays in the various daemons to match the changes made in lib/privs.h. * zebra.h: Solaris capabilities requires priv.h to be included. * privs.{c,h}: Add support for Solaris Least-Privileges. privs.h: Reduce some of the abstract capabilities, which do not have rough equivalents on both systems. Rename the net related caps to _NET, as they should have been in first place. (zprivs_terminate) should take the zebra_privs_t as argument so that it can update change pointer. Add an additional privilege state, ZPRIVS_UNKNOWN. * privs.c: (various capability functions) Add Solaris privileges variants. (zprivs_state) Use privs.c specific generic types to represent various capability/privilege related types, so that each can be typedef'd as appropriate on each platform. (zprivs_null_state) static added, to hold the state the null method should report (should be raised by default, and LOWERED if zprivs_terminate has been called) (zprivs_state_null) Report back the zprivs_null_state. (cap_map) Make it able to map abstract capability to multiple system capabilities. (zcaps2sys) Map to abstract capabilities to multiple system privileges/capabilities. (zprivs_init) move capability related init to seperate function, zprivs_caps_init. (zprivs_terminate) ditto, moved to zprivs_caps_terminate. Set the change_state callback to the NULL state, so the user can continue to run and use the callbacks.
2005-09-28 * *.c: Massive cleanup of lists loops. Stop abusing ALL_LIST_ELEMENTS.hasso
Replace XMALLOC + memset with XCALLOC. Fix some indentation issues. The only really significant change is simplified isis_delete_adj function in isis_adjacency.c.
2005-09-28 * isis_dynh.c, isisd.h: Implement dynamic hostname cache cleanup.hasso
* isis_lsp.c: Refresh dynamic hostname in the cache while refreshing topology LSP.
2005-09-28 * isis_lsp.c: Make topology generator generate TE TLVs if necessary.hasso
Also take care of inserting dynamic hostname of topology TLVs into cache.
2005-09-26 * isis_spf.c: Changing cost from uint16_t to uint32_t. Unsethasso
ISIS_ROUTE_FLAG_ACTIVE flag before running SPF. * isisd.[ch]: Separate route tables for different levels. SPF is done separately, but in case of L1L2 area they have to be merged. * isis_zebra.c: Set/unset ISIS_ROUTE_FLAG_ZEBRA_SYNC flag correctly in case of adding/removing IPv4 routes. * zebra_route.c: Rework route validating process. Merging L1 and L2 tables in case of L1L2 area. In short - many changes to make SPF work more correctly, add/remove to/from RIB also works now. It's still very far from perfect though.
2005-09-26 * isis_spf.[ch]: Added TE TLVs to the SPF process. It seems to workhasso
mostly, but needs certainly much more testing, especially transition situation.
2005-09-26 * isis_lsp.c: Put correct metric info into TE TLV's. Wide metric ishasso
used only if only wide metric style (extended TLV's) is in use.
2005-09-26 * isis_tlv.[ch]: New function tlv_add_in_addr() to put just one IPv4hasso
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.
2005-09-26 * isis_lsp.c: Support for originating TE IS and IPv4 TLV's. No any subhasso
TLV handling yet.
2005-09-26 * isis_tlv.[ch]: Two new functions - tlv_add_te_is_neighs() andhasso
tlv_add_te_ipv4_reachs() to handle TLV's with new metric. None of them handle sub TLVs though for now.
2005-09-26 * isis_circuit.[ch]: Some preliminary support for specifying widehasso
circuit metrics. Needs more thinking though, but should do for now.
2005-09-26 * isisd.[ch]: Introduce oldmetric flag for area and transitionhasso
metricstyle command. With metricstyle wide only extended TLVs should be used.
2005-09-25 * dict.[ch]: Revert all nonfunctional changes. It's external modulehasso
imported from kazlib and it's better not to screw it - there is theoretical chance that we might want to merge changes from upstream at some point. Also avoid the loss of info about upstream version (rcsid).
2005-09-21 * isis_route.c: Fix output of nexthops in case of extreme debug.hasso
2005-09-19 * isis_lsp.c, isis_pdu.c, isis_spf.c: Remove some old unused code.hasso
2005-09-19 * isis_lsp.c: Better output of detailed LSP printout and fixed TE IPv4hasso
reachibility metric display.
2005-09-19 * isis_tlv.h: Cleanup comment about TLVs we should support, remove infohasso
about useless (in sense of IP(v6)) TLVs.
2005-09-19 * isis_lsp.h: Added backpointer to the area from LSP. For now it's usedhasso
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.
2005-09-18 * isis_lsp.c (lsp_update): Fix previous commit - manipulate the righthasso
database and only if LSP is really in the database (sanity check).
2005-09-16 * isis_lsp.c (lsp_update): Remove LSP from database before updatinghasso
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.
2005-09-04 * *.c: Try to be less verbose by default (without any debug optionshasso
on). * isis_lsp.c (lsp_build_nonpseudo): Use stream_reset() instead of touching endp directly. * isis_lsp.c (lsp_build_pseudo): Ditto.
2005-09-03 * isis_lsp.c: Yet another regression introduced by stream cleanup.hasso
Similar fix to the one commited to lsp_build_nonpseudo() some days ago.
2005-09-02 * isis_lsp.c: Less TLV leaking.hasso
2005-09-01 * random.c, spgrid.[ch]: Fix warnings with hope that I didn't brokehasso
anything. These floats to longs and vice versa casts are starnge indeed. * isis_pdu.c: As we don't use %z for size_t for now because we support older compilers, cast them to unsigned long. Also fix previous changelog entry. Isisd compiles cleanly now again.
2005-09-01 * isis_adjacency.c, isis_lsp.c, isisd.c: Replace XMALLOC && memsethasso
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-08-16 * isis_misc.[ch]: Fix some warnings, making some strings const.hasso
2005-08-10 * topology/spgrid.c: MAXLONG is deprecated, use LONG_MAX instead.hasso
values.h, where MAXLONG is defined, is deprecated as well. Thanks to Greg for noticing and to Rivo for fix.
2005-05-26 * isis_dr.c: Fix copy&paste error in isis_dr_resign().hasso
[backport candidate]
2005-05-252005-05-25 Paul Jakma <paul@dishone.st>paul
* isisd.c: (show_isis_generated_topology) change to _RO version of list macro. remove the extra listnode variable. one of the macros had had incorrect number of arguments.
2005-05-032005-05-03 Paul Jakma <paul@dishone.st>paul
* (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-152005-04-15 Paul Jakma <paul@dishone.st>paul
* topology/Makefile.am: random.c is a source of libtopology, so list it.
2005-04-12 * isis_adjacency.c: Fix typo introduced with listloop cleanup.hasso
2005-04-112005-04-11 Andrew J. Schorr <ajschorr@alumni.princeton.edu>ajs
Implement non-blocking zclient I/O with buffering. * zclient.h (struct zclient): Add two fields to support non-blocking I/O: struct buffer *wb, and struct thread *t_write. (zclient_free): Remove function. (zebra_redistribute_send): Change 2nd arg from socket fd to struct zclient * (needed to support non-blocking I/O and buffering). (zclient_send_message): New function to send an arbitrary message with non-blocking I/O. * zclient.c (zclient_new): Create write buffer. (zclient_free): Remove unused function. (zclient_stop): Must cancel new t_write thread. Also, reset all buffers: ibuf, obuf, and wb. (zclient_failed): New helper function for typical error handling. (zclient_flush_data): New thread to flush queued data. (zclient_send_message): New function to send the message in zclient->obuf to zebra using non-blocking I/O and buffering. (zebra_message_send, zapi_ipv4_route, zapi_ipv6_route): Use new zclient_send_message function instead of calling writen. (zclient_start): Set socket non-blocking. Also, change 2nd arg to zebra_redistribute_send from zclient->sock to zclient. (zebra_redistribute_send): Change 2nd arg to struct zclient *. Can now use zclient->obuf to assemble the message instead of allocating a temporary stream. And call zclient_send_message to send the message instead of writen. (zclient_read): Convert to support non-blocking I/O by using stream_read_try instead of deprecated stream_read. (zclient_redistribute): Change 2nd arg to zebra_redistribute_send from zclient->sock to zclient. * ospf6_zebra.c (ospf6_zebra_redistribute, ospf6_zebra_no_redistribute): Change 2nd arg to zebra_redistribute_send from zclient->sock to zclient. * ospf_zebra.c (ospf_zebra_add): Call zclient_send_message instead of writen. * rip_zebra.c (rip_redistribute_set, rip_redistribute_unset, rip_redistribute_clean): Change 2nd arg to zebra_redistribute_send from zclient->sock to zclient. * ripng_zebra.c (ripng_redistribute_unset, ripng_redistribute_clean): Change 2nd arg to zebra_redistribute_send from zclient->sock to zclient. * bgp_zebra.c (bgp_redistribute_set, bgp_redistribute_unset): The 2nd arg to zebra_redistribute_send is now zclient instead of zclient->sock. * isis_zebra.h (isis_zebra_finish): Remove declaration of unused function. * isis_zebra.c (isis_zebra_route_add_ipv4): Call zclient_send_message to send the message to zebra instead of calling writen directly, since zclient_send_message understands non-blocking I/O and will manage the buffer queue appropriately. (isis_zebra_finish): Remove unused function, particularly since the zclient_free function has been removed.
2005-04-102005-04-10 Paul Jakma <paul@dishone.st>paul
* 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-072005-04-07 Paul Jakma <paul.jakma@sun.com>paul
* (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.
2005-04-022005-04-02 Andrew J. Schorr <ajschorr@alumni.princeton.edu>ajs
* isis_zebra.c: (isis_zebra_if_del) Must use if_lookup_by_name_len.
2005-04-02 * configure.ac: Add --enable-isis-topology to enable isisd topologyhasso
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-04-022005-04-02 Andrew J. Schorr <ajschorr@alumni.princeton.edu>ajs
Fix problems when netlink interfaces are renamed (same ifindex used for a new interface). Start cleaning up some problems with the way interface names are handled. * interface.c: (if_new_intern_ifindex) Remove obsolete function. (if_delete_update) After distributing the interface deletion message, set ifp->ifindex to IFINDEX_INTERNAL. (if_dump_vty) Detect pseudo interface by checking if ifp->ifindex is IFINDEX_INTERNAL. (zebra_interface) Check return code from interface_cmd.func. Do not set internal ifindex values to if_new_intern_ifindex(), since we now use IFINDEX_INTERNAL for all pseudo interfaces. * kernel_socket.c: (ifm_read) Fix code and comments to reflect that all internal interfaces now have ifp->ifindex set to IFINDEX_INTERNAL. * rt_netlink.c: (set_ifindex) New function used to update ifp->ifindex. Detects interface rename events by checking if that ifindex is already being used. If it is, delete the old interface before assigning the ifindex to the new interface. (netlink_interface, netlink_link_change) Call set_ifindex to update the ifindex. * if.h: Remove define for IFINDEX_INTERNBASE and add define IFINDEX_INTERNAL 0, since all internal (i.e. non-kernel) pseudo- interfaces should have ifindex set to 0. (if_new) Remove function. (if_delete_retain) New function to delete an interface without removing from iflist and freeing the structure. (ifname2ifindex) New function. * if.c: (if_new) Remove function (absorb into if_create). (if_create) Replace function if_new with call to calloc. Set ifp->ifindex to IFINDEX_INTERNAL. Fix off-by-one error in assert to check length of interface name. Add error message if interface with this name already exists. (if_delete_retain) New function to delete an interface without removing from iflist and freeing the structure. (if_delete) Implement with help of if_delete_retain. (ifindex2ifname) Reimplement using if_lookup_by_index. (ifname2ifindex) New function to complement ifindex2ifname. (interface) The interface command should check the name length and fail with a warning message if it is too long. (no_interface) Fix spelling in warning message. (if_nametoindex) Reimplement using if_lookup_by_name. (if_indextoname, ifaddr_ipv4_lookup) Reimplement using if_lookup_by_index. * bgp_zebra.c: (bgp_interface_delete) After deleting, set ifp->ifindex to IFINDEX_INTERNAL. * isis_zebra.c: (isis_zebra_if_del) Call if_delete_retain instead of if_delete, since it is generally not safe to remove interface structures. After deleting, set ifp->ifindex to IFINDEX_INTERNAL. (zebra_interface_if_lookup) Tighten up code. * ospf6_zebra.c: (ospf6_zebra_if_del) Previously, this whole function was commented out. But this is not safe: we should at least update the ifindex when the interface is deleted. So the new version updates the interface status and sets ifp->ifindex to IFINDEX_INTERNAL. (ospf6_zebra_route_update) Use if_indextoname properly. * ospf_vty.c: (show_ip_ospf_interface_sub) Show ifindex and interface flags to help with debugging. * ospf_zebra.c: (ospf_interface_delete) After deleting, set ifp->ifindex to IFINDEX_INTERNAL. (zebra_interface_if_lookup) Make function static. Tighten up code. * rip_interface.c: (rip_interface_delete) After deleting, set ifp->ifindex to IFINDEX_INTERNAL. * ripng_interface.c: (ripng_interface_delete) After deleting, set ifp->ifindex to IFINDEX_INTERNAL.
2005-03-28 * configure.ac, */Makefile.am: Fix previous commit. SNMP includeshasso
must be after lib/ includes in some systems. Introduce SNMP_INCLUDES for that.
2005-03-07 * isis_spf.c: host.name might be NULL.hasso
[backport candidate]
2005-02-232005-02-23 Andrew J. Schorr <ajschorr@alumni.princeton.edu>ajs
* {vty.h,vty.c}: Remove vty_finish (duplicate of vty_reset). * isis_main.c: (reload) Call vty_reset instead of vty_finish (both functions were exactly the same).