summaryrefslogtreecommitdiffhomepage
AgeCommit message (Collapse)Author
2014-01-15safi: add a constant for route target constrainYAMAMOTO Takashi
Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-15rest_firewall: support IPv6 match conditionsYuichi Ito
this patch gets rest_firewall to support IPv6 match conditions. 'ipv6_src' and 'ipv6_dst' are allowed as key. 'ICMPv6' is allowed as the value of 'nw_proto'. e.g.) curl -X POST -d '{"ipv6_src": "10::/64"}' http://localhost:8080/firewall/rules/0000000000000001 curl http://localhost:8080/firewall/rules/0000000000000001 [ { "access_control_list": [ { "rules": [ { "priority": 1, "dl_type": "IPv6", "ipv6_src": "10::/64", "rule_id": 1, "actions": "ALLOW" } ] } ], "switch_id": "0000000000000001" } ] Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-15ofctl_v1_2/3: fix match conditions about ARPYuichi Ito
ofctl_v1_0 has changed nw_src/dst into ipv4_src/dst or arp_spa/tpa automatically like ovs-ofctl. since ofctl_v1_2/3 change nw_src/dst only into ipv4_src/dst, it cannot create the match conditions which use arp_spa/tpa. this patch fixes this problem. before applying this patch (using ofctl_rest): curl -X POST -d '{"dpid": 1, "match": {"dl_type": 2048, "nw_src": "192.168.0.0/24"}, "actions": [{"type": "OUTPUT", "port": 2}]}' http://localhost:8080/stats/flowentry/add OFPST_FLOW reply (OF1.3) (xid=0x2): cookie=0x0, duration=3.602s, table=0, n_packets=0, n_bytes=0, priority=0,ip,nw_src=192.168.0.0/24 actions=output:2 curl -X POST -d '{"dpid": 1, "match": {"dl_type": 2054, "nw_src": "192.168.0.0/24"}, "actions": [{"type": "OUTPUT", "port": 2}]}' http://localhost:8080/stats/flowentry/add no flow entry was installed. after applying this patch (using ofctl_rest): curl -X POST -d '{"dpid": 1, "match": {"dl_type": 2048, "nw_src": "192.168.0.0/24"}, "actions": [{"type": "OUTPUT", "port": 2}]}' http://localhost:8080/stats/flowentry/add OFPST_FLOW reply (OF1.3) (xid=0x2): cookie=0x0, duration=3.602s, table=0, n_packets=0, n_bytes=0, priority=0,ip,nw_src=192.168.0.0/24 actions=output:2 curl -X POST -d '{"dpid": 1, "match": {"dl_type": 2054, "nw_src": "192.168.0.0/24"}, "actions": [{"type": "OUTPUT", "port": 2}]}' http://localhost:8080/stats/flowentry/add OFPST_FLOW reply (OF1.3) (xid=0x2): cookie=0x0, duration=2.555s, table=0, n_packets=0, n_bytes=0, priority=0,arp,arp_spa=192.168.0.0/24 actions=output:2 Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-15enable OpenFlow 1.4FUJITA Tomonori
Adds the very basic features for L2 switch. Kinda simple_switch_14.py successfully works with LINC switch. - HELLO - FEATURES_REQUEST_REQUEST/REPLY - GET_CONFIG_REQUEST/REPLY - SET_CONFIG - PACKET_IN - MULTIPART_REQUEST/REPLY (only flow_stats) - PACKET_OUT - FLOW_MOD Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-14packet_data_generator: update of_protocol upstreamYAMAMOTO Takashi
merely a clean up for a pullup request. no functionality changes. also, update comments. Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-09test_bpdu: add unit testwatanabe.fumitaka
Signed-off-by: WATANABE Fumitaka <watanabe.fumitaka1@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-09bpdu: handling based on version and typewatanabe.fumitaka
In bpdu.py only one version was permitted with one type, before. This patch improves parser so that it may be based on multiple versions and types. Signed-off-by: WATANABE Fumitaka <watanabe.fumitaka1@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-09ofctl_rest: improve readability of the result of MeterFeaturesYuichi Ito
although 'band_types' of MeterFeatures were bitmaps of supported band types, it was expressed numerically. this patch makes 'band_types' human-readable. e.g.) curl http://localhost:8080/stats/meterfeatures/8796750050962 { "8796750050962": [ { "max_meter": 16777216, "max_color": 0, "max_band": 255, "band_types": ["DROP", "DSCP_REMARK"] } ] } Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-09ofctl_rest: support group-related messagesYuichi Ito
this patch makes ofctl_rest possible to: - support the GROUP action in the FlowMod message - support the GroupMod message - support the GroupStats message - support the GroupFeatures message - support the GroupDesc message see following examples. FlowMod with the group action: e.g.) curl -X POST -d '{"dpid": 1, "match": {}, "actions": [{"type": "GROUP, "group_id": 1}]}' http://localhost:8080/stats/flowentry/add GroupMod: usage) URI: /stats/groupentry/{cmd} METHOD: POST NOTE: the value of 'cmd' is one of follows: 'add', 'modify', or 'delete'. the message body is as follows: type Group types. 'ALL', 'SELECT', 'INDIRECT', or 'FF'. group_id Group Identifier. (default: 0) buckets a list of buckets. where each bucket has the following members: weight Relative weight of bucket. (default: 0) watch_port Port whose state affects whether this bucket is live. (default: OFPP_ANY) watch_group Group whose state affects whether this bucket is live. (default: OFPG_ANY) actions a list of actions. the format is the same as that of FlowMod. e.g.) curl -X POST -d '{"dpid": 1, "type": "FF", "group_id": 1, "buckets": [{"watch_port": 2, "actions": [{"type": "OUTPUT", "port": 3}]}]}' http://localhost:8080/stats/groupentry/add GroupStats: usage) URI: /stats/group/{dpid} METHOD: GET e.g.) curl http://localhost:8080/stats/group/1 { "1": [ { "bucket_stats": [ { "packet_count": 0, "byte_count": 0 } ], "byte_count": 0, "ref_count": 0, "duration_nsec": 231000000, "packet_count": 0, "duration_sec": 11238, "group_id": 1 } ] } GroupFeatures: usage) URI: /stats/groupfeatures/{dpid} METHOD: GET e.g.) curl http://localhost:8080/stats/groupfeatures/1 { "1": [ { "actions": [ {"ALL": ["OUTPUT", "COPY_TTL_OUT", "COPY_TTL_IN", "SET_MPLS_TTL", "DEC_MPLS_TTL", "PUSH_VLAN", "POP_VLAN", "PUSH_MPLS", "POP_MPLS", "SET_QUEUE", "GROUP", "SET_NW_TTL", "DEC_NW_TTL", "SET_FIELD"]}, {"SELECT": []}, {"INDIRECT": []}, {"FF": []} ], "max_groups": [ {"ALL": 4294967040}, {"SELECT": 4294967040}, {"INDIRECT": 4294967040}, {"FF": 4294967040} ], "capabilities": ["SELECT_WEIGHT", "SELECT_LIVENESS", "CHAINING"], "types": [] } ] } GroupDesc: usage) URI: /stats/groupdesc/{dpid} METHOD: GET e.g.) curl http://localhost:8080/stats/groupdesc/1 { "1": [ { "buckets": [ { "actions": ["OUTPUT:2"], "watch_group": 4294967295, "weight": 0, "watch_port": 3 } ], "group_id": 1, "type": "FF" } ] } Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-09lib.of_config: import ryu.contribYAMAMOTO Takashi
import ryu.contrib by ourself for the benefit of programs which doesn't use other ryu.contrib stuffs like oslo.config. Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-09tests: add some tests for ryu.lib.of_config.classesYAMAMOTO Takashi
Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-09A happy new year 2014YAMAMOTO Takashi
Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-07Ryu 3.5FUJITA Tomonori
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-07firewall: correct acquisition result of DENY rulewatanabe.fumitaka
When blocked packet logging is enabled, GET rest command shows DENY rules as 'ALLOW' before. This patch improves it. Signed-off-by: WATANABE Fumitaka <watanabe.fumitaka1@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-07ofctl_rest: fix mod_meter_entry in OpenFlow1.0/1.2Yuichi Ito
mod_meter_entry causes the following error when the protocol version is 1.0 or 1.2. AttributeError: 'module' object has no attribute 'OFPMC_ADD' this patch fixes this problem. Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-06ofctl_rest: support OFPExperimenter messageYuichi Ito
this patch makes ofctl_rest enable use of OFPExperimenter message. usage) URI: /stats/experimenter/{dpid} method: POST the message body is as follows: experimenter Experimenter ID. (default: 0) exp_type Experimenter defined type. (default:0) data_type Data encoding type. 'ascii' or 'base64'. (default: 'ascii') data Experimenter-defined arbitrary additional data. (default: '') e.g.) curl -X POST -d '{"experimenter": 8992, "exp_type": 10, "data": "\x00\x00\x00\x01"}' http://localhost:8080/stats/experimenter/1 curl -X POST -d '{"experimenter": 8992, "exp_type": 10. "data_type": "base64", "data": "AAAAAQ=="}' http://localhost:8080/stats/experimenter/1 Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-06ofctl_rest: fix delete_flow_entryYuichi Ito
Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-06topology: Setting highest rule priority to LLDP packetsSrini Seetharaman
Signed-off-by: Srini Seetharaman <srini.seetharaman@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-06Fix Windows setup dependency bugWei-Li Tang
The hook raises an AttributeError exception on Windows because of recent changes in the pbr project. This fix solves the issue. This is adapted from https://review.openstack.org/#/c/42170/ Since ryu didn't depend on pyudev, I think it no longer needs a removal here. Signed-off-by: Wei-Li Tang <alextwl@xinguard.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2014-01-06add IGMP snooping applicationYuichi Ito
this application provides the simple example of IGMP snooping. the module "igmplib" mainly offers 2 functions: - listening on in the IGMP conversation between multicast routers and hosts - emulating of the querier function of multicast servers the former operates a switch as a snooping switch and controls transmission of an unnecessary multicasting packet. the latter realizes the IGMP conversation in the environment without multicast routers. the module "simple_switch_igmp" is a variation of "simple_switch". the switch receives the "EventPacketIn" event instead of the "EventOFPPacketIn" event from the module "igmplib" in order to except IGMP. Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-29packet lib: icmpv6: support MLD (v1/v2)Yuichi Ito
Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-29packet lib: igmp: support IGMP v3Yuichi Ito
Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-27firewall: packet blocking log for DENY rulewatanabe.fumitaka
rest_firewall outputs packet blocking log. However it was not output about DENY rules, it outputted only table-miss packets. This patch improves it. Signed-off-by: WATANABE Fumitaka <watanabe.fumitaka1@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-27ofctl_v1_2/3: support IPv6Yuichi Ito
this patch implements the match conditions using IPv6. NOTE: OpenFlow1.0 does not support IPv6. e.g. using ofctl_rest) curl -X POST -d '{"dpid": 1, "match": {"eth_type": 34525, "ipv6_src": "fe08:2001::/64", "ipv6_dst": "ff02::1"}, "actions": [{"type": "OUTPUT", "port": 2}]}' http://localhost:8080/stats/flowentry/add Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com>
2013-12-27ofctl_v1_2/3: support OXM field namesYuichi Ito
this patch gets match field names to support OXM field names. NOTE: OpenFlow1.0 does not support OXM field names. the compatibility is as follows: dl_src eth_src dl_dst eth_dst dl_type eth_type dl_vlan vlan_vid nw_src ipv4_src nw_dst ipv4_dst nw_proto ip_proto tp_src tcp_src or udp_src tp_dst tcp_dst or udp_dst for example, the following commands for ofctl_rest install the same flow entry. curl -X POST -d '{"dpid": 1, "match": {"dl_type": 2048, "nw_src": "192.168.1.1"}, "actions": [{"type": "OUTPUT", "port": 2}]}' http://localhost:8080/stats/flowentry/add curl -X POST -d '{"dpid": 1, "match": {"eth_type": 2048, "ipv4_src": 192.168.1.1"}, "actions": [{"type": "OUTPUT", "port": 2}]}' http://localhost:8080/stats/flowentry/add Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com>
2013-12-27ofctl_rest: support OpenFlow1.2Yuichi Ito
this patch makes ofctl_rest enable use of OpenFlow1.2. Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com>
2013-12-25of_config_cli: remove no longer necessary "_pythonify" stuffYAMAMOTO Takashi
Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-25of_config: allows both of of-config element names and python style namesYAMAMOTO Takashi
for convenience of api consumers, allows both of of-config style element names (eg. logical-switches) and python style attribute names (eg. logical_switches). Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-25of_config_cli: add add_queue commandYAMAMOTO Takashi
totally untested as i have no access to switches which support the operation. Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-25of_config_cli: add delete_config and copy_configYAMAMOTO Takashi
Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-25a simple of-config client commandYAMAMOTO Takashi
the placement (ryu/tests/bin) was suggested by FUJITA Tomonori. Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-25of_config.capable_switch: add delete_config and copy_configYAMAMOTO Takashi
Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-25tests.integrated.test_of_config: update after capable_switch api changeYAMAMOTO Takashi
Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-25of_config.capable_switch: api tweakYAMAMOTO Takashi
tweak method to take of_config.classes classes instead of xml. Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-25add some convenient OF-Config classesYAMAMOTO Takashi
some python classes for a set of OF-Config 1.1.1 types. the goal is to allow programmers use OF-Config without direct XML manipulations. Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-25requires lxmlYAMAMOTO Takashi
will be used for OF-Config stuff. Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-25oxm_fields: make a crash less crypticYAMAMOTO Takashi
when oxm length is not what we expect, explicitly raise an exception with descriptive message like the following. Exception: Unexpected OXM payload length 3 for ipv6_flabel (expected 4) This often happens if you are using LINC and IPv6. https://github.com/FlowForwarding/of_protocol/pull/57 Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-24ofctl_v1_3: support OFPMeterConfigStatsYuichi Ito
Changes v2 -> v3: - correct the following description this patch implements a REST API for OFPMeterConfigStats. e.g., when you send a MeterMod message as: curl -X POST -d '{"dpid": 1, "meter_id": 1, "flags": "KBPS", "bands": [{"type": "DROP", "rate": 1000}, {"type": "REMARK", "rate": 2000}, {"type": "EXPERIMENTER", "rate": 3000} ]}' http://localhost:8080/stats/meterentry/add and you do the following command: curl http://localhost:8080/stats/meterconfig/1 then you will get the configuration as: {"1": [{"bands": [{"burst_size": 0, "rate": 1000, "type": "DROP"}, {"prec_level": 0, "burst_size": 0, "rate": 2000, "type": "REMARK"}, {"burst_size": 0, "rate": 3000, "experimenter": 0, "type": "EXPERIMENTER"}], "flags": "KBPS", "meter_id": 1}]} Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-24ofctl_v1_3: fix match for metadataSrini Seetharaman
also use the default priority for FlowMod. Signed-off-by: Srini Seetharaman <srini.seetharaman@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-20ofctl_v1_3: correct MeterStats and MeterFeaturesYuichi Ito
- add the insufficient handlers - correct the using instance Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-20topology: add of13 supportSrini Seetharaman
Signed-off-by: Srini Seetharaman <srini.seetharaman@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-20ofctl_v1_3: support meterYuichi Ito
Support meter in FlowMod instructions and support MeterMod, MeterStats, MeterFeatures. see following examples. FlowMod with the meter instruction: flow = {'match': {}, 'actions': [{'type': 'METER', 'meter_id': 1}] curl -X POST -d '{"dpid": 1, "match": {}, "actions": [{"type": "METER", "meter_id": 1}]}' http://localhost:8080/stats/flowentry/add MeterMod: meter = {'meter_id': 1, 'flags': 'KBPS', 'bands': [{'type': 'DROP', 'rate': 1000}]} curl -X POST -d '{"dpid": 1, "meter_id": 1, "flags": "KBPS", "bands": [{"type": "DROP", "rate": 1000}]}' http://localhost:8080/stats/meterentry/add NOTE: flags: 'KBPS', 'PKTPS', 'BURST', 'STATS' type: 'DROP', 'REMARK', 'EXPERIMENTER' MeterStats: curl http://localhost:8080/stats/meter/1 MetetFeatures: curl http://localhost:8080/stats/meterfeatures/1 Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-20ofctl_v1_3: support metadataYuichi Ito
Support metadata in FlowMod instructions and match. both a decimal number and a hexadecimal number are able to use in 'metadata' and 'metadata_mask'. all the following examples express the same flow entry. flow = {'match': {'metadata': '12345/4095'}, 'actions': [{'type': 'WRITE_METADATA', 'metadata': '12345', 'metadata_mask': '4095'}]} flow = {'match': {'metadata': '12345/4095'}, 'actions': [{'type': 'WRITE_METADATA', 'metadata': 12345, 'metadata_mask': 4095}]} flow = {'match': {'metadata': '0x3039/0xfff'}, 'actions': [{'type': 'WRITE_METADATA', 'metadata': '0x3039', 'metadata_mask': '0xfff'}]} Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-18packet.ospf: workaround a bytearray vs buffer problemYAMAMOTO Takashi
feeding bytearray to struct.unpack() crashes on some environment. (depends on the interpreter versions? i'm not sure.) this fixes the following crash in the unit test. the crash was seen on travis-ci, too. https://travis-ci.org/osrg/ryu/jobs/15578909 https://s3.amazonaws.com/archive.travis-ci.org/jobs/15578909/log.txt ====================================================================== ERROR: test_hello (packet.test_ospf.Test_ospf) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/yamamoto/git/ryu/ryu/tests/unit/packet/test_ospf.py", line 68, in test_hello msg2, cls, rest = ospf.OSPFMessage.parser(binmsg) File "/Users/yamamoto/git/ryu/ryu/lib/packet/ospf.py", line 443, in parser kwargs = subcls.parser(binmsg) File "/Users/yamamoto/git/ryu/ryu/lib/packet/ospf.py", line 501, in parser n = addrconv.ipv4.bin_to_text(n) File "/Users/yamamoto/git/ryu/ryu/lib/addrconv.py", line 30, in bin_to_text return str(self._addr(self._strat.packed_to_int(bin), File "/Users/yamamoto/git/ryu/.venv/lib/python2.7/site-packages/netaddr/strategy/ipv4.py", line 196, in packed_to_int return _struct.unpack('>I', packed_int)[0] error: unpack requires a string argument of length 4 ---------------------------------------------------------------------- Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-17rest_firewall: use the explicit max_len of flow_modYuichi Ito
rest_firewall had used the max_len value of flow_mod message which ofctl_v1_x specified. in response to change ofctl_v1_x, rest_firewall gets to use the specified max_len explicitly. Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-17lib: ofctl: support the specified max_len of flow_modYuichi Ito
this patch makes the max_len of flow_mod message more flexible. before applying this patch: ofctl_v1_0: 128 bytes for packet_in (fixed size) and none for others (fixed) ofctl_v1_2: 128 bytes for packet_in (fixed size) and 0 for others (fixed size) ofctl_v1_3: 0 for all by default (flexible) ofctl_v1_3 will send 0 byte length data in a packet_in message if max_len is not specified. after applying this patch: all version: MAX_LEN for all by default (flexible) NOTE: MAX_LEN is 65535 for OF1.0, and is OFPCML_MAX for OF1.2/1.3. max_len is omissible by every ofctl. Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-17packet lib: improve readability of jsonYuichi Ito
this patch makes some json members of several packet libraries human-readable. ex) ethernet.ethernet before applying this patch: {'ethernet': {'ethertype': 2048, 'dst': 'ZmY6ZmY6ZmY6ZmY6ZmY6ZmY=', 'src': 'MDA6MDA6MDA6MDA6MDA6MDA='}} after applying this patch: {'ethernet': {'ethertype': 2048, 'dst': u'ff:ff:ff:ff:ff:ff', 'src': u'00:00:00:00:00:00'}} Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-13add license to ospf filesFUJITA Tomonori
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-13test tool: add a script to make the test environment on mininetYuichi Ito
What this patch implements: This patch implements a script that provides the simple test environment that includes 2 switches and 2 links for the test tool as follows: +-----------+ +----------| target sw | The OpenFlow switch to be tested (Open vSwitch) | +-----------+ +------------+ (1) (2) | controller | | | +------------+ (1) (2) | +-----------+ +----------| tester sw | OpenFlow Switch (Open vSwitch) +-----------+ (X) : port number How to run: Do the following command: sudo ryu/tests/switch/run_mininet.py And then, run the test tool at another terminal: ryu-manager ryu/tests/switch/tester.py Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-13test tool: add default test files (match)Yuichi Ito
What this patch implements: This patch implements the test files for the test tool. These test files aim to examine 'match' of FlowMod message. Signed-off-by: WATANABE Fumitaka <watanabe.fumitaka@nttcom.co.jp> Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>