mirror_frr/ospfd
rgirada ef151af79b ospfd: crash when router acts as GR helper upon a topo change
Description:
	ospf process is crashing when  the current router acts
	as GR helper and it received a new lsa.

	Here, ospf_lsa_different() is being called without checking
	'old' pointer. It is asserted in ospf_lsa_different() api
	if the 'old' pointer is NULL.

	corrected this by validaing old pointer before calling
	ospf_lsa_different() api.

	back tarce:
	Program terminated with signal SIGABRT, Aborted.
	0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
	[Current thread is 1 (Thread 0x6b84348827c0 (LWP 3155))]
	0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
	1  0x00006b8433aa4801 in __GI_abort () at abort.c:79
	2  0x00006b8433a9439a in __assert_fail_base (fmt=0x6b8433c1b7d8 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x162ffc0630bc "l1", file=file@entry=0x162ffc062ff7 "ospfd/ospf_lsa.c", line=line@entry=3520, function=function@entry=0x162ffc0646f0 <__PRETTY_FUNCTION__.18732> "ospf_lsa_different") at assert.c:92
	3  0x00006b8433a94412 in __GI___assert_fail (assertion=assertion@entry=0x162ffc0630bc "l1", file=file@entry=0x162ffc062ff7 "ospfd/ospf_lsa.c", line=line@entry=3520, function=function@entry=0x162ffc0646f0 <__PRETTY_FUNCTION__.18732> "ospf_lsa_different") at assert.c:101
	4  0x0000162ffc008c25 in ospf_lsa_different (l1=l1@entry=0x0, l2=l2@entry=0x162ffe535c60, ignore_rcvd_flag=ignore_rcvd_flag@entry=true) at ospfd/ospf_lsa.c:3520
	5  0x0000162ffc00a8e8 in ospf_lsa_install (ospf=ospf@entry=0x162ffe513650, oi=oi@entry=0x162ffe531c30, lsa=lsa@entry=0x162ffe535c60) at ospfd/ospf_lsa.c:2892
	6  0x0000162ffc059d16 in ospf_flood (ospf=0x162ffe513650, nbr=nbr@entry=0x162ffe52cc90, current=current@entry=0x0, new=new@entry=0x162ffe535c60) at ospfd/ospf_flood.c:429
	7  0x0000162ffc01838f in ospf_ls_upd (size=<optimized out>, oi=0x162ffe531c30, s=<optimized out>, ospfh=<optimized out>, iph=<optimized out>, ospf=<optimized out>) at ospfd/ospf_packet.c:2162
	8  ospf_read_helper (ospf=<optimized out>) at ospfd/ospf_packet.c:3241
	9  ospf_read (thread=<optimized out>) at ospfd/ospf_packet.c:3272
	10 0x00006b843450139c in thread_call (thread=thread@entry=0x7780f42c7480) at lib/thread.c:1692
	11 0x00006b84344cfb18 in frr_run (master=0x162ffe34d130) at lib/libfrr.c:1068

