From 4cde7487d9791ebfc53a56ce1ea6993e4bd23f24 Mon Sep 17 00:00:00 2001 From: nikr <none@none> Date: Thu, 26 Mar 2015 13:31:29 +1300 Subject: [PATCH] OpenFlow() function to use changed OFv3 multipart message types. Openflow message type numberings changed with v3, OFPT_MULTIPART_REQUEST changed from 16 to 18, OFPT_MULTIPART_REPLY chaged from 17 to 19. --- scapy/contrib/openflow3.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scapy/contrib/openflow3.py b/scapy/contrib/openflow3.py index 64828722..ace4dd3d 100755 --- a/scapy/contrib/openflow3.py +++ b/scapy/contrib/openflow3.py @@ -3353,11 +3353,11 @@ def OpenFlow(self, payload): # err_type is a short int, but last byte is enough if err_type == 255: err_type = 65535 return ofp_error_cls[err_type] - elif of_type == 16: + elif of_type == 18: mp_type = ord(payload[9]) if mp_type == 255: mp_type = 65535 return ofp_multipart_request_cls[mp_type] - elif of_type == 17: + elif of_type == 19: mp_type = ord(payload[9]) if mp_type == 255: mp_type = 65535 return ofp_multipart_reply_cls[mp_type] -- GitLab