Comment 0 for bug 1525317

Revision history for this message
Dave Chen (wei-d-chen) wrote :

Currently, IdP doesn't support to filter the DB records based on the field, for example,

If configure the DB like this,
mysql> select * from identity_provider;
+------+---------+-------------+
| id | enabled | description |
+------+---------+-------------+
| idp1 | 1 | NULL |
| idp2 | 1 | NULL |
+------+---------+-------------+
2 rows in set (0.00 sec)

And I query the IdP by this curl, I get all of the records from DB,

curl -g -i -X GET http://127.0.0.1:35357/v3/OS-FEDERATION/identity_providers?id=idontexist -H "User-Agent: python-keystoneclient" -H "Accept: application/json" -H "X-Auth-Token: f74ac35177cb4720891a9cfed5ea1b9c"

{
 "links": {
  "self": "http://10.239.48.36:35357/v3/OS-FEDERATION/identity_providers?id=idp1",
  "previous": null,
  "next": null
 },
 "identity_providers": [{
  "remote_ids": [],
  "enabled": true,
  "id": "idp1",
  "links": {
   "self": "http://10.239.48.36:35357/v3/OS-FEDERATION/identity_providers/idp1",
   "protocols": "http://10.239.48.36:35357/v3/OS-FEDERATION/identity_providers/idp1/protocols"
  },
  "description": null
 }, {
  "remote_ids": [],
  "enabled": true,
  "id": "idp2",
  "links": {
   "self": "http://10.239.48.36:35357/v3/OS-FEDERATION/identity_providers/idp2",
   "protocols": "http://10.239.48.36:35357/v3/OS-FEDERATION/identity_providers/idp2/protocols"
  },
  "description": null
 }]
}

This feature should be supported since OSC depends on this to filter the DB records wanted.

Noted: Open this bug since it's different with https://bugs.launchpad.net/python-openstackclient/+bug/1479837, they are two different things, and I think this more sound like a feature that keystone should support.