mirror of
				https://git.proxmox.com/git/mirror_frr
				synced 2025-10-30 19:39:50 +00:00 
			
		
		
		
	bgpd: fix bgpd core when unintern attr
When the remote peer is neither EBGP nor confed, aspath is the shadow copy of attr->aspath in bgp_packet_attribute(). Striping AS4_PATH should not be done on the aspath directly, since that would lead to bgpd core dump when unintern the attr. Signed-off-by: Yuan Yuan <yyuanam@amazon.com>
This commit is contained in:
		
							parent
							
								
									147c7a2de3
								
							
						
					
					
						commit
						32af4995aa
					
				| @ -4682,6 +4682,10 @@ bgp_size_t bgp_packet_attribute(struct bgp *bgp, struct peer *peer, | ||||
| 		 * there! (JK) | ||||
| 		 * Folks, talk to me: what is reasonable here!? | ||||
| 		 */ | ||||
| 
 | ||||
| 		/* Make sure dup aspath before the modification */ | ||||
| 		if (aspath == attr->aspath) | ||||
| 			aspath = aspath_dup(attr->aspath); | ||||
| 		aspath = aspath_delete_confed_seq(aspath); | ||||
| 
 | ||||
| 		stream_putc(s, | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 Yuan Yuan
						Yuan Yuan