]> git.proxmox.com Git - mirror_frr.git/log
mirror_frr.git
6 years agoMerge pull request #2447 from ajones-rvbd/ajones-issue-2391
Quentin Young [Fri, 15 Jun 2018 16:40:19 +0000 (12:40 -0400)]
Merge pull request #2447 from ajones-rvbd/ajones-issue-2391

alpine: add unit tests to build

6 years agoisisd: out-of-bounds access (Coverity 1399309)
paco [Fri, 15 Jun 2018 16:36:20 +0000 (18:36 +0200)]
isisd: out-of-bounds access (Coverity 1399309)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agoMerge pull request #2409 from LabNConsulting/working/master/vtysh-2400
Quentin Young [Fri, 15 Jun 2018 16:33:44 +0000 (12:33 -0400)]
Merge pull request #2409 from LabNConsulting/working/master/vtysh-2400

vtysh: -u fixes

6 years agoMerge pull request #2458 from pacovn/Coverity_1221437_Unchecked_return_value
Donald Sharp [Fri, 15 Jun 2018 14:53:58 +0000 (10:53 -0400)]
Merge pull request #2458 from pacovn/Coverity_1221437_Unchecked_return_value

ospf6d: unchecked return value (Coverity 1221437)

6 years agopimd: Untrusted val as argument (Coverity 1465491)
paco [Fri, 15 Jun 2018 10:57:47 +0000 (12:57 +0200)]
pimd: Untrusted val as argument (Coverity 1465491)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agoospf6d: unchecked return value (Coverity 1221437)
paco [Fri, 15 Jun 2018 11:08:37 +0000 (13:08 +0200)]
ospf6d: unchecked return value (Coverity 1221437)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agobgpd: out-of-bounds access (Coverity 1399306)
paco [Fri, 15 Jun 2018 10:39:10 +0000 (12:39 +0200)]
bgpd: out-of-bounds access (Coverity 1399306)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agobgpd: dead code (Coverity 1399373)
paco [Wed, 13 Jun 2018 09:35:01 +0000 (11:35 +0200)]
bgpd: dead code (Coverity 1399373)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agobgpd: Fix crash when showing filtered routes
Pascal Mathis [Thu, 14 Jun 2018 17:40:36 +0000 (19:40 +0200)]
bgpd: Fix crash when showing filtered routes

This commit fixes the issue mentioned in #2419, which is caused by a
double-free. The problem of the current implementation is that
*bgp_input_modifier* already frees the passed attributes under specific
circumstances, which can then lead to a double-free as *bgp_attr_undup*
does not check if the attributes are set to NULL.

As it is not transparent to the function caller if the attributes get
freed or not and the similar function *bgp_output_modifier* also does
not flush the passed attributes, the line has been removed altogether.

All callers of *bgp_input_modifier* already deal by themself with
freeing/flushing/unduping BGP attributes, so it is safe to remove.

Signed-off-by: Pascal Mathis <mail@pascalmathis.com>
6 years agoMerge pull request #2426 from pacovn/Coverity_23089_Buffer_not_null_terminated
Rafael Zalamena [Thu, 14 Jun 2018 21:02:34 +0000 (18:02 -0300)]
Merge pull request #2426 from pacovn/Coverity_23089_Buffer_not_null_terminated

ospfd: buffer termination (Coverity 23089)

6 years agoMerge pull request #2438 from pacovn/Coverity_1457300_Dereference_after_null_check
Rafael Zalamena [Thu, 14 Jun 2018 20:58:10 +0000 (17:58 -0300)]
Merge pull request #2438 from pacovn/Coverity_1457300_Dereference_after_null_check

ospfd: null check (Coverity 1457300)

6 years agoalpine: add unit tests to build
Arthur Jones [Fri, 8 Jun 2018 16:47:28 +0000 (09:47 -0700)]
alpine: add unit tests to build

Now that make check works on alpine, add it to the build

Testing done: alpine linux build -- check works

Issue: https://github.com/FRRouting/frr/issues/2391

Signed-off-by: Arthur Jones <arthur.jones@riverbed.com>
6 years agoospfd: OoB access (Cov 1452454 1452455 1452456)
paco [Thu, 14 Jun 2018 17:19:44 +0000 (19:19 +0200)]
ospfd: OoB access (Cov 1452454 1452455 1452456)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agoMerge pull request #2422 from pacovn/Coverity_23201_Dereference_before_null_check
Donald Sharp [Thu, 14 Jun 2018 17:03:50 +0000 (13:03 -0400)]
Merge pull request #2422 from pacovn/Coverity_23201_Dereference_before_null_check

