Here is what I confirmed.
- List networks It returns 401 when giving a wrong token.
$ curl -i -X GET -H "x-auth-token: dummy" http://192.168.122.111:9696/v2.0/networks HTTP/1.1 401 Unauthorized Content-Type: text/html; charset=UTF-8 Content-Length: 23 Www-Authenticate: Keystone uri='http://192.168.122.111:5000' X-Openstack-Request-Id: req-bd75e25a-b102-4ec2-a68e-7ea16feb05bf Date: Thu, 23 Jul 2015 11:55:32 GMT
- Create network It returns 400 when giving a bad request body.
$ curl -i -X POST -H "x-auth-token: $TOKEN" -H "content-type:application/jason" -d '{"network":{"dummy":"dummy"}}' http://192.168.122.111:9696/v2.0/networks HTTP/1.1 400 Bad Request Content-Length: 106 Content-Type: application/json; charset=UTF-8 X-Openstack-Request-Id: req-ba7ebf42-b1fb-48f8-bc34-62ac8408b9b1 Date: Thu, 23 Jul 2015 11:58:56 GMT
It returns 401 when giving a wrong token.
$ curl -i -X POST -H "x-auth-token: dummy" -H "content-type:application/jason" -d '{"network":{}}' http://192.168.122.111:9696/v2.0/networks HTTP/1.1 401 Unauthorized Content-Type: text/html; charset=UTF-8 Content-Length: 23 Www-Authenticate: Keystone uri='http://192.168.122.111:5000' X-Openstack-Request-Id: req-c4382d22-5ff6-415b-b8a3-98abada420e6 Date: Thu, 23 Jul 2015 12:00:00 GMT
- Show network details It returns 401 when giving a wrong token.
$ neutron net-list +--------------------------------------+----------+----------------------------------------------------------+ | id | name | subnets | +--------------------------------------+----------+----------------------------------------------------------+ | 0d4af632-5e88-4d9a-a155-3f1a64a49986 | private4 | a0a928f1-e057-4ecd-99d6-659fe2c950c5 fdc6:3c3c:39a7::/64 | | | | a9d8ad08-71f9-4a7b-82f1-9005ff24e7c1 10.0.0.0/24 | | ae75fb2a-c44f-4e85-a1b5-c2b79bd79dab | public | c2c2c941-c315-43b3-8318-73adff030aad 172.24.4.0/24 | | | | e8cb68cf-f0ad-4d7e-a0b3-2c56d35f01ce 2001:db8::/64 | +--------------------------------------+----------+----------------------------------------------------------+ $ curl -i -X GET -H "x-auth-token: dummy" http://192.168.122.111:9696/v2.0/networks/0d4af632-5e88-4d9a-a155-3f1a64a49986 HTTP/1.1 401 Unauthorized Content-Type: text/html; charset=UTF-8 Content-Length: 23 Www-Authenticate: Keystone uri='http://192.168.122.111:5000' X-Openstack-Request-Id: req-b6442ede-d972-45c4-82b6-fb0adff5108f Date: Thu, 23 Jul 2015 12:02:20 GMT
It returns 404 when giving a wrong network-id.
$ curl -i -X GET -H "x-auth-token: $TOKEN" http://192.168.122.111:9696/v2.0/networks/dummy HTTP/1.1 404 Not Found Content-Length: 154 Content-Type: text/html; charset=UTF-8 X-Openstack-Request-Id: req-1f28e824-6c6a-432d-bcf2-113b4071e03d Date: Thu, 23 Jul 2015 12:03:32 GMT
- Update network It returns 401 when giving a wrong token.
$ neutron net-list +--------------------------------------+----------+----------------------------------------------------------+ | id | name | subnets | +--------------------------------------+----------+----------------------------------------------------------+ | 0d4af632-5e88-4d9a-a155-3f1a64a49986 | private4 | a0a928f1-e057-4ecd-99d6-659fe2c950c5 fdc6:3c3c:39a7::/64 | | | | a9d8ad08-71f9-4a7b-82f1-9005ff24e7c1 10.0.0.0/24 | | ae75fb2a-c44f-4e85-a1b5-c2b79bd79dab | public | c2c2c941-c315-43b3-8318-73adff030aad 172.24.4.0/24 | | | | e8cb68cf-f0ad-4d7e-a0b3-2c56d35f01ce 2001:db8::/64 | +--------------------------------------+----------+----------------------------------------------------------+ $ curl -i -X PUT -H "x-auth-token: dummy" -H "content-type:application/jason" -d '{"network":{"name":"private5"}}' http://192.168.122.111:9696/v2.0/networks/0d4af632-5e88-4d9a-a155-3f1a64a49986 HTTP/1.1 401 Unauthorized Content-Type: text/html; charset=UTF-8 Content-Length: 23 Www-Authenticate: Keystone uri='http://192.168.122.111:5000' X-Openstack-Request-Id: req-f702bf41-98f6-4e6a-8a47-500415120d7e Date: Thu, 23 Jul 2015 12:06:28 GMT
It returns 401 when giving a bad request body.
$ curl -i -X PUT -H "x-auth-token: $TOKEN" -H "content-type:application/jason" -d '{"network":{"dummy":"private5"}}' http://192.168.122.111:9696/v2.0/networks/0d4af632-5e88-4d9a-a155-3f1a64a49986 HTTP/1.1 400 Bad Request Content-Length: 106 Content-Type: application/json; charset=UTF-8 X-Openstack-Request-Id: req-b9d86ae9-6b71-4a30-82d2-08637ba12f4f Date: Thu, 23 Jul 2015 12:08:37 GMT
$ curl -i -X PUT -H "x-auth-token: $TOKEN" -H "content-type:application/jason" -d '{"network":{"name":"private5"}}' http://192.168.122.111:9696/v2.0/networks/dummy HTTP/1.1 404 Not Found Content-Length: 154 Content-Type: text/html; charset=UTF-8 X-Openstack-Request-Id: req-72d35342-f42c-4e23-9e82-f0aa42731242 Date: Thu, 23 Jul 2015 12:09:40 GMT
- Delete network It returns 401 when giving a wrong token.
$ neutron net-list +--------------------------------------+----------+----------------------------------------------------------+ | id | name | subnets | +--------------------------------------+----------+----------------------------------------------------------+ | 0d4af632-5e88-4d9a-a155-3f1a64a49986 | private4 | a0a928f1-e057-4ecd-99d6-659fe2c950c5 fdc6:3c3c:39a7::/64 | | | | a9d8ad08-71f9-4a7b-82f1-9005ff24e7c1 10.0.0.0/24 | | ae75fb2a-c44f-4e85-a1b5-c2b79bd79dab | public | c2c2c941-c315-43b3-8318-73adff030aad 172.24.4.0/24 | | | | e8cb68cf-f0ad-4d7e-a0b3-2c56d35f01ce 2001:db8::/64 | +--------------------------------------+----------+----------------------------------------------------------+ $ curl -i -X DELETE -H "x-auth-token: dummy" http://192.168.122.111:9696/v2.0/networks/0d4af632-5e88-4d9a-a155-3f1a64a49986 HTTP/1.1 401 Unauthorized Content-Type: text/html; charset=UTF-8 Content-Length: 23 Www-Authenticate: Keystone uri='http://192.168.122.111:5000' X-Openstack-Request-Id: req-bff58281-c2e1-4ea1-98de-d091dc413717 Date: Thu, 23 Jul 2015 12:10:56 GMT
$ curl -i -X DELETE -H "x-auth-token: $TOKEN" http://192.168.122.111:9696/v2.0/networks/dummy HTTP/1.1 404 Not Found Content-Length: 154 Content-Type: text/html; charset=UTF-8 X-Openstack-Request-Id: req-c9371145-200f-41ce-97e7-87b46b28023b Date: Thu, 23 Jul 2015 12:12:06 GMT
It returns 409 when the network already has a port.
$ curl -i -X POST -H "x-auth-token: $TOKEN" -H "content-type:application/jason" -d '{"port":{"network_id":"0d4af632-5e88-4d9a-a155-3f1a64a49986"}}' http://192.168.122.111:9696/v2.0/ports HTTP/1.1 201 Created Content-Type: application/json; charset=UTF-8 Content-Length: 747 X-Openstack-Request-Id: req-9dc471ac-2fb0-4798-84e1-fb82fb34b94e Date: Thu, 23 Jul 2015 12:13:14 GMT <snipped> $ curl -i -X DELETE -H "x-auth-token: $TOKEN" http://192.168.122.111:9696/v2.0/networks/0d4af632-5e88-4d9a-a155-3f1a64a49986 HTTP/1.1 409 Conflict Content-Type: application/json; charset=UTF-8 Content-Length: 205 X-Openstack-Request-Id: req-b649e00b-2b06-4c37-a4d9-3de8725fbd3d Date: Thu, 23 Jul 2015 12:13:24 GMT
Here is what I confirmed.
- List networks
It returns 401 when giving a wrong token.
$ curl -i -X GET -H "x-auth-token: dummy" http:// 192.168. 122.111: 9696/v2. 0/networks Authenticate: Keystone uri='http:// 192.168. 122.111: 5000' -Request- Id: req-bd75e25a- b102-4ec2- a68e-7ea16feb05 bf
HTTP/1.1 401 Unauthorized
Content-Type: text/html; charset=UTF-8
Content-Length: 23
Www-
X-Openstack
Date: Thu, 23 Jul 2015 11:55:32 GMT
- Create network
It returns 400 when giving a bad request body.
$ curl -i -X POST -H "x-auth-token: $TOKEN" -H "content- type:applicatio n/jason" -d '{"network" :{"dummy" :"dummy" }}' http:// 192.168. 122.111: 9696/v2. 0/networks -Request- Id: req-ba7ebf42- b1fb-48f8- bc34-62ac8408b9 b1
HTTP/1.1 400 Bad Request
Content-Length: 106
Content-Type: application/json; charset=UTF-8
X-Openstack
Date: Thu, 23 Jul 2015 11:58:56 GMT
It returns 401 when giving a wrong token.
$ curl -i -X POST -H "x-auth-token: dummy" -H "content- type:applicatio n/jason" -d '{"network":{}}' http:// 192.168. 122.111: 9696/v2. 0/networks Authenticate: Keystone uri='http:// 192.168. 122.111: 5000' -Request- Id: req-c4382d22- 5ff6-415b- b8a3-98abada420 e6
HTTP/1.1 401 Unauthorized
Content-Type: text/html; charset=UTF-8
Content-Length: 23
Www-
X-Openstack
Date: Thu, 23 Jul 2015 12:00:00 GMT
- Show network details
It returns 401 when giving a wrong token.
$ neutron net-list ------- ------- ------- ------- ------- -+----- -----+- ------- ------- ------- ------- ------- ------- ------- ------- -+ ------- ------- ------- ------- ------- -+----- -----+- ------- ------- ------- ------- ------- ------- ------- ------- -+ 5e88-4d9a- a155-3f1a64a499 86 | private4 | a0a928f1- e057-4ecd- 99d6-659fe2c950 c5 fdc6:3c3c:39a7::/64 | 71f9-4a7b- 82f1-9005ff24e7 c1 10.0.0.0/24 | c44f-4e85- a1b5-c2b79bd79d ab | public | c2c2c941- c315-43b3- 8318-73adff030a ad 172.24.4.0/24 | f0ad-4d7e- a0b3-2c56d35f01 ce 2001:db8::/64 | ------- ------- ------- ------- ------- -+----- -----+- ------- ------- ------- ------- ------- ------- ------- ------- -+ 192.168. 122.111: 9696/v2. 0/networks/ 0d4af632- 5e88-4d9a- a155-3f1a64a499 86 Authenticate: Keystone uri='http:// 192.168. 122.111: 5000' -Request- Id: req-b6442ede- d972-45c4- 82b6-fb0adff510 8f
+--
| id | name | subnets |
+--
| 0d4af632-
| | | a9d8ad08-
| ae75fb2a-
| | | e8cb68cf-
+--
$ curl -i -X GET -H "x-auth-token: dummy" http://
HTTP/1.1 401 Unauthorized
Content-Type: text/html; charset=UTF-8
Content-Length: 23
Www-
X-Openstack
Date: Thu, 23 Jul 2015 12:02:20 GMT
It returns 404 when giving a wrong network-id.
$ curl -i -X GET -H "x-auth-token: $TOKEN" http:// 192.168. 122.111: 9696/v2. 0/networks/ dummy -Request- Id: req-1f28e824- 6c6a-432d- bcf2-113b4071e0 3d
HTTP/1.1 404 Not Found
Content-Length: 154
Content-Type: text/html; charset=UTF-8
X-Openstack
Date: Thu, 23 Jul 2015 12:03:32 GMT
- Update network
It returns 401 when giving a wrong token.
$ neutron net-list ------- ------- ------- ------- ------- -+----- -----+- ------- ------- ------- ------- ------- ------- ------- ------- -+ ------- ------- ------- ------- ------- -+----- -----+- ------- ------- ------- ------- ------- ------- ------- ------- -+ 5e88-4d9a- a155-3f1a64a499 86 | private4 | a0a928f1- e057-4ecd- 99d6-659fe2c950 c5 fdc6:3c3c:39a7::/64 | 71f9-4a7b- 82f1-9005ff24e7 c1 10.0.0.0/24 | c44f-4e85- a1b5-c2b79bd79d ab | public | c2c2c941- c315-43b3- 8318-73adff030a ad 172.24.4.0/24 | f0ad-4d7e- a0b3-2c56d35f01 ce 2001:db8::/64 | ------- ------- ------- ------- ------- -+----- -----+- ------- ------- ------- ------- ------- ------- ------- ------- -+ type:applicatio n/jason" -d '{"network" :{"name" :"private5" }}' http:// 192.168. 122.111: 9696/v2. 0/networks/ 0d4af632- 5e88-4d9a- a155-3f1a64a499 86 Authenticate: Keystone uri='http:// 192.168. 122.111: 5000' -Request- Id: req-f702bf41- 98f6-4e6a- 8a47-500415120d 7e
+--
| id | name | subnets |
+--
| 0d4af632-
| | | a9d8ad08-
| ae75fb2a-
| | | e8cb68cf-
+--
$ curl -i -X PUT -H "x-auth-token: dummy" -H "content-
HTTP/1.1 401 Unauthorized
Content-Type: text/html; charset=UTF-8
Content-Length: 23
Www-
X-Openstack
Date: Thu, 23 Jul 2015 12:06:28 GMT
It returns 401 when giving a bad request body.
$ curl -i -X PUT -H "x-auth-token: $TOKEN" -H "content- type:applicatio n/jason" -d '{"network" :{"dummy" :"private5" }}' http:// 192.168. 122.111: 9696/v2. 0/networks/ 0d4af632- 5e88-4d9a- a155-3f1a64a499 86 -Request- Id: req-b9d86ae9- 6b71-4a30- 82d2-08637ba12f 4f
HTTP/1.1 400 Bad Request
Content-Length: 106
Content-Type: application/json; charset=UTF-8
X-Openstack
Date: Thu, 23 Jul 2015 12:08:37 GMT
It returns 404 when giving a wrong network-id.
$ curl -i -X PUT -H "x-auth-token: $TOKEN" -H "content- type:applicatio n/jason" -d '{"network" :{"name" :"private5" }}' http:// 192.168. 122.111: 9696/v2. 0/networks/ dummy -Request- Id: req-72d35342- f42c-4e23- 9e82-f0aa427312 42
HTTP/1.1 404 Not Found
Content-Length: 154
Content-Type: text/html; charset=UTF-8
X-Openstack
Date: Thu, 23 Jul 2015 12:09:40 GMT
- Delete network
It returns 401 when giving a wrong token.
$ neutron net-list ------- ------- ------- ------- ------- -+----- -----+- ------- ------- ------- ------- ------- ------- ------- ------- -+ ------- ------- ------- ------- ------- -+----- -----+- ------- ------- ------- ------- ------- ------- ------- ------- -+ 5e88-4d9a- a155-3f1a64a499 86 | private4 | a0a928f1- e057-4ecd- 99d6-659fe2c950 c5 fdc6:3c3c:39a7::/64 | 71f9-4a7b- 82f1-9005ff24e7 c1 10.0.0.0/24 | c44f-4e85- a1b5-c2b79bd79d ab | public | c2c2c941- c315-43b3- 8318-73adff030a ad 172.24.4.0/24 | f0ad-4d7e- a0b3-2c56d35f01 ce 2001:db8::/64 | ------- ------- ------- ------- ------- -+----- -----+- ------- ------- ------- ------- ------- ------- ------- ------- -+ 192.168. 122.111: 9696/v2. 0/networks/ 0d4af632- 5e88-4d9a- a155-3f1a64a499 86 Authenticate: Keystone uri='http:// 192.168. 122.111: 5000' -Request- Id: req-bff58281- c2e1-4ea1- 98de-d091dc4137 17
+--
| id | name | subnets |
+--
| 0d4af632-
| | | a9d8ad08-
| ae75fb2a-
| | | e8cb68cf-
+--
$ curl -i -X DELETE -H "x-auth-token: dummy" http://
HTTP/1.1 401 Unauthorized
Content-Type: text/html; charset=UTF-8
Content-Length: 23
Www-
X-Openstack
Date: Thu, 23 Jul 2015 12:10:56 GMT
It returns 404 when giving a wrong network-id.
$ curl -i -X DELETE -H "x-auth-token: $TOKEN" http:// 192.168. 122.111: 9696/v2. 0/networks/ dummy -Request- Id: req-c9371145- 200f-41ce- 97e7-87b46b2802 3b
HTTP/1.1 404 Not Found
Content-Length: 154
Content-Type: text/html; charset=UTF-8
X-Openstack
Date: Thu, 23 Jul 2015 12:12:06 GMT
It returns 409 when the network already has a port.
$ curl -i -X POST -H "x-auth-token: $TOKEN" -H "content- type:applicatio n/jason" -d '{"port" :{"network_ id":"0d4af632- 5e88-4d9a- a155-3f1a64a499 86"}}' http:// 192.168. 122.111: 9696/v2. 0/ports -Request- Id: req-9dc471ac- 2fb0-4798- 84e1-fb82fb34b9 4e 192.168. 122.111: 9696/v2. 0/networks/ 0d4af632- 5e88-4d9a- a155-3f1a64a499 86 -Request- Id: req-b649e00b- 2b06-4c37- a4d9-3de8725fbd 3d
HTTP/1.1 201 Created
Content-Type: application/json; charset=UTF-8
Content-Length: 747
X-Openstack
Date: Thu, 23 Jul 2015 12:13:14 GMT
<snipped>
$ curl -i -X DELETE -H "x-auth-token: $TOKEN" http://
HTTP/1.1 409 Conflict
Content-Type: application/json; charset=UTF-8
Content-Length: 205
X-Openstack
Date: Thu, 23 Jul 2015 12:13:24 GMT