Signed-off-by: Rajesh Girada <rgirada@vmware.com>
2022-08-30 00:48:32 -07:00
..
.gitignore *: cleanup .gitignore files 2018-09-08 21:30:42 +02:00
ChangeLog.opaque.txt Initial revision 2003-02-03 16:31:16 +00:00
Makefile build: non-recursive ospf* 2017-08-04 11:09:50 +02:00
ospf_abr.c ospfd: changes code maintainability 2022-08-19 12:45:16 +05:30
ospf_abr.h ospfd: fix NSSA translator 2020-11-18 23:23:14 -08:00
ospf_api.c ospfd: add router id support to ospf api 2022-06-23 05:01:40 -04:00
ospf_api.h ospfd: add router id support to ospf api 2022-06-23 05:01:40 -04:00
ospf_apiserver.c ospfd: changes for code maintainability 2022-08-22 12:48:35 +05:30
ospf_apiserver.h ospfd: add router id support to ospf api 2022-06-23 05:01:40 -04:00
ospf_asbr.c *: Properly use memset() when zeroing 2022-05-11 14:08:47 +03:00
ospf_asbr.h ospfd: adjust type of "aggr_delay_interval" 2022-01-28 20:11:40 -05:00
ospf_ase.c ospfd: changes for code maintainability 2022-08-28 20:48:29 +05:30
ospf_ase.h *: reindent 2017-07-17 14:04:07 +02:00
ospf_bfd.c ospfd: set/unset bfd profile 2022-06-30 10:56:34 +03:00
ospf_bfd.h ospfd: rework BFD integration 2021-03-23 10:18:42 -03:00
ospf_dump_api.c ospfd: replace inet_ntoa 2020-10-22 13:37:25 -04:00
ospf_dump_api.h *: use C99 standard fixed-width integer types 2018-03-27 15:13:34 -04:00
ospf_dump.c bgpd, ospfd: Remove extra newline for show debugging 2022-06-15 10:34:30 -04:00
ospf_dump.h ospfd: cli: add client api debug option 2022-06-01 18:11:31 -04:00
ospf_errors.c ospfd: Add Segment Routing Local Block 2020-08-20 14:37:40 +02:00
ospf_errors.h ospfd: Add Segment Routing Local Block 2020-08-20 14:37:40 +02:00
ospf_ext.c *: Properly use memset() when zeroing 2022-05-11 14:08:47 +03:00
ospf_ext.h ospfd: Add Segment Routing Local Block 2020-08-20 14:37:40 +02:00
ospf_flood.c ospfd: changes for code maintainability 2022-08-28 20:48:29 +05:30
ospf_flood.h ospfd: introduce support for Graceful Restart (restarting mode) 2021-07-05 11:43:02 -03:00
ospf_gr_helper.c *: remove the checking returned value for hash_get() 2022-05-03 00:41:48 +08:00
ospf_gr.c ospfd: Remove various macros that overlap THREAD_OFF 2022-07-21 08:27:35 -04:00
ospf_gr.h ospfd: introduce support for Graceful Restart (restarting mode) 2021-07-05 11:43:02 -03:00
ospf_ia.c ospfd: changes for code maintainability 2022-08-22 18:23:04 +05:30
ospf_ia.h *: reindent 2017-07-17 14:04:07 +02:00
ospf_interface.c ospfd: changes for code maintainability 2022-08-22 23:16:28 +05:30
ospf_interface.h ospfd: Refactor fifo_flush for the interface 2022-08-11 13:30:32 -04:00
ospf_ism.c ospfd: Remove various macros that overlap THREAD_OFF 2022-07-21 08:27:35 -04:00
ospf_ism.h ospfd: Remove various macros that overlap THREAD_OFF 2022-07-21 08:27:35 -04:00
ospf_ldp_sync.c ospfd: changes for code maintainability 2022-08-23 16:50:54 +05:30
ospf_ldp_sync.h ldpd, isisd, ospfd: Remove periodic ldp-sync hello message 2020-12-09 14:11:38 -05:00
ospf_lsa.c ospfd: crash when router acts as GR helper upon a topo change 2022-08-30 00:48:32 -07:00
ospf_lsa.h *: Change thread->func to return void instead of int 2022-02-23 19:56:04 -05:00
ospf_lsdb.c *: Properly use memset() when zeroing 2022-05-11 14:08:47 +03:00
ospf_lsdb.h ospfd: replace pqueue_* with DECLARE_SKIPLIST 2019-04-27 19:33:45 +02:00
ospf_main.c *: Convert quagga_signal_X to frr_signal_X 2021-11-11 14:41:27 -05:00
ospf_memory.c *: require semicolon after DEFINE_MTYPE & co 2021-03-17 06:18:17 +01:00
ospf_memory.h *: require semicolon after DEFINE_MTYPE & co 2021-03-17 06:18:17 +01:00
ospf_neighbor.c ospfd: Remove various macros that overlap THREAD_OFF 2022-07-21 08:27:35 -04:00
ospf_neighbor.h ospfd: rename the graceful restart header 2021-07-05 11:43:02 -03:00
ospf_network.c ospfd: don't exit when socket is not created 2021-07-27 16:10:35 +03:00
ospf_network.h ospfd: basic support for VRF NETNS backend 2018-02-27 11:11:24 +01:00
ospf_nsm.c ospfd: Refactor fifo_flush for the interface 2022-08-11 13:30:32 -04:00
ospf_nsm.h ospfd: Remove various macros that overlap THREAD_OFF 2022-07-21 08:27:35 -04:00
ospf_opaque.c ospfd: changes for code maintainability 2022-08-23 22:18:33 +05:30
ospf_opaque.h ospfd: api: fix recovery of LSA after restart of api client 2022-06-02 16:37:16 -04:00
ospf_packet.c ospfd: changes for code maintainability 2022-08-25 23:48:24 +05:30
ospf_packet.h *: Change thread->func to return void instead of int 2022-02-23 19:56:04 -05:00
ospf_ri.c *: Properly use memset() when zeroing 2022-05-11 14:08:47 +03:00
ospf_ri.h ospfd: Correct Coverity defects 2021-05-19 09:48:54 +02:00
ospf_route.c ospfd: changes for code maintainability 2022-08-26 13:01:37 +05:30
ospf_route.h ospfd: add all_rtrs route table when opaque enabled 2022-06-02 16:37:16 -04:00
ospf_routemap_nb_config.c *: make sure config.h or zebra.h is first 2021-04-23 12:06:35 +02:00
ospf_routemap_nb.c *: make sure config.h or zebra.h is first 2021-04-23 12:06:35 +02:00
ospf_routemap_nb.h ospfd: North-bound implementation for ospfd rmaps 2021-03-30 22:59:30 +03:00
ospf_routemap.c ospfd: don't use if_lookup_by_name_all_vrf 2021-10-15 03:44:42 +03:00
ospf_snmp.c *: Properly use memset() when zeroing 2022-05-11 14:08:47 +03:00
ospf_spf.c ospfd: changes for code maintainability 2022-08-28 20:48:29 +05:30
ospf_spf.h ospfd: add all_rtrs route table when opaque enabled 2022-06-02 16:37:16 -04:00
ospf_sr.c ospfd: Cleanup indentation surrounding oi->nbr 2022-08-11 13:30:32 -04:00
ospf_sr.h ospfd: validate input SRGB and SRLB 2021-09-28 10:40:32 +02:00
ospf_te.c *: Properly use memset() when zeroing 2022-05-11 14:08:47 +03:00
ospf_te.h ospfd: Add Link-State support 2021-03-23 15:39:29 +01:00
ospf_ti_lfa.c ospfd: add all_rtrs route table when opaque enabled 2022-06-02 16:37:16 -04:00
ospf_ti_lfa.h ospfd: Add support for TI-LFA node protection 2021-01-19 15:32:13 +00:00
ospf_vty.c ospfd: Adding per neighbour json details to GR helper detail command 2022-08-23 21:15:12 -07:00
ospf_vty.h ospfd: TI-LFA basic infrastructure and algorithms 2021-01-19 15:32:13 +00:00
ospf_zebra.c ospfd: Fixup ospfd.h to declare variable names 2022-06-08 11:38:22 -04:00
ospf_zebra.h ospfd: introduce support for Graceful Restart (restarting mode) 2021-07-05 11:43:02 -03:00
OSPF-ALIGNMENT.txt *: Remove cvs control points 2017-12-05 17:28:12 -05:00
ospfd.c ospfd: Convert thread_cancel to THREAD_OFF 2022-07-21 08:27:35 -04:00
ospfd.h ospfd: Remove various macros that overlap THREAD_OFF 2022-07-21 08:27:35 -04:00
subdir.am build: fix AM_LDFLAGS usage (and gcov) 2021-07-21 17:10:08 +02:00