From 8ebac84bc8d51e2404ce6d6dc5e35fb261830596 Mon Sep 17 00:00:00 2001 From: Maria Matejka Date: Wed, 20 Apr 2022 13:56:04 +0200 Subject: Moved advertising router info (FROM attribute) to eattrs --- proto/bgp/packets.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'proto/bgp') diff --git a/proto/bgp/packets.c b/proto/bgp/packets.c index 45a4b1de..9760ebee 100644 --- a/proto/bgp/packets.c +++ b/proto/bgp/packets.c @@ -2476,8 +2476,9 @@ bgp_decode_nlri(struct bgp_parse_state *s, u32 afi, byte *nlri, uint len, ea_lis a->source = RTS_BGP; a->scope = SCOPE_UNIVERSE; - a->from = s->proto->remote_ip; a->eattrs = ea; + + ea_set_attr_data(&a->eattrs, &ea_gen_from, 0, &s->proto->remote_ip, sizeof(ip_addr)); ea_set_attr_u32(&a->eattrs, &ea_gen_preference, 0, c->c.preference); c->desc->decode_next_hop(s, nh, nh_len, a); -- cgit v1.2.3