bgpd: null check (Coverity 23201)

6 years agobgpd: Finalize group-overrides for peer/AF attrs
Pascal Mathis [Thu, 14 Jun 2018 16:03:33 +0000 (18:03 +0200)]
bgpd: Finalize group-overrides for peer/AF attrs

This commit finalizes the previous commits which introduced a generic
approach for making all BGP peer and address-family attributes
overrideable by keeping track of the configuration origin in separate
internal structures.

First of all, the test suite was greatly extended to also check the
internal data structures of peer/AF attributes, so that inheritance for
internal values like 'peer->weight' is also being checked in all cases.

This revealed some smaller issues in the implementation, which were also
fixed in this commit. The test suite now fully passes and covers all the
usual situations that should normally occur.

Signed-off-by: Pascal Mathis <mail@pascalmathis.com>
6 years agobgpd: Implement group-overrides for peer attrs
Pascal Mathis [Wed, 13 Jun 2018 17:34:17 +0000 (19:34 +0200)]
bgpd: Implement group-overrides for peer attrs

This commit introduces BGP peer-group overrides for the last set of
peer-level attrs which did not offer that feature yet. The following
attributes have been implemented: description, local-as, password and
update-source.

Each attribute, with the exception of description because it does not
offer any inheritance between peer-groups and peers, is now also setting
a peer-flag instead of just modifying the internal data structures. This
made it possible to also re-use the same implementation for attribute
overrides as already done for peer flags, AF flags and AF attrs.

The `no neighbor <neigh> description` command has been slightly changed
to support negation for no parameters, one parameter or * parameters
(LINE...). This was needed for the test suite to pass and is a small
change without any bigger impact on the CLI.

Signed-off-by: Pascal Mathis <mail@pascalmathis.com>
6 years agobgpd: Implement group-overrides for peer timers
Pascal Mathis [Wed, 13 Jun 2018 00:34:43 +0000 (02:34 +0200)]
bgpd: Implement group-overrides for peer timers

This commit implements BGP peer-group overrides for the timer flags,
which control the value of the hold, keepalive, advertisement-interval
and connect connect timers. It was kept separated on purpose as the
whole timer implementation is quite complex and merging this commit
together with with the other flag implementations did not seem right.

Basically three new peer flags were introduced, namely
*PEER_FLAG_ROUTEADV*, *PEER_FLAG_TIMER* and *PEER_FLAG_TIMER_CONNECT*.
The overrides work exactly the same way as they did before, but
introducing these flags made a few conditionals simpler as they no
longer had to compare internal data structures against eachother.

Last but not least, the test suite has been adjusted accordingly to test
the newly implemented flag overrides.

Signed-off-by: Pascal Mathis <mail@pascalmathis.com>
6 years agobgpd: Improve test suite for peer-group overrides
Pascal Mathis [Tue, 12 Jun 2018 22:39:19 +0000 (00:39 +0200)]
bgpd: Improve test suite for peer-group overrides

This commit introduces the current test suite for BGP peer-group
overrides by adding support for custom check handlers (which can check
internal data structures more thoroughly) and by fixing several small
mistakes and issues that slipped through. Also some parts of the code
have been cleaned up to avoid duplicate and/or hard-to-read code.

Additionally a first experimental check for a BGP peer attribute with
values (advertisement-interval <value>) has been added to the test
suite. As this test suite is currently not passing, it has not been
added to the python test caller.

Signed-off-by: Pascal Mathis <mail@pascalmathis.com>
6 years agobgpd: Cleanup peer/AF-flag override implementation
Pascal Mathis [Tue, 12 Jun 2018 16:50:51 +0000 (18:50 +0200)]
bgpd: Cleanup peer/AF-flag override implementation

This commit cleans up some ugly leftovers from previous flag-override
implementation and refactors the AF-flag override implementation to
match the same behavior the newly added peer-flag override
implementation has.

Signed-off-by: Pascal Mathis <mail@pascalmathis.com>
6 years agobgpd: Fix AF-attribute overrides when binding peer
Pascal Mathis [Tue, 12 Jun 2018 15:09:49 +0000 (17:09 +0200)]
bgpd: Fix AF-attribute overrides when binding peer

The current implementation of the overrides for peer address-family
attributes suffered a bug, which caused all peer-specific attributes to
be lost when the peer was added to a peer-group which already had that
specific address-family active.

