Skip to content

Instantly share code, notes, and snippets.

@shun159
Last active December 23, 2015 07:59
Show Gist options
  • Save shun159/6604955 to your computer and use it in GitHub Desktop.
Save shun159/6604955 to your computer and use it in GitHub Desktop.
ARPデータの配列版です。

An ARP Reply From Host

[ 0x11,0x22,0x33,0x44,0x55,0x66,0x5c,0x9a,0xd8,0xea,0x37,0x32,0x08,0x06,0x00,0x01,0x08,0x00,0x06,0x04,0x00,0x02,0x5c,0x9a,0xd8,0xea,0x37,0x32,0xc0,0xa8,0x00,0x01,0x11,0x22,0x33,0x44,0x55,0x66,0xc0,0xa8,0x00,0xfe ]

An ARP Request From Host

[ 0xff,0xff,0xff,0xff,0xff,0xff,0x5c,0x9a,0xd8,0xea,0x37,0x32,0x08,0x06,0x00,0x01,0x08,0x00,0x06,0x04,0x00,0x01,0x5c,0x9a,0xd8,0xea,0x37,0x32,0xc0,0xa8,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xa8,0x00,0xfe ]

An ARP Request From OpenFlowSwitch

[ 0xff,0xff,0xff,0xff,0xff,0xff,0x11,0x22,0x33,0x44,0x55,0x66,0x08,0x06,0x00,0x01,0x08,0x00,0x06,0x04,0x00,0x01,0x11,0x22,0x33,0x44,0x55,0x66,0xc0,0xa8,0x00,0xfe,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xa8,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 ]
@yasuhito
Copy link

テストケースに追加したところ、すべてうまくパースできたようです。

https://github.com/shun159/pio/commit/e12f67c95f110af1093a071ce64109d3cf13eb7c

@shun159
Copy link
Author

shun159 commented Sep 18, 2013

有難うございます!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment