[CONTROLLER-1315] restconf allows alphabetical characters and non-numerical symbols for the flow id field Created: 13/May/15  Updated: 25/Jul/23  Resolved: 14/May/15

Status: Resolved
Project: controller
Component/s: restconf
Affects Version/s: None
Fix Version/s: None

Type: Bug
Reporter: Ryan Goulding Assignee: Unassigned
Resolution: Cannot Reproduce Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Operating System: All
Platform: All


External issue ID: 3207

 Description   

Alphabetical characters and non-numerical symbol are inappropriately allowed as flow ID. There is potential for exploitation with characters such as '$' and '@'. Thus, flow IDs like 'abc', or '---' are accepted by restconf.

An example of a REST PUT call utilizing "---" as the flow ID that was accepted by the controller is shown below:

PUT http://<controller-ip>:8181/restconf/config/opendaylight-inventory:nodes/node/openflow:1/table/0/flow/--- d '<?xml version="1.0" encoding="UTF-8" standalone="no"?><flow xmlns="urn:opendaylight:flow:inventory"><hard-timeout>0</hard-timeout><idle-timeout>0</idle-timeout><priority>2</priority><flow-name>flow1</flow-name><match><ethernet-match><ethernet-type><type>2048</type></ethernet-type></ethernet-match><ipv4-destination>10.0.0.1/32</ipv4-destination></match><id>--</id><table_id>0</table_id><instructions><instruction><order>0</order><apply-actions><action><output-action><output-node-connector>1</output-node-connector></output-action><order>0</order></action></apply-actions></instruction></instructions></flow>'



 Comments   
Comment by Tony Tkacik [ 14/May/15 ]

id in openflow model is modeled as string, so openflow model allows such keys and is correct for restconf to accept them.

Marking is as Resolved - INVALID - since Restconf is behaving correctly according
to model of flow.

If you still see this as a bug, please open issue against openflowplugin with your
rationale why id in flow model should be changed to number instead of string.

Could you please elaborate how characters such "$" or "@" may present security flaw?

Restconf / MD-SAL / Clustering / Netconf is not interpreting this characters and treats them as pure strings.

Generated at Wed Feb 07 19:55:13 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.