This commit extends the *peer_group2peer_config_copy_af* function to
respect overridden flags properly. Additionally, the arguments of the
macros *PEER_ATTR_INHERIT* and *PEER_STR_ATTR_INHERIT* have been
reordered to be more consistent and easy to read.

This commit also adds further test cases to the BGP peer attributes test
suite, so that this kind of error is being caught in future commits. The
missing AF-attribute *distribute-list* has also been added to the test
suite.

Signed-off-by: Pascal Mathis <mail@pascalmathis.com>
6 years agobgpd: Implement group-overrides for peer flags
Pascal Mathis [Mon, 11 Jun 2018 17:49:20 +0000 (19:49 +0200)]
bgpd: Implement group-overrides for peer flags

The current implementation of peer flags (e.g. shutdown, passive, ...)
only has partial support for overriding flags of a peer-group when the
peer is a member. Often settings might get lost if the user toys around
with the peer-group configuration, which can lead to disaster.

This commit introduces the same override implementation which was
previously integrated to support proper peer flag/attribute override on
the address-family level. The code is very similar and the global
attributes now use their separate state-arrays *flags_invert* and
*flags_override*.

The test suite for BGP peer attributes was extended to also check peer
global attributes, so that the newly introduced changes are covered. An
additional feature was added which allows to test an attribute with an
*interface-peer*, which can be configured by running `neighbor IF-TEST
interface`. This was introduced so that the dynamic runtime inversion of
the `extended-nexthop` flag, which is only enabled by default for
interface peers, can also be tested.

Last but not least, two small changes have been made to the current bgpd
implementation:

- The command `strict-capability-match` can now also be set on a
peer-group, it seems like this command slipped through while
implementing peer-groups in the very past.

- The macro `COND_FLAG` was introduced inside lib/zebra.h, which now
allows to either set or unset a flag based on a condition. The syntax
for using this macro is: `COND_FLAG(flag_variable, flag, condition)`

Signed-off-by: Pascal Mathis <mail@pascalmathis.com>
6 years agoMerge pull request #2435 from pacovn/Coverity_1464993_Buffer_not_null_terminated
Renato Westphal [Thu, 14 Jun 2018 16:44:10 +0000 (13:44 -0300)]
Merge pull request #2435 from pacovn/Coverity_1464993_Buffer_not_null_terminated

ospfd: buffer termination (Coverity 1464993)

6 years agoospfd: buffer termination (Coverity 23089)
paco [Wed, 13 Jun 2018 12:43:18 +0000 (14:43 +0200)]
ospfd: buffer termination (Coverity 23089)

Details:
- INET_ADDRSTRLEN is 16, for xxx.xxx.xxx\0, so 15 is now passed
 to the strncpy call instead of 16, ensuring ASCII-z output

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agobgpd: null check (Coverity 23201)
paco [Wed, 13 Jun 2018 10:45:44 +0000 (12:45 +0200)]
bgpd: null check (Coverity 23201)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agoospfd: buffer termination (Coverity 1464993)
paco [Wed, 13 Jun 2018 15:24:51 +0000 (17:24 +0200)]
ospfd: buffer termination (Coverity 1464993)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agoMerge pull request #2430 from pacovn/clang_scan_ospf_dereference
Rafael Zalamena [Thu, 14 Jun 2018 14:14:52 +0000 (11:14 -0300)]
Merge pull request #2430 from pacovn/clang_scan_ospf_dereference

ospfd: dereference check (Clang scan-build)

6 years agoMerge pull request #2434 from pacovn/Coverity_1457145_Out-of-bounds_access
Rafael Zalamena [Thu, 14 Jun 2018 14:09:05 +0000 (11:09 -0300)]
Merge pull request #2434 from pacovn/Coverity_1457145_Out-of-bounds_access

lib: out-of-bounds access (Coverity 1457145)

6 years agoMerge pull request #2436 from pacovn/Coverity_1143220_Argument_cannot_be_negative
Donald Sharp [Thu, 14 Jun 2018 14:02:25 +0000 (10:02 -0400)]
Merge pull request #2436 from pacovn/Coverity_1143220_Argument_cannot_be_negative

tools: return check (Coverity 1143220)

6 years agoMerge pull request #2437 from pacovn/Coverity_1436343_Dereference_after_null_check
Rafael Zalamena [Thu, 14 Jun 2018 14:00:57 +0000 (11:00 -0300)]
Merge pull request #2437 from pacovn/Coverity_1436343_Dereference_after_null_check

