summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2011-12-13lib: clearing zclient.c for some cases of buildingVyacheslav Trushkin
lib/zclient.c: using of HAVE_TCP_ZEBRA in zclient_socket_* definitions extended by else clause.
2011-12-13quagga: option "-z" ("--socket <path>") addedVyacheslav Trushkin
All daemons modified to support custom path to zserv socket. lib: generalize a zclient connection zclient_socket_connect added. zclient_socket and zclient_socket_un were hidden under static expression. "zclient_serv_path_set" modified.
2011-12-13isisd: indent longopts arrayVyacheslav Trushkin
2011-12-13bgpd: implement 'match probability' in route-mapsVyacheslav Trushkin
New clause 'match probability <percentage value>' was added in route-maps (bgpd/bgp_routemap.c modified).
2011-12-13ospf6d: justify multicast group managementVyacheslav Trushkin
* ospf6_network.[ch] * ospf6_sso(): new function supersedes ospf6_join_allspfrouters(), ospf6_leave_allspfrouters(), ospf6_join_alldrouters() and ospf6_leave_alldrouters() * ospf6_interface.c * ospf6_interface_state_change(): update respectively * interface_up(): ditto * interface_down(): ditto
2011-12-13ripngd: limit max of "timers basic" to 65535 as documentedUlrich Weber
and use VTY_GET_INTEGER_RANGE instead of calling strtoul
2011-12-13bgp: use VTY_GET_INTEGER_RANGE() in bgp_clear()Ulrich Weber
Second patch replaces "VTY_GET_LONG ("AS", as_ul, arg);" by "VTY_GET_INTEGER_RANGE ("AS", as, arg, 1, BGP_AS4_MAX);" as done in all other code, which parses AS numbers.
2011-12-13ospf6d: implement 'match interface' for route-mapsVyacheslav Trushkin
ospf6_routemap_rule_match_interface* was imported from ospfd daemon with minor changes. new CLI options defined. `ospf6_routemap_rule_match_interface' was changed to support IPv6 (ospfv3) route's external information.
2011-12-07lib: fix SMUX compiler warningsStephen Hemminger
Make progname a string, and cast when calling asn1. Remove variable set but never used.
2011-12-07lib: fix compile warnings from set-never-usedStephen Hemminger
The if_dump code had empty loop, that caused set-never-used warning.
2011-12-07ospf6d: fix compile warning from falling off end of mainStephen Hemminger
ospf6 main always calls ospf6_exit() which always calls exit. Use attributes to tell GCC that this is ok.
2011-12-07zebra: fix warnings in forward procStephen Hemminger
Check result of fgets(), and don't set variable that is never used.
2011-12-07bgpd: cleanup privs on terminationStephen Hemminger
When doing valgrind testing, the privledges from zprivs_init() need to be cleaned up on exit.
2011-12-07vty_serv_sock_family unusedStephen Hemminger
If the vty_serv_sock_addrinfo is being used, then vty_serv_sock_family is unsed. Fix by adjusting ifdef/else/endif
2011-12-07ospfd: remove unused codeStephen Hemminger
The code for nssa_range and other bits that were written but never used.
2011-12-06bgpd: store nexthop info for redistributed IPV6 routesStephen Hemminger
BGP was ignoring nexthop info for static and other redistributed routes for IPv6. Build extra attribute info to store the nexthop. See also: https://bugzilla.vyatta.com/show_bug.cgi?id=6073
2011-12-06ospfd: avoid redundant lookup in ospf_redistribute_withdrawStephen Hemminger
The old algorithim looked up every node twice as it withdrew the entry. It looks up entry once in redistribute_withdraw, then looks it up again info_delete. Use result of first lookup to do the free directly. This may explain the slow performance observed in https://bugzilla.vyatta.com/show_bug.cgi?id=4421
2011-12-06lib: fix memory leak on connect() failureStephen Hemminger
Change sockunion_log() to not use strdup(). This fixes a small memory leak that occurs on every failed connect(), and is simpler/cleaner.
2011-12-06lib: call filter delete hook before freeing access listStephen Hemminger
The delete_hook was being run after calling access list delete function. This would cause ospf to dereference a NULL, in ospf_filter_update because 'access->name' was already freed. See also: https://bugzilla.vyatta.com/show_bug.cgi?id=7654
2011-12-03bgpd: fix memory leak for extra attributesOleg A. Arkhangelsky
this fixes commit b881c7074bb698aeb1b099175b325734fc6e44d2
2011-11-22doc: rectify "match ip next-hop" in ripd (BZ#537)Roderick Schertler
2011-11-21bgpd: remove unused function bgp_bind_addressDavid Lamparter
bgp_bind_address is replaced with sockunion_bind.
2011-11-21bgpd: fix update-source for IPv6 (BZ#548)David Lamparter
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.
2011-11-21lib: prefix2sockunion, prefix_common_bits helper functionsDavid Lamparter
prefix2sockunion converts a struct prefix* to a union sockunion *; prefix_common_bits counts the number of common bits in the prefix's address part.
2011-11-17ospf6d: check MTU with message header size in mindDmitrij Tejblum
* ospf6_message.c: (ospf6_packet_max): new function, return maximum IPv6 payload on an interface; (ospf6_hello_send, ospf6_dbdesc_send, ospf6_dbdesc_send_newone, ospf6_lsreq_send, ospf6_lsupdate_send_neighbor, ospf6_lsupdate_send_interface, ospf6_lsack_send_neighbor, ospf6_lsack_send_interface): compare message size with the maximum payload instead of the MTU.
2011-11-15bgpd: fix "nexthop-local unchanged" (BZ#350)Dylan Hall
2011-11-15bgpd: justify capabilities for TOS settingChris Luke
To set the TOS bits on TCP connections, platforms that restrict capabilities need the priv level to be raised before the sockopt is set, and this requires the ZCAP_NET_ADMIN priv. * bgp_main.c: update _caps_p to include ZCAP_NET_ADMIN * bgp_network.c * bgp_connect(): request ZPRIVS_RAISE/ZPRIVS_LOWER * bgp_listener(): request ZPRIVS_RAISE earlier
2011-11-15ospfd: improve fix to CVE-2011-3326 (BZ#586)Thomas Ries
Make ospf_flood() propagate error returned by ospf_lsa_install() further to properly discard the malformed LSA, not just prevent the immediate crash.
2011-11-15bgpd: revised fix to --dryrun (BZ#622)Sergey Y. Afonin
2011-10-26bgpd: fix 2 more cases of length error reportingDenis Ovsienko
* bgp_attr.c (bgp_attr_originator_id, bgp_attr_cluster_list): provide required arguments to bgp_attr_malformed()
2011-10-22bgpd: check AGGREGATOR attr flags (BZ#678)Denis Ovsienko
* bgp_attr.c * bgp_attr_aggregator(): check Optional/Transitive flag bits
2011-10-19bgpd: fix more regressions in attr flag checksDenis Ovsienko
Commit 05a4936b713b9882171d0f7fb20b8439df23939e fixed some of the attributes involved, but not all. This commit should do it. * bgp_attr.c * bgp_attr_originator_id() * bgp_attr_cluster_list() * bgp_mp_reach_parse() * bgp_mp_unreach_parse()
2011-10-18bgpd: use bgp_attr_malformed()Denis Ovsienko
Some of the recent attribute flags/length checks copied from QRE use bgp_notify_send_with_data() directly, but master branch assumes using bgp_attr_malformed(). * bgp_attr.c * bgp_attr_med() * bgp_attr_local_pref() * bgp_attr_atomic() * bgp_attr_originator_id() * bgp_attr_cluster_list() * bgp_mp_reach_parse() * bgp_mp_unreach_parse()
2011-10-17bgpd: add flag checks for MP_(UN)REACH_NLRIDenis Ovsienko
* bgp_attr.[ch] * bgp_mp_reach_parse(): add extra arguments and a uniform flag check block * bgp_mp_unreach_parse(): idem * bgp_attr_parse(): provide extra arguments * bgp_mp_attr_test.c * parse_test(): justify respective calls
2011-10-17bgpd: fix spelling of CLUSTER_LISTDenis Ovsienko
2011-10-17bgpd: check CLUSTER_LIST attribute flagsDenis Ovsienko
* bgp_attr.c * bgp_attr_cluster_list(): accept extra argument, add checks for "optional", "transitive" and "partial" bits, log each error condition independently * bgp_attr_parse(): provide extra arguments
2011-10-17bgpd: check ORIGINATOR_ID attribute flagsDenis Ovsienko
* bgp_attr.c * bgp_attr_originator_id(): accept extra argument, add checks for "optional", "transitive" and "partial" bits, log each error condition independently * bgp_attr_parse(): provide extra arguments
2011-10-17vtysh: [build] silence preprocessor errors in some casesDmitrij Tejblum
* extract.pl.in: use configured CPPFLAGS in cpp invocation.
2011-10-17lib: compile even without IPV6_TCLASSDenis Ovsienko
2011-10-17IPv6 transport class suppportStephen Hemminger
IPv6 supports the same concept of differentiated service for routing protocols as IPv4, but like too many things, the standards committee decided that having two names for the same thing wasn't good enough and introduced a third more generic term transport class. The socket option to set transport class works the same as IPv4, but the arguments are different. * lib/sockopt.[ch] * setsockopt_ipv6_tclass(): new function * bgpd/bgp_network.c * bgp_connect(): set socket option * bgp_listener(): set socket option * ospf6d/ospf6_network.c * ospf6_set_transport_class(): new function * ospf6_serv_sock(): set socket option * ripngd/ripngd.c * ripng_make_socket(): set socket option
2011-10-12bgpd: fix regression in improved attr flag checksDenis Ovsienko
Commit 2febf323411c1aed9d7694898f852ce2ef36a7e5 assumed every flag bit except optional/transitive/partial unset, which at times could not be true for "extended length" bit. * bgp_attr.c * bgp_attr_origin(): exclude BGP_ATTR_FLAG_EXTLEN from comparison * bgp_attr_nexthop(): idem * bgp_attr_med(): idem * bgp_attr_local_pref(): idem * bgp_attr_atomic(): idem
2011-10-08bgpd: fix parsing of graceful restart cap. (#663)Peter Pentchev
"While setting up a testbed, I ran across a little problem in the parsing of the "graceful restart" BGP capability that resulted in Quagga not actually activating it for the peer in question - when the peer sent a single AFI/SAFI block." * bgp_open.c * bgp_capability_restart(): actually process the last AFI/SAFI block
2011-10-08bgpd: improve attr length error handling (BZ#679)Denis Ovsienko
* bgp_attr.c * bgp_attr_parse(): provide extra argument to bgp_attr_aggregator() * bgp_attr_local_pref(): use bgp_notify_send_with_data() * bgp_attr_atomic(): idem * bgp_attr_aggregator(): idem Conflicts: bgpd/bgp_attr.c
2011-09-30bgpd: improve attr flags checksDenis Ovsienko
Do not check each of the Optional/Transitive/Partial attribute flag bits, when their only valid combination is known in advance, but still perform bit-deep error message logging. This change assumes unused (low-order) 4 bits of the flag octet cleared. * bgp_attr.c * bgp_attr_origin(): rewrite check * bgp_attr_nexthop(): idem * bgp_attr_med(): idem * bgp_attr_local_pref(): idem * bgp_attr_atomic(): idem Conflicts: bgpd/bgp_attr.c
2011-09-30bgpd: ignore 4 bits of attribute flags byteDenis Ovsienko
2011-09-30bgpd: add missing "partial" flag checks (BZ#676)Denis Ovsienko
ORIGIN handling function used to have "partial" bit check and recent commits added it for NEXT_HOP, MULTI_EXIT_DISC and ATOMIC_AGGREGATE cases. This commit adds "partial" check for AS_PATH and LOCAL_PREF cases, which should leave attributes 1 through 6 inclusive completely covered with attribute flags checks. * bgp_attr.c * bgp_attr_origin(): use bit-by-bit checks for better diagnostics * bgp_attr_aspath(): add flag check * bgp_attr_local_pref(): idem Conflicts: bgpd/bgp_attr.c
2011-09-30bgpd: improve NEXT_HOP attribute checks (BZ#680)Denis Ovsienko
* lib/prefix.h * IPV4_CLASS_DE(): new helper macro * bgp_attr.c * bgp_attr_nexthop(): add check for "partial" bit, refresh flag error reporting, explain meaning of RFC4271 section 6.3 and implement it Conflicts: bgpd/bgp_attr.c
2011-09-29bgpd: rename SAFI 3 according to RFC4760Denis Ovsienko
- SAFI value 3 is reserved. It was assigned by RFC 2858 for a use that was never fully implemented, so it is deprecated by this document. * zebra.h: rename macro * bgp_fsm.c: (bgp_graceful_restart_timer_expire, bgp_graceful_stale_timer_expire, bgp_stop, bgp_establish): update * bgpd.c: (peer_nsf_stop): update * bgp_open.c: (bgp_capability_vty_out): SAFI 3 isn't a recognized case any more
2011-09-29bgpd: more SAFI fixesDenis Ovsienko
(with resolved conflict in bgpd/bgp_packet.c) Two macros resolving to the same integer constant broke a case block and a more thorough merge of BGP_SAFI_VPNV4 and BGP_SAFI_VPNV6 was performed. * bgpd.h: MPLS-labeled VPN SAFI is AFI-independent, switch to single * macro * bgp_capability_test.c: update test data * bgp_mp_attr_test.c: idem * bgp_route.c: (bgp_maximum_prefix_overflow, bgp_table_stats_vty) update macro and check conditions (where appropriate) * bgp_packet.c: (bgp_route_refresh_send, bgp_capability_send, bgp_update_receive, bgp_route_refresh_receive): idem * bgp_open.c: (bgp_capability_vty_out, bgp_afi_safi_valid_indices, bgp_open_capability_orf, bgp_open_capability): idem * bgp_attr.c: (bgp_mp_reach_parse, bgp_packet_attribute, bgp_packet_withdraw): idem
2011-09-29bgpd: fix SAFI for for MPLS labeled VPN-IPv6Denis Ovsienko
* bgpd.h: change value of BGP_SAFI_VPNV6 to 128 (RFC4659, BZ#659) * bgp_route.c: (bgp_table_stats_vty) fix length argument to strncmp()