Malformed UPDATE message

1,594 views
Skip to first unread message

Mehdi Rukmawan

unread,
Apr 23, 2018, 8:05:55 AM4/23/18
to exabgp-users
Hello,

I'm trying to announce full internet routes with exabgp into gns3.
here's the ini file

neighbor 172.16.100.1 {
router-id 172.16.100.2;
local-address 172.16.100.2;
local-as 1234;
peer-as 5678;
graceful-restart;

process announce-routes {
run ./usr/bin/python /home/ubuntu/fullbgptable.py;
}
}

neighbour is establish and no receiving prefix from exabgp.
and there's log just like this

RP/0/0/CPU0:Apr 23 05:38:14.819 : bgp[1051]: %ROUTING-BGP-3-MALFORM_UPDATE : Malformed UPDATE message received from neighbor 172.16.100.2 (VRF: default) - message length 78 bytes, error flags 0x00000200, action taken "TreatAsWdr". Error details: "Error 0x00000200, Field "Attr-data", Attribute 2 (Flags 0x40, Length 30), Data [40021e02070000b34800001b1b000060]". NLRIs: [IPv4 Unicast] 193.177.168.0/21

is there anyone here know what is the problem ?

note:
i'm using exabgp version 4 and 3 both have the same log above
the neighbour is using ios XRV 6.0.1

thanks is advance

Thomas Mangin

unread,
Apr 23, 2018, 8:39:36 AM4/23/18
to exabgp...@googlegroups.com
Hello Mehdi,

From the error the issue is the AS-Path (Attribute 2) - can I please have the output of exabgp with the -d flag to get 
 - the open negotiation
 - the packet exchanged

I am not aware of any issue with that code but it could be that you have an ibgp session where the first ASN is not the local-as as ExaBGP will let you do that.

Thomas



--
You received this message because you are subscribed to the Google Groups "exabgp-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to exabgp-users+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Mehdi Rukmawan

unread,
Apr 23, 2018, 9:29:03 AM4/23/18
to exabgp-users
Hello Thomas,

Attached the output.

my configuration is just exabgp -- xrv 6.0.1
no ibgp after xrv.


thanks for replying Thomas.
To unsubscribe from this group and stop receiving emails from it, send an email to exabgp-users...@googlegroups.com.
exabgp log.log

Thomas Mangin

unread,
Apr 23, 2018, 3:15:27 PM4/23/18
to exabgp...@googlegroups.com
Hello,

The logs for 193.177.168.0/21 which caused the issue would have been good ..
That said, I will come back to my previous comment as it should have said EBGP and not IBGP - typo - which is what you configured.
As it did not seem to help, here is a longer answer (now that I have a few minutes).
(sent) OPEN version=4 asn=3491 hold_time=180 router_id=172.16.100.2 capabilities=[Multiprotocol(ipv4 unicast,ipv4 multicast,ipv4 nlri-mpls,ipv4 mpls-vpn,ipv4 rtc,ipv4 flow,ipv4 flow-vpn,ipv6 unicast,ipv6 multicast,ipv6 nlri-mpls,ipv6 mpls-vpn,ipv6 flow,ipv6 flow-vpn,l2vpn vpls,l2vpn evpn,bgp-ls bgp-ls,bgp-ls bgp-ls-vpn), ASN4(3491)]
(recv) OPEN version=4 asn=7632 hold_time=180 router_id=10.10.10.1 capabilities=[Multiprotocol(ipv4 unicast), Route Refresh, ASN4(7632), Route Refresh]
Your ASN is 3491 but the routes your are advertising does not have this ASN at the start of the AS-PATH.
The first route sent has 45896, which is likely why the other side refuse the UPDATE as ExaBGP does NOT modify the AS-PATH on EBGP connection.

The relevant RFC section is:

5.1.2.  AS_PATH

   [...]

   When a BGP speaker propagates a route it learned from another BGP
   speaker's UPDATE message, it modifies the route's AS_PATH attribute
   based on the location of the BGP speaker to which the route will be
   sent:

      a) [...]

      b) When a given BGP speaker advertises the route to an external
         peer, the advertising speaker updates the AS_PATH attribute as
         follows:

         1) if the first path segment of the AS_PATH is of type
            AS_SEQUENCE, the local system prepends its own AS number as
            the last element of the sequence (put it in the leftmost
            position with respect to the position of octets in the
            protocol message).  [...]
which is then redefined by RFC 7606 (which your router supports as it speaks of treat-as-withdraw)
7.2.  AS_PATH

   An AS_PATH is considered malformed if an unrecognized segment type is
   encountered or if it contains a malformed segment.  A segment is
   considered malformed if any of the following are true: [...]

   An UPDATE message with a malformed AS_PATH attribute SHALL be handled
   using the approach of "treat-as-withdraw".

   [RFC4271] also says that an implementation optionally "MAY check
   whether the leftmost ... AS in the AS_PATH attribute is equal to the
   autonomous system number of the peer that sent the message".  A BGP
   implementation SHOULD also handle routes that violate this check
   using "treat-as-withdraw" but MAY follow the "session reset" behavior
   if configured to do so.
So depending on the implementation:
 - (1) this route will be accepted as valid (as it is only a SHOULD test - ie not mandatory) or;
 - (2) this route will be removed from the peer RIB (treat-as-withdraw) or;
 - (3) this route may trigger the session between the peer to drop !

Your vendor picked option 2

Have fun,

Thomas


To unsubscribe from this group and stop receiving emails from it, send an email to exabgp-users+unsubscribe@googlegroups.com.

Mehdi Rukmawan

unread,
Apr 23, 2018, 8:12:46 PM4/23/18
to exabgp-users
Hello Thomas,

Thanks a lot.
Now i'm able to receiving the routes after i'm change the ASN neighbour

172.16.100.2      0 45896    3051      18     3956    0    0 00:01:01       3936

prefix still increasing, again thank you very much

regards,
Reply all
Reply to author
Forward
0 new messages