lib: null check (Coverity 1436343)

6 years agoMerge pull request #2428 from donaldsharp/zserv_debug
Renato Westphal [Thu, 14 Jun 2018 13:43:40 +0000 (10:43 -0300)]
Merge pull request #2428 from donaldsharp/zserv_debug

zebra: Cleanup code to test for failure once

6 years agoMerge pull request #2410 from pacovn/Coverity_1448806_Out-of-bounds_access
Rafael Zalamena [Thu, 14 Jun 2018 13:29:35 +0000 (10:29 -0300)]
Merge pull request #2410 from pacovn/Coverity_1448806_Out-of-bounds_access

lib: Out-of-bounds access (Coverity 14488061448810)

6 years agoMerge pull request #2439 from chiragshah6/evpn_dev
Lou Berger [Thu, 14 Jun 2018 13:21:14 +0000 (09:21 -0400)]
Merge pull request #2439 from chiragshah6/evpn_dev

bgpd: Fix bgpd crash in evpn vni route-map apply

6 years agoMerge pull request #2441 from MasterofJOKers/workflow_pr_info_url
Donald Sharp [Thu, 14 Jun 2018 10:27:15 +0000 (06:27 -0400)]
Merge pull request #2441 from MasterofJOKers/workflow_pr_info_url

doc: Correct wiki URL in workflow-documentation

6 years agodoc: Correct wiki URL in workflow-documentation
MasterofJOKers [Thu, 14 Jun 2018 07:31:14 +0000 (09:31 +0200)]
doc: Correct wiki URL in workflow-documentation

The organization on github is called "FRRouting".

Signed-off-by: MasterofJOKers <joker@someserver.de>
6 years agolib: null check (Coverity 1436343)
paco [Wed, 13 Jun 2018 16:38:46 +0000 (18:38 +0200)]
lib: null check (Coverity 1436343)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agoMerge pull request #2431 from pacovn/Coverity_1399290_Out-of-bounds_access
Renato Westphal [Wed, 13 Jun 2018 17:49:52 +0000 (14:49 -0300)]
Merge pull request #2431 from pacovn/Coverity_1399290_Out-of-bounds_access

tools: out-of-bounds access (Coverity 1399290)

6 years agoMerge pull request #2416 from pacovn/Coverity_1399389_Structurally_dead_code
Donald Sharp [Wed, 13 Jun 2018 17:38:03 +0000 (13:38 -0400)]
Merge pull request #2416 from pacovn/Coverity_1399389_Structurally_dead_code

bgpd: dead code (Coverity 1399389)

6 years agobgpd: Fix bgpd crash in evpn vni route-map
Chirag Shah [Wed, 13 Jun 2018 05:13:05 +0000 (22:13 -0700)]
bgpd: Fix bgpd crash in evpn vni route-map

When evpn configured wiht route-map with vni which is not
configured. Upon receiving evpn routes (i.e Type-2, Type-3),
route-map match will be triggered. Since there is no l2vni
exists in db, some of the member fields in bgp_info (i.e.
dummy_info_extra) are passed uninitialized to evpn filter match cb.
This results in inaccessible memory causes crash.

Fix is to memset the bgp_info prior to passing to evpn filter cb.
In evpn vni filter cb, ensure to have NULL check for member filed
of the bgp_info.

memset bgp_info at few places where it is passed to route_match.

Ticket:CM-21335
Reviewed By:
Testing Done:

Configure route-map with not configured l2vni
Simulate to learn l2vpn type-2, 3 route

Restart frr.service with below config
address-family l2vpn evpn
  neighbor fear route-map EVPN_VNI out

route-map EVPN_VNI deny 10
 match evpn vni 140010

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
6 years agoospfd: null check (Coverity 1457300)
paco [Wed, 13 Jun 2018 17:04:43 +0000 (19:04 +0200)]
ospfd: null check (Coverity 1457300)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agobgpd: dead code removal (Coverity 1399389)
paco [Wed, 13 Jun 2018 09:09:17 +0000 (11:09 +0200)]
bgpd: dead code removal (Coverity 1399389)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agoMerge pull request #2424 from pacovn/Coverity_1399270_Dereference_after_null_check
Donald Sharp [Wed, 13 Jun 2018 16:13:57 +0000 (12:13 -0400)]
Merge pull request #2424 from pacovn/Coverity_1399270_Dereference_after_null_check

bgpd: null check (Coverity 1399270)

