Hi, Jibran
Sorry for cutting in.
FYI, in RYU, you can decode your OpenFlow message like this:
@set_ev_cls(ofp_event.EventOFPPacketIn, MAIN_DISPATCHER)
def _packet_in_handler(self, ev):
msg = ev.msg.to_jsondict()
print(json.dumps(msg, indent=4))
And you can get:
{
"OFPPacketIn": {
"total_len": 42,
"buffer_id": 4294967295,
"reason": 0,
"cookie": 0,
"table_id": 0,
"data":
"////////AAAAAAABCAYAAQgABgQAAQAAAAAAAQoAAAEAAAAAAAAKAAAC",
"match": {
"OFPMatch": {
"type": 1,
"length": 12,
"oxm_fields": [
{
"OXMTlv": {
"field": "in_port",
"mask": null,
"value": 1
}
}
]
}
}
}
}
Thanks,
Fujimoto
On 2017年04月10日 04:32, Jibran Ahmed wrote:
Thank you very much for the information Bill!
Jibran
On Apr 9, 2017, at 3:19 PM, William Fisher
<william.w.fis...@gmail.com <mailto:william.w.fis...@gmail.com>> wrote:
The data field is the packet data for the Packet-In message in hex. I
took the data snippet from your message (with python string escapes)
and entered the following in a python 2.7 interpreter:
data='\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\x00\x02\x08\x00E\x10\x00D\x84u@\x00@\x06\xa2,\n\x00\x00\x02\n\x00\x00\x01\xb8\xfd\x00P\x19\xb9\\\xe6\xa1^+U\x80\x18\x00:\xd6\x9d\x00\x00\x01\x01\x08\n\x00U\xe4J\x00U\xd8\x9fGET
/ HTTP/1.0\r\n'
import binascii
binascii.hexlify(data)
'000000000001000000000002080045100044847540004006a22c0a0000020a000001b8fd005019b95ce6a15e2b558018003ad69d00000101080a0055e44a0055d89f474554202f20485454502f312e300d0a'
-Bill
On Sun, Apr 9, 2017 at 11:53 AM, Jibran Ahmed <ahme...@husky.neu.edu
<mailto:ahme...@husky.neu.edu>> wrote:
Hello Bill,
Thank you for your response! The output is very similar to our
requirement!
Could you please tell me how the data field was populated?
Thanks once again!
Jibran
------------------------------------------------------------------------------
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
------------------------------------------------------------------------------
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