Hi,
I am running ExaBGP from a Mininet node and modified the simple_switch_13
app to parse the BGP messages received from a peer. However, I can
correctly parse the IP and TCP fields of the packet, while the BGP part
returns *None:*
*The code:*
def parse_packet(self,message):
pkt = packet.Packet(message.data)
ip = pkt.get_protocol(ipv4.ipv4)
total_len = ip.total_length
ttl = ip.ttl
self.logger.info("Packet Total length: %s", total_len)
self.logger.info("Packet TTL: %s", ttl)
tcp_protocol = pkt.get_protocol(tcp.tcp)
src_port = tcp_protocol.src_port
dst_port = tcp_protocol.dst_port
self.logger.info("TCP source port: %s", src_port)
self.logger.info("TCP destination port: %s", dst_port)
bgp_protocol = pkt.get_protocol(bgp.BGPMessage)
if bgp_protocol == None:
self.logger.info("BGP is None")
else:
bgp_length = bgp_protocol.len
bgp_type = bgp_protocol.type
self.logger.info("BGP length: %s", bgp_length)
self.logger.info("BGP type: %s", bgp_type)
*The output:*
Packet Total length: 1297
Packet TTL: 64
TCP source port: 179
TCP destination port: 55083
BGP is None
Can someone help me to address this problem?
Thank you in advance,
--
Ricardo Bennesby da Silva
Ciência da Computação - UFAM
LabCIA - Laboratório de Computação Inteligente e Autonômica
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Ryu-devel mailing list
Ryu-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ryu-devel