Rich Lane | b1f347d | 2013-05-16 16:39:12 -0700 | [diff] [blame] | 1 | -- binary |
| 2 | 01 0e 00 70 12 34 56 78 |
| 3 | 00 00 00 0c 00 03 01 23 |
| 4 | 45 67 89 ab cd ef 01 23 |
| 5 | 45 67 00 00 00 00 00 00 |
| 6 | 00 00 00 00 c0 a8 03 7f |
| 7 | ff ff ff ff 00 00 00 00 |
| 8 | 00 00 00 00 00 00 00 00 |
| 9 | 00 00 00 05 00 00 00 00 |
| 10 | 00 00 00 00 00 00 00 02 |
| 11 | 00 00 00 08 ff fb 00 00 |
| 12 | ff ff 00 10 00 00 23 20 |
| 13 | 00 12 00 00 00 00 00 00 |
| 14 | ff ff 00 10 00 5c 16 c7 |
| 15 | 00 00 00 02 00 00 00 00 |
| 16 | -- python |
| 17 | ofp.message.flow_add( |
| 18 | xid=0x12345678, |
| 19 | match=ofp.match( |
| 20 | wildcards=ofp.OFPFW_DL_SRC|ofp.OFPFW_DL_DST, |
| 21 | in_port=3, |
| 22 | ipv4_src=0xc0a8037f, |
| 23 | ipv4_dst=0xffffffff, |
| 24 | eth_src=[0x01, 0x23, 0x45, 0x67, 0x89, 0xab], |
| 25 | eth_dst=[0xcd, 0xef, 0x01, 0x23, 0x45, 0x67]), |
| 26 | idle_timeout=5, |
| 27 | flags=ofp.OFPFF_CHECK_OVERLAP, |
| 28 | actions=[ |
| 29 | ofp.action.output(port=ofp.OFPP_FLOOD), |
| 30 | ofp.action.nicira_dec_ttl(), |
| 31 | ofp.action.bsn_set_tunnel_dst()]) |
| 32 | -- python pretty-printer |
| 33 | flow_add { |
| 34 | xid = 0x12345678, |
| 35 | match = match_v1 { |
| 36 | wildcards = OFPFW_DL_SRC|OFPFW_DL_DST, |
| 37 | in_port = 3, |
| 38 | eth_src = 01:23:45:67:89:ab, |
| 39 | eth_dst = cd:ef:01:23:45:67, |
| 40 | vlan_vid = 0x0, |
| 41 | vlan_pcp = 0x0, |
| 42 | eth_type = 0x0, |
| 43 | ip_dscp = 0x0, |
| 44 | ip_proto = 0x0, |
Rob Sherwood | 6798fff | 2013-06-11 14:46:20 -0700 | [diff] [blame] | 45 | src_meta_id = 0x0, |
| 46 | dst_meta_id = 0x0, |
Rich Lane | b1f347d | 2013-05-16 16:39:12 -0700 | [diff] [blame] | 47 | ipv4_src = 192.168.3.127, |
| 48 | ipv4_dst = 255.255.255.255, |
| 49 | tcp_src = 0x0, |
| 50 | tcp_dst = 0x0 |
| 51 | }, |
| 52 | cookie = 0x0, |
| 53 | idle_timeout = 0x5, |
| 54 | hard_timeout = 0x0, |
| 55 | priority = 0x0, |
| 56 | buffer_id = 0x0, |
| 57 | out_port = 0, |
| 58 | flags = 0x2, |
| 59 | actions = [ |
| 60 | output { port = OFPP_FLOOD, max_len = 0x0 }, |
| 61 | nicira_dec_ttl { }, |
| 62 | bsn_set_tunnel_dst { dst = 0x0 } |
| 63 | ] |
| 64 | } |