6 years agotools: return check (Coverity 1143220)
paco [Wed, 13 Jun 2018 16:07:36 +0000 (18:07 +0200)]
tools: return check (Coverity 1143220)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agobgpd: null check (Coverity 1399270)
paco [Wed, 13 Jun 2018 11:08:58 +0000 (13:08 +0200)]
bgpd: null check (Coverity 1399270)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agolib: out-of-bounds access (Coverity 1457145)
paco [Wed, 13 Jun 2018 15:08:38 +0000 (17:08 +0200)]
lib: out-of-bounds access (Coverity 1457145)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agoMerge pull request #2421 from pacovn/Coverity_1399232_Logically_dead_code
Donald Sharp [Wed, 13 Jun 2018 14:45:48 +0000 (10:45 -0400)]
Merge pull request #2421 from pacovn/Coverity_1399232_Logically_dead_code

ospfd: dead code (Coverity 1399232)

6 years agotools: out-of-bounds access (Coverity 1399290)
paco [Wed, 13 Jun 2018 14:33:51 +0000 (16:33 +0200)]
tools: out-of-bounds access (Coverity 1399290)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agoospfd: dereference check (Clang scan-build)
paco [Wed, 13 Jun 2018 13:49:36 +0000 (15:49 +0200)]
ospfd: dereference check (Clang scan-build)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agozebra: Cleanup code to test for failure once
Donald Sharp [Wed, 13 Jun 2018 13:19:37 +0000 (09:19 -0400)]
zebra: Cleanup code to test for failure once

Cleanup the zebra code to test for failure for reading
from stream once instead of once to see if we should
debug and once for the actual failure.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agoospfd: dead code (Coverity 1399232)
paco [Wed, 13 Jun 2018 10:34:23 +0000 (12:34 +0200)]
ospfd: dead code (Coverity 1399232)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agoMerge pull request #2420 from pacovn/Coverity_1399246_Logically_dead_code
Donald Sharp [Wed, 13 Jun 2018 12:08:45 +0000 (08:08 -0400)]
Merge pull request #2420 from pacovn/Coverity_1399246_Logically_dead_code

bgpd: dead code (Coverity 1399246)

6 years agobgpd: dead code (Coverity 1399246)
paco [Wed, 13 Jun 2018 10:25:45 +0000 (12:25 +0200)]
bgpd: dead code (Coverity 1399246)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agoMerge pull request #2414 from donaldsharp/bsd_failure
Rafael Zalamena [Tue, 12 Jun 2018 20:51:03 +0000 (17:51 -0300)]
Merge pull request #2414 from donaldsharp/bsd_failure

zebra: Fix compilation of bsd

6 years agoMerge pull request #2412 from opensourcerouting/lintian-warn-fix
Quentin Young [Tue, 12 Jun 2018 20:22:38 +0000 (16:22 -0400)]
Merge pull request #2412 from opensourcerouting/lintian-warn-fix

debianpkg: Add additional lintian override for Ubuntu 18.04

6 years agoMerge pull request #2407 from donaldsharp/bgp_spelunk
Rafael Zalamena [Tue, 12 Jun 2018 20:11:15 +0000 (17:11 -0300)]
Merge pull request #2407 from donaldsharp/bgp_spelunk

Bgp crash fix for topotests

6 years agoMerge pull request #2411 from qlyoung/fix-vtysh-config-write
Rafael Zalamena [Tue, 12 Jun 2018 19:59:35 +0000 (16:59 -0300)]
Merge pull request #2411 from qlyoung/fix-vtysh-config-write

vtysh: fix config write

6 years agozebra: Fix compilation of bsd
Donald Sharp [Tue, 12 Jun 2018 19:50:39 +0000 (15:50 -0400)]
zebra: Fix compilation of bsd

Actually return a value.

Fixes: #2413
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agobgpd: Ensure that bgp_delete bgp pointer is non-null
Donald Sharp [Tue, 12 Jun 2018 19:10:01 +0000 (15:10 -0400)]
bgpd: Ensure that bgp_delete bgp pointer is non-null

Crash w/ an assert if someone calls bgp_delete with a
NULL parameter as opposed to crashing when we dereference
the pointer a bit later.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agobgpd: bgp_default may be null
Donald Sharp [Wed, 23 May 2018 18:54:30 +0000 (14:54 -0400)]
bgpd: bgp_default may be null

The bgp_default variable when saved to the side might actually
be NULL.

Ticket: CM-21119
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agobgpd: Fix crash when shutdown
Donald Sharp [Tue, 22 May 2018 00:13:27 +0000 (20:13 -0400)]
bgpd: Fix crash when shutdown

The process of BGP shutdown hard free's memory irrelevant to
the fact that another process may be using that memory still
in route leaking scenario's.

As a temporary fix find the default instance and free it
last.

Ticket: CM-21068
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agobgpd: Move extra free code and fix a bug.
Donald Sharp [Tue, 12 Jun 2018 14:38:37 +0000 (10:38 -0400)]
bgpd: Move extra free code and fix a bug.

The bgp_info_extra_free code was the correct place to free
up data associated with the bgp_info pointer when we are
deleting the bgp_info node.

Additionally, if we have a parent pointer, we may not have a net
pointer.  So make sure we do.

Finally clean up the bgp_info_extra_free code so it is a bit
easier to read.  Use variables instead of multiple level
of casting.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agodebianpkg: Add additional lintian override for Ubuntu 18.04
Martin Winter [Tue, 12 Jun 2018 19:06:00 +0000 (12:06 -0700)]
debianpkg: Add additional lintian override for Ubuntu 18.04

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
6 years agovtysh: fix config write
Quentin Young [Tue, 12 Jun 2018 18:14:52 +0000 (18:14 +0000)]
vtysh: fix config write

Changing vtysh to use vty_out() for everything broke writing to config
files.

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
6 years agolib: OoB access (Coverity 1448806, 1448810)
paco [Tue, 12 Jun 2018 17:16:39 +0000 (19:16 +0200)]
lib: OoB access (Coverity 14488061448810)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agovtysh: in user mode, don't show 'enable not allowed', also block writeconfig
Lou Berger [Tue, 12 Jun 2018 16:33:25 +0000 (12:33 -0400)]
vtysh: in user mode, don't show 'enable not allowed', also block writeconfig

Signed-off-by: Lou Berger <lberger@labn.net>
6 years agoMerge pull request #2402 from qlyoung/germx-hand-sanitizer-kills-99-percent-of-germs
Jafar Al-Gharaibeh [Tue, 12 Jun 2018 16:11:55 +0000 (11:11 -0500)]
Merge pull request #2402 from qlyoung/germx-hand-sanitizer-kills-99-percent-of-germs

*: disable all sanitizers for clippy build

6 years agoMerge pull request #2379 from qlyoung/docuser
Jafar Al-Gharaibeh [Tue, 12 Jun 2018 16:04:26 +0000 (11:04 -0500)]
Merge pull request #2379 from qlyoung/docuser

Improve introductory user docs

6 years agoMerge pull request #2384 from qlyoung/docs-bgp-update
Jafar Al-Gharaibeh [Tue, 12 Jun 2018 15:57:36 +0000 (10:57 -0500)]
Merge pull request #2384 from qlyoung/docs-bgp-update

doc: massive cleanup of bgp.rst

6 years agoMerge pull request #2392 from chiragshah6/evpn_dev
Lou Berger [Tue, 12 Jun 2018 15:50:43 +0000 (11:50 -0400)]
Merge pull request #2392 from chiragshah6/evpn_dev

bgpd: accept vni rd_rt command for default vrf only

6 years agoMerge pull request #2399 from pacovn/Coverity_1469894_Dereference_null_return_value
Donald Sharp [Tue, 12 Jun 2018 15:50:18 +0000 (11:50 -0400)]
Merge pull request #2399 from pacovn/Coverity_1469894_Dereference_null_return_value

lib: null return value check (Coverity 1469894)

6 years agoMerge pull request #2404 from pacovn/Coverity_1455338_Dereference_null_return_value
Donald Sharp [Tue, 12 Jun 2018 14:47:48 +0000 (10:47 -0400)]
Merge pull request #2404 from pacovn/Coverity_1455338_Dereference_null_return_value

eigrpd: null return value check (Coverity 1455338)

6 years agoMerge pull request #2406 from pacovn/Coverity_1465495_Out-of-bounds_read
Rafael Zalamena [Tue, 12 Jun 2018 14:45:11 +0000 (11:45 -0300)]
Merge pull request #2406 from pacovn/Coverity_1465495_Out-of-bounds_read

zebra: Out-of-bounds read (Coverity 1465495)

6 years agolib: null return value check (Coverity 1469894)
paco [Mon, 11 Jun 2018 18:14:59 +0000 (20:14 +0200)]
lib: null return value check (Coverity 1469894)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agoMerge pull request #2405 from pacovn/Coverity_1399236_Logically_dead_code
Donald Sharp [Tue, 12 Jun 2018 13:59:37 +0000 (09:59 -0400)]
Merge pull request #2405 from pacovn/Coverity_1399236_Logically_dead_code

