summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
| * | | | | | lib: Optimize Fletcher and Internet checksumsJoakim Tjernlund2010-02-041-34/+19
| |/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Did some simple optimizations to reduce the number of instructions in the hot path for both fletcher_checksum() and in_cksum().
* | | | | | Merge branch 'patches/hpp_rdnss' into dn42David Lamparter2010-02-045-0/+180
|\ \ \ \ \ \ | | |_|_|_|/ | |/| | | |
| * | | | | zebra: fix rtadv/rdnss vtysh breakageDavid Lamparter2010-02-041-2/+2
| | | | | |
| * | | | | extend IPv6 documention for RDNSS optionHagen Paul Pfeifer2010-02-031-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | RDNSS RA are specified by RFC 5006 and supported by quagga. This extends the user documentation to illustrate these changes and explain user visable flags. Signed-off-by: Hagen Paul Pfeifer <hagen@jauu.net>
| * | | | | IPv6 Router Advertisement Option for RDNSSHagen Paul Pfeifer2010-02-034-0/+170
| |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | IPv6 Router Advertisement Option for DNS Configuration (RFC 5006)[1] introduced a mechanism to hand out recursive DNS server addresses via router advertisement (RA) messages. This simple combines the IPv6 stateless address auto-configuration process with the ability to get DNS server information - in one message. This options frees many environments from operating an additional DHCPv6 server that provides such information. This patch extends quagga by the ability to generate and transport RDNS addresses. RDNSS options are currently supported at radvd(1) and the Linux Kernel by handover this information to the user-space (via netlink socket). A simple RA configuration with two RDNS entries can be enabled via no ipv6 nd suppress-ra ipv6 nd prefix 2001:db8::/64 ipv6 nd rdnss 2001:db8::1 ipv6 nd rdnss 2001:db8::2 It is additionally possible to specify the lifetime of an RDNSS option as stated in [1] section 4.1. The default is infinity lifetime (0xfffffff) as it serves the most common application areas. ip nd rdnss 2001:db8::1 300000 [1] http://tools.ietf.org/html/rfc5006 Signed-off-by: Hagen Paul Pfeifer <hagen@jauu.net>
* | | | | Merge branch 'patches/smallones' into dn42David Lamparter2010-02-045-206/+1165
|\ \ \ \ \ | | |_|_|/ | |/| | |
| * | | | lib: Do better filtering of arguments, optional args particularlyPaul Jakma2010-02-031-181/+144
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * command.c: (cmd_deopt) helper to extract the inside argument string from an optional argument. (cmd_match) Consolidate matching code from cmd_filter_by_* to here. Use cmd_deopt to match on the /inner/ argument of an optional string, rather than treating optional arguments as matching pretty much any string. (cmd_filter) consolidate cmd_filter_by_* to here, and use cmd_match. Further, do a two-pass filter, to make use of the fact that we know the "strongest" match (e.g. range-match args beat variables) and can filter out weaker ones. Along with ability to match on inside of optional arguments, this makes our command definitions more powerful, and should allow us to avoid much redundancy in command defs. (is_cmd_ambiguous) look inside optional args, for better matching.
| * | | | bgpd: New show commands for improved view and address family supportMichael Lambert2010-02-032-15/+991
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Many show commands do not have support for multiple views and do not treat different address families uniformly. The following changes add a number of commands with support for views and rationalized treatment of IPv4 v IPv6 and unicast v multicast (such as in JUNOS, IOS XR and more recent versions of IOS). * bgp_route.c: (bgp_show_community) Inserted a new second argument (the name of the view) and the code to look up that name in the BGP structure. The NULL argument in the call to bgp_show (indicating the default view) was replaced by the specified view. The existing calls to bgp_show_community had a NULL second argument inserted to make clear that they refer to the default view. (top level) Added new functions via the DEFUN and/or ALIAS macros (and the associated command table entries) to add the commands show bgp ipv4 (unicast|multicast) show bgp ipv4 (unicast|multicast) A.B.C.D show bgp ipv4 (unicast|multicast) A.B.C.D/M show bgp ipv6 (unicast|multicast) show bgp ipv6 (unicast|multicast) X:X::X:X show bgp ipv6 (unicast|multicast) X:X::X:X/M These show either the full BGP table or the specified route or prefix for the given address family. show bgp view WORD (ipv4|ipv6) (unicast|multicast) community show bgp view WORD (ipv4|ipv6) (unicast|multicast) community \ (AA:NN|local-AS|no-advertise|no-export){1,4} For the specified view and address family, these show entries matching any community or the specified communit(y)(ies). show bgp view WORD (ipv4|ipv6) (unicast|multicast) neighbors \ (A.B.C.D|X:X::X:X) (advertised-routes|received-routes) For the specified view and address family, show the routes advertised to or received from the given BGP neighbor. show bgp [view WORD] ipv4 (unicast|multicast) \ rsclient (A.B.C.D|X:X::X:X) show bgp [view WORD] ipv4 (unicast|multicast) \ rsclient (A.B.C.D|X:X::X:X) A.B.C.D show bgp [view WORD] ipv4 (unicast|multicast) \ rsclient (A.B.C.D|X:X::X:X) A.B.C.D/M show bgp [view WORD] ipv6 (unicast|multicast) \ rsclient (A.B.C.D|X:X::X:X) show bgp [view WORD] ipv6 (unicast|multicast) \ rsclient (A.B.C.D|X:X::X:X) X:X::X:X show bgp [view WORD] ipv6 (unicast|multicast) \ rsclient (A.B.C.D|X:X::X:X) X:X::X:X/M For the specifed (optional) view and address family, show either the full BGP table or the specified route or prefix for the given route server client peer. * bgp_vty.c: (top level) Added new functions via the DEFUN and/or ALIAS macros (and the associated command table entries) to add the commands show bgp [view WORD] (ipv4|ipv6) (unicast|multicast) summary show bgp [view WORD] (ipv4|ipv6) (unicast|multicast) rsclient summary For the specified (optional) view and address family, display either the normal summary table for BGP peers, or the route server client table showing the import and export policies.
| * | | | zebra: set the interface link-layer socket addressTom Goff2010-02-031-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * kernel_socket.c: (ifm_read) The reorganization from commit 6fe70d1b35c189cb1e488b2c26551ba7baac6148 removed setting the interface link-layer socket address structure on routing socket platforms. This restores saving the link-layer information because it might be used elsewhere: rtm_write() when no gateway is given, if_dump_vty() and rtadv_send_packet().
| * | | | ospf6d: Fix crash when '[no] ipv6 ospf6 advertise prefix-list' is in ↵David Ward2010-02-031-10/+18
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | startup-config * ospf6_interface.c: When '[no] ipv6 ospf6 advertise prefix-list' appears in the startup configuration for ospf6d, a crash occurs, because ospf6d attempts to schedule LSAs when the 'oi->area' structure has not yet been initialized. Now, when the command above is issued (either in the startup configuration or at runtime), ospf6d will only schedule LSAs if the 'oi->area' structure has been initalized. A similar test is already used when handling the commands 'ipv6 ospf6 priority' and 'ipv6 ospf6 cost'.
* | | | Merge branch 'patches/sh_bgp-write-cork' into dn42David Lamparter2010-02-0410-82/+50
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | Conflicts: lib/sockunion.c
| * | | | BGP: enable TCP corkingStephen Hemminger2010-02-033-11/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On BGP write, use TCP_CORK to provide hints to kernel about TCP buffering. This will cause BGP packets to occur in bigger chunks (full size MTU), improving performance and getting rid of one of the problems reported in the UNH BGP conformance test.
| * | | | BGP: fix crash when allowas-in is doneStephen Hemminger2010-02-031-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes BGP crash when allow-as is changed on inactive peer. It supersedes Michael Larson's earlier patch. When allowas-in is changed on a peer that is not up, BGP would crash trying to do route_refresh. If peer is not up, there is no need to do notification or send.
| * | | | BGP: only use write event for non-blocking connectStephen Hemminger2010-02-032-16/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | According to Steven's and other unix network programming books, only write select is needed when doing non-blocking connect. Doing this simplifies the receive path, it also gets rid of some possible races when when a TCP simultaneous connect happens.
| * | | | BGP: leave peer socket in non-blocking mode (mostly)Stephen Hemminger2010-02-032-21/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rather than toggling socket in/out of non-block mode, just leave it in nonblocking mode. Also, only handle non-blocking and errno's correctly. On write errno is only set if return is less than zero; otherwise errno is from last failed system call. On read errno is only set if return is less than zero. Use convient ERRNO_IO_RETRY() macro to check for AGAIN/INTR etc. One exception is in bgp_notify which only happens just before close.
| * | | | thread: remove except fd setStephen Hemminger2010-02-032-4/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The fd_set exceptfd is never used by any Quagga thread. According to documentation it is only meaningful for out of band data, and no routing protocol uses out of band data. It saves some small amount of kernel overhead to not use it.
| * | | | stream: remove unused stream_read_unblockStephen Hemminger2010-02-032-30/+0
| |/ / / | | | | | | | | | | | | | | | | The one place this was being used in BGP is now gone, can remove deprecated interface.
* | | | Merge branch 'patches/dl_isisd-extract-pl' into dn42David Lamparter2010-02-045-13/+20
|\ \ \ \
| * | | | isisd: change ISIS_METHOD to use C preprocessorDavid Lamparter2010-02-035-13/+20
| |/ / / | | | | | | | | | | | | | | | | | | | | this fixes warnings from vtysh extract.pl by making sure the isis method files always 'work'. (previously, extract.pl would grab unselected isis method sources and then complain about missing headers)
* | | | Merge branch 'patches/fr_isisd-fixes' into dn42David Lamparter2010-02-0416-147/+411
|\ \ \ \
| * | | | isisd: md5 link authenticationFritz Reichmann2010-02-038-25/+204
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Implement isis circuit md5 authentication * Replace command "isis passwd" with "isis passwd {clear|md5}" * Verify HMAC MD5 on ISIS Hello PDUs * Add HMAC MD5 authentication to md5.h/md5.c from RFC2104
| * | | | isisd: fixes 7/7: bug #544: unexpected kernel routing tableFritz Reichmann2010-02-033-25/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix Bug 544: isisd produces an unexpected routing table for wide-metric. * isis_spf.c: Accept VTYPE_PSEUDO_TE_IS and VTYPE_NONPSEUDO_TE_IS vertex types for SPF calculation * isis_pdu.c: Change order of TLVs to match Cisco to make bitwise comparision easier for Wireshark. * isis_tlv.c: EXTREME_TLV_DEBUG for TLV debugging instead of EXTREME_DEBUG CSNP triple sending rate (fix 8/7) is merged into this patch. Cc: David Lamparter <equinox@diac24.net>
| * | | | isisd: fixes 6/7: wrong next-hops from SPFPeter Szilagyi2010-02-033-29/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The forwarding table was filled with wrong next-hops, and which is even worse, it was done in a totally non-deterministic way. The next-hop set for an IP prefix by isisd was the neighbor IS from which the flooded LSP about the IP prefix was arrived. So, if an IS received all the LSPs through its, say, eth0 interface, all entries in the forwarding table contained the next IS reachable via eth0 as the next-hop. The solution is to propagate the correct next-hop further from node to node as the SPF algorithm traverses the graph and selects the next node to be added to the set of already covered nodes. Also, the construction of the tentative node list (the nodes where the shortest path is not known yet) was buggy: if a node was already a member of this list with a certain path cost, and an alternative path was found to it with a lower cost while processing a pseudo-node LSP, it was not added to the list. This way, the path selected by isisd for a certain prefix was the first one it encountered during the LSDB processing. Signed-off-by: Fritz Reichmann <fritz@reichmann.nl>
| * | | | isisd: fixes 5/7: send proper LSP after DIS electionPeter Szilagyi2010-02-031-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | After an IS has been elected as the Designated IS for a LAN, it did not refresh the content of the pseudo-node after a new node has been connected to the same LAN. Instead, the periodically reoriginated pseudo-node LSP still contained only those IS neighbors that were already present when the DIS election process was commenced. The fix for the problem schedules an LSP regeneration rather than just reoriginating the same LSP with the old content. Signed-off-by: Fritz Reichmann <fritz@reichmann.nl>
| * | | | isisd: fixes 4/7: circuit state machinePeter Szilagyi2010-02-035-64/+79
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | isisd has a so-called circuit state machine that takes care about the interface state changes, such as initializing, down, up. When an interface was brought down by a link failure, the interface information was deleted and set to NULL. When the link was restored later, the interface was looked up by the old pointer, but since it was cleared, it was never found again, resulting in an interface never entering the up state again. Also, the program regularly crashed because of a deleted pointer in the same context which was later accessed without any further checking. Signed-off-by: Fritz Reichmann <fritz@reichmann.nl>
| * | | | isisd: fixes 3/7: include hash.h, not hash.cPeter Szilagyi2010-02-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Inclusion of the source file hash.c instead of the proper hash.h header file. Signed-off-by: Fritz Reichmann <fritz@reichmann.nl>
| * | | | isisd: fixes 2/7: bug #539: wrong hello rate for pseudo nodeFritz Reichmann2010-02-031-2/+24
| | | | | | | | | | | | | | | | | | | | * isis_pdu.c: Divide hello interval by three, depending if we are DIS or not.
| * | | | isisd: fixes 1/7: bug #536: crash on apply/delete isis configFritz Reichmann2010-02-036-3/+40
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The crash is due to threads accessing data that gets destroyed during the removal of the configuration. * isis_circuit.c: Destroy adjacencies to stop adjacency expiry thread. Stop PSNP threads. * isisd.c: Change state of circuit back to INIT and reassing the circuit structure to isis->init_circ_list rather than destroying the circuit data structure. Stop SPF threads. Stop LSP generation threads. * isisd.h: Add pointers to LSP threads into area structure in order to stop them in isisd.c * isis_lsp.c: Store pointer to LSP thread in area structure. * isis_pdu.c: Stop PDU generation for a circuit with a removed area. * isis_pfpacket.c: Stop processing received PDUs for a circuit with a removed area.
* | | | Merge branch 'patches/dl_bug-537' into dn42David Lamparter2010-02-043-37/+82
|\ \ \ \
| * | | | bgpd: remove unused function bgp_bind_addressDavid Lamparter2010-02-031-26/+0
| | | | | | | | | | | | | | | | | | | | bgp_bind_address is replaced with sockunion_bind.
| * | | | bgpd: bug #537: find proper source address for interface update-sourceDavid Lamparter2010-02-031-12/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | if update-source was given as interface name, bgpd was unconditionally trying to bind to an IPv4 address from that interface. change function to find the best-matching (number of address bits) same-family address on the interface.
| * | | | lib: prefix2sockunion, prefix_common_bits helper functionsDavid Lamparter2010-02-032-0/+56
| |/ / / | | | | | | | | | | | | | | | | | | | | prefix2sockunion converts a struct prefix* to a union sockunion *; prefix_common_bits counts the number of common bits in the prefix's address part.
* | | | Merge branch 'patches/jt_times2' into dn42David Lamparter2010-02-042-49/+85
|\ \ \ \
| * | | | lib: fix header broken by times(2) branchDavid Lamparter2010-02-031-4/+0
| | | | |
| * | | | lib: Use times(2) to calculate relative time.Joakim Tjernlund2010-02-031-36/+84
| | | | | | | | | | | | | | | | | | | | | | | | | times(2) is monotonic, use it to calculate relative_time and scale the value using sysconf(_SC_CLK_TCK);
| * | | | lib: Unexport recent_timeJoakim Tjernlund2010-02-031-9/+1
| |/ / / | | | | | | | | | | | | | | | | Exporting a variable is bad practise and since recent_time isn't used, make it static.
* | | | dn42: motdDavid Lamparter2010-02-041-3/+3
| | | |
* | | | dn42: enable HSLS, OLSR, BATMAN, DHCPDavid Lamparter2010-02-042-6/+21
| | | |
* | | | dn42: bgpd: always display IP subnets with netmaskDavid Lamparter2010-02-041-29/+4
| | | | | | | | | | | | | | | | | | | | from ht-20040304-classless-bgp_adapted.patch, removes special treatment of classful netmasks.
* | | | dn42: tag versionDavid Lamparter2010-02-041-1/+1
| |/ / |/| |
* | | lib: fs namespacing 5/5: vtysh -N command-line parameterDavid Lamparter2010-02-041-1/+17
| | | | | | | | | | | | | | | | | | vtysh needs some special care for namespace support in order to not open a gaping security hole. this patch allows giving namespace names without slashes or leading dots only.
* | | lib: fs namespacing 4/5: add -N command-line parameterDavid Lamparter2010-02-046-7/+38
| | | | | | | | | | | | | | | this adds a -N option to all daemons which specifies the namespace name to include in all paths through path_set_namespace
* | | lib: fs namespacing 3/5: use path_state for zserv socketDavid Lamparter2010-02-047-7/+18
| | | | | | | | | | | | | | | | | | this uses the path_state helper for determining the path of quagga's zserv.api socket. this allows for running multiple instances of zebra each with its own interface.
* | | lib: fs namespacing 2/5: use path_state for vty pathsDavid Lamparter2010-02-0423-70/+122
| | | | | | | | | | | | | | | | | | use the path_state helper functions for determining vty socket paths in all quagga daemons. this allows for running multiple daemons if a namespace name is set.
* | | lib: fs namespacing 1/5: add path_* helpersDavid Lamparter2010-02-044-3/+103
| | | | | | | | | | | | | | | | | | path_state and path_config return full path names to configuration / state files. path_set_namespace can be used to include a namespace part into the paths returned.
* | | zebra: NetBSD: support setting IPSRCSEL preferenceDavid Lamparter2010-02-042-11/+78
| | | | | | | | | | | | | | | | | | | | | | | | add 'ip address X preference Y' vty command and appropriate infrastructure for setting it through ioctl(SIOCSIFADDRPREF). IPSRCSEL is a NetBSD kernel option(4), documented in in_getifa(9) and is available since NetBSD 4.0 but not enabled in default GENERIC.
* | | zebra: NetBSD: get IPSRCSEL preference value from kernelDavid Lamparter2010-02-049-8/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | fetch the address preference value from the kernel through SIOCGIFADDRPREF and pass it to quagga through connected_add_ipv4, which stores it in struct connected->preference. IPSRCSEL is a NetBSD kernel option(4), documented in in_getifa(9) and is available since NetBSD 4.0 but not enabled in default GENERIC.
* | | zebra: configure PtP address on ifaliasreq systemsDavid Lamparter2010-02-041-5/+41
| | | | | | | | | | | | | | | | | | | | | support configuring a point-to-point address on systems using ioctl / struct ifaliasreq. error out when interface/address type mismatch. tested on FreeBSD 8.0-RELEASE.
* | | zebra: add 'ip address ... scope WORD' vty+netlinkDavid Lamparter2010-02-042-14/+81
| | | | | | | | | | | | | | | add a new "scope WORD" flag on ip address creation commands to set the address's scope.
* | | netlink: process scope value, save itDavid Lamparter2010-02-0310-16/+28
| | | | | | | | | | | | | | | add struct connected "scope" field, fill it from kernel data and display it in "show interface" address list.