As discussed in [1] placing strict validation around the attributes of this request is likely dangerous at this point in time as extensions maybe adding additional attrs that would then be blocked. If we can get some stricter versioning in place we can revisit this one. Please see discussion in [1] for more details.
Marking this as 'won't fix' for now. Please reopen if there's additional discussion to be had or if versioning is in place to support more strict validation of the request body. [1] https://review.openstack.org/402339/ ** Changed in: neutron Status: In Progress => Won't Fix -- You received this bug notification because you are a member of Yahoo! Engineering Team, which is subscribed to neutron. https://bugs.launchpad.net/bugs/1644708 Title: Unrecognized parameters are not blocked in 'fixed_ips' of Port Status in neutron: Won't Fix Bug description: No errors are returned even though there are unrecognized parameter in Dict for 'fixed_ips'. Environment ----------- master Expected behavior ----------------- It is hard to notice that the request is wrong. Thus, it should be returned 400 error so that user can understand the request is wrong. How to reproduce ----------------- Create/Update port with fixed_ips parameter that is contained unrecognized parameter. "a" is unrecognized parameter in case below. ubuntu@neutron-ml2:/opt/stack/neutron$ curl -i -X PUT -H "X-Auth-Token: $TOKEN" http://172.16.1.29:9696/v2.0/ports/42bff786-a7fd-4631-8416-83052d078389 -d '{"port": {"fixed_ips":[{"a":"a", "ip_address":"192.168.0.15"}]}}' HTTP/1.1 200 OK Content-Type: application/json Content-Length: 906 X-Openstack-Request-Id: req-f6b46c50-6f98-470c-a3ea-17eacf765603 Date: Fri, 25 Nov 2016 05:40:59 GMT {"port": {"allowed_address_pairs": [{"ip_address": "1.1.1.1", "mac_address": "aa:aa:aa:aa:aa:aa"}], "extra_dhcp_opts": [], "updated_at": "2016-11-25T05:40:59Z", "device_owner": "", "revision_number": 9, "binding:profile": {"\u3042": "a"}, "port_security_enabled": true, "fixed_ips": [{"subnet_id": "b89324b7 -4f6c-47b0-a874-601a345a11e2", "ip_address": "192.168.0.15"}], "id": "42bff786-a7fd-4631-8416-83052d078389", "security_groups": ["e2238dd0-01b2-44a2-a9b3-08e8d2163de5"], "binding:vif_details": {}, "binding:vif_type": "unbound", "mac_address": "fa:16:3e:2d:95:8d", "project_id": "d713c7d4c02541d8b239d6d9761768e5", "status": "DOWN", "binding:host_id": "", "description": "", "device_id": "", "name": "", "admin_state_up": true, "network_id": "af5370f1-a37d-4b36-900e- 4aa6aa939fef", "tenant_id": "d713c7d4c02541d8b239d6d9761768e5", "created_at": "2016-11-17T09:06:35Z", "binding:vnic_type": "normal"}} To manage notifications about this bug go to: https://bugs.launchpad.net/neutron/+bug/1644708/+subscriptions -- Mailing list: https://launchpad.net/~yahoo-eng-team Post to : yahoo-eng-team@lists.launchpad.net Unsubscribe : https://launchpad.net/~yahoo-eng-team More help : https://help.launchpad.net/ListHelp