ospfd: logically dead code (Coverity 1399236)

6 years agoeigrpd: null return value check (Coverity 1455338)
paco [Tue, 12 Jun 2018 12:31:14 +0000 (14:31 +0200)]
eigrpd: null return value check (Coverity 1455338)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agozebra: Out-of-bounds read (Coverity 1465495)
paco [Tue, 12 Jun 2018 13:27:44 +0000 (15:27 +0200)]
zebra: Out-of-bounds read (Coverity 1465495)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agoospfd: logically dead code (Coverity 1399236)
paco [Tue, 12 Jun 2018 12:41:19 +0000 (14:41 +0200)]
ospfd: logically dead code (Coverity 1399236)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agoMerge pull request #2397 from pacovn/Coverity_1469896_Dereference_after_null_check
Quentin Young [Mon, 11 Jun 2018 20:30:49 +0000 (16:30 -0400)]
Merge pull request #2397 from pacovn/Coverity_1469896_Dereference_after_null_check

vtysh: null dereference (Coverity 1469896)

6 years agoMerge pull request #2398 from pacovn/Coverity_1469895_Dereference_after_null_check
Quentin Young [Mon, 11 Jun 2018 20:27:42 +0000 (16:27 -0400)]
Merge pull request #2398 from pacovn/Coverity_1469895_Dereference_after_null_check

lib: null dereference (Coverity 1469895)

6 years agoMerge pull request #2396 from pacovn/Coverity_1469897_1469893_Out-of-bounds_access
Quentin Young [Mon, 11 Jun 2018 19:48:10 +0000 (15:48 -0400)]
Merge pull request #2396 from pacovn/Coverity_1469897_1469893_Out-of-bounds_access

bgpd: OoB access (Coverity 14698971469893)

6 years agolib: null dereference (Coverity 1469895)
paco [Mon, 11 Jun 2018 18:02:58 +0000 (20:02 +0200)]
lib: null dereference (Coverity 1469895)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agovtysh: null dereference (Coverity 1469896)
paco [Mon, 11 Jun 2018 17:42:03 +0000 (19:42 +0200)]
vtysh: null dereference (Coverity 1469896)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agobgpd: OoB access (Coverity 1469897, 1469893)
paco [Mon, 11 Jun 2018 17:07:13 +0000 (19:07 +0200)]
bgpd: OoB access (Coverity 14698971469893)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agobgpd: accept vni rd_rt command for default vrf
Chirag Shah [Sat, 2 Jun 2018 00:52:14 +0000 (17:52 -0700)]
bgpd: accept vni rd_rt command for default vrf

L2VNI route-distinguisher and route-target configuartions
should only applied under DEFAULT VRF bgpd instance.

Add newline to each vni display.

router bgp 65006
  address-family l2vpn evpn
    vni 1000101
      route-target import 1:1000101

do not allow under
router bgp 65006 vrf RED

Ticket:CM-20204
Reviewed By:
Testing Done:

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
6 years agoMerge pull request #2390 from pacovn/Coverity_1221459_Use_after_free
Donald Sharp [Fri, 8 Jun 2018 18:57:02 +0000 (14:57 -0400)]
Merge pull request #2390 from pacovn/Coverity_1221459_Use_after_free

spf6d: fix use after free (Coverity 1221459)

6 years agoMerge pull request #2389 from pacovn/Coverity_1455482_Incorrect_sizeof_expression
Donald Sharp [Fri, 8 Jun 2018 18:36:42 +0000 (14:36 -0400)]
Merge pull request #2389 from pacovn/Coverity_1455482_Incorrect_sizeof_expression

lib: fix sizeof expression (Coverity 1455482)

6 years agoMerge pull request #2388 from pacovn/Coverity_1453454_Resource_leak
Donald Sharp [Fri, 8 Jun 2018 18:20:28 +0000 (14:20 -0400)]
Merge pull request #2388 from pacovn/Coverity_1453454_Resource_leak

zebra: resource leak fix (Coverity 1453454)

6 years agoMerge pull request #2387 from pacovn/Coverity_1465679_Resource_leak
Donald Sharp [Fri, 8 Jun 2018 18:14:57 +0000 (14:14 -0400)]
Merge pull request #2387 from pacovn/Coverity_1465679_Resource_leak

zebra: resource leak fix (Coverity 1465679)

6 years agoMerge pull request #2386 from gromit1811/pim-connected-nexthop-fix2
Donald Sharp [Fri, 8 Jun 2018 17:50:48 +0000 (13:50 -0400)]
Merge pull request #2386 from gromit1811/pim-connected-nexthop-fix2

pimd: Fix connected route nexthop fix from 66f5152f

6 years agospf6d: fix use after free (Coverity 1221459)
paco [Fri, 8 Jun 2018 17:46:48 +0000 (19:46 +0200)]
spf6d: fix use after free (Coverity 1221459)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agolib: fix sizeof expression (Coverity 1455482)
paco [Fri, 8 Jun 2018 17:30:32 +0000 (19:30 +0200)]
lib: fix sizeof expression (Coverity 1455482)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years ago*: disable all sanitizers for clippy build
Quentin Young [Fri, 8 Jun 2018 16:39:31 +0000 (16:39 +0000)]
*: disable all sanitizers for clippy build

* Move configure flag propagations out of user flags
* Use AC_SUBST to transfer flag values to Automake
* Set default AM_CFLAGS and AM_CPPFLAGS in common.am and change child
  Makefiles to modify these base variables
* Add flag override to turn off all sanitizers when building clippy
* Remove LSAN suppressions blacklist as it's no longer needed

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
6 years agozebra: resource leak fix (Coverity 1453454)
paco [Fri, 8 Jun 2018 17:18:49 +0000 (19:18 +0200)]
zebra: resource leak fix (Coverity 1453454)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agozebra: resource leak fix (Coverity 1465679)
paco [Fri, 8 Jun 2018 16:49:36 +0000 (18:49 +0200)]
zebra: resource leak fix (Coverity 1465679)

Signed-off-by: F. Aragon <paco@voltanet.io>
6 years agopimd: Fix connected route nexthop fix from 66f5152f
Martin Buck [Fri, 8 Jun 2018 16:26:39 +0000 (18:26 +0200)]
pimd: Fix connected route nexthop fix from 66f5152f

Fix a couple of problems in my 1st fix for PIM nexthops reachable via a
connected route:

Use NEXTHOP_TYPE_IPV4_IFINDEX instead of NEXTHOP_TYPE_IPV4 since we add an
IPv4 address to an already known ifindex.

Assign nexthop_tab[num_ifindex].protocol_distance and .route_metric before
incrementing num_ifindex.

Revert the default: to individual switch case statement conversion in
zclient_read_nexthop() as requested by donaldsharp in #2347

Signed-off-by: Martin Buck <mb-tmp-tvguho.pbz@gromit.dyndns.org>
6 years agoMerge pull request #2298 from qlyoung/pipe-actions-vtysh
Russ White [Fri, 8 Jun 2018 11:39:36 +0000 (07:39 -0400)]
Merge pull request #2298 from qlyoung/pipe-actions-vtysh

*: add support for `|` actions

6 years agoMerge pull request #2347 from gromit1811/pim-connected-nexthop-fix
Russ White [Fri, 8 Jun 2018 11:12:26 +0000 (07:12 -0400)]
Merge pull request #2347 from gromit1811/pim-connected-nexthop-fix

pimd: Fix nexthop determination when sending towards RP

6 years agoMerge pull request #2377 from ajones-rvbd/ajones-issue-2375
Russ White [Fri, 8 Jun 2018 11:07:25 +0000 (07:07 -0400)]
Merge pull request #2377 from ajones-rvbd/ajones-issue-2375

tests/isisd: bypass test_fuzz_isis_tlv when inet_ntop is broken

6 years agoMerge pull request #2380 from donaldsharp/pim_stuff
Russ White [Fri, 8 Jun 2018 11:06:19 +0000 (07:06 -0400)]
Merge pull request #2380 from donaldsharp/pim_stuff

pimd: Fix ecmp_enable and ecmp_rebalance_enable

6 years agoMerge pull request #2383 from donaldsharp/bgp_lunicast
Russ White [Fri, 8 Jun 2018 11:04:46 +0000 (07:04 -0400)]
Merge pull request #2383 from donaldsharp/bgp_lunicast

bgpd: Actually display labeled unicast routes received

6 years agoMerge pull request #2385 from donaldsharp/SA_SA_SA
Russ White [Fri, 8 Jun 2018 10:57:30 +0000 (06:57 -0400)]
Merge pull request #2385 from donaldsharp/SA_SA_SA

Some small clang 6.0 cleanups