Fixing dn_to_id function for cases were id is not in the DN
The more common scenario to return the uid as part of the RDN in a DN,
However, it's a valid case to not have the uid in the RDN, so we need to
search in the LDAP based on the DN and return the uid in the entire object.
Also, we do not support multivalued attribute id on DN, so the test case
covering this case, it was adjusted for raise NotFound.
Closes-Bug: 1782922
Change-Id: I87a3bfa94b5907ce4c6b4eb8e124ec948b390bf2
(cherry picked from commit a1dc21f3d34ae34bc6a5c9acebc0eb752495ae7a)
Reviewed: https:/ /review. opendev. org/674030 /git.openstack. org/cgit/ openstack/ keystone/ commit/ ?id=9d9451e13c8 e7a1835d721be7b 8a4a5c6dff2b95
Committed: https:/
Submitter: Zuul
Branch: stable/queens
commit 9d9451e13c8e7a1 835d721be7b8a4a 5c6dff2b95
Author: Raildo Mascena <email address hidden>
Date: Mon Apr 1 16:48:07 2019 -0300
Fixing dn_to_id function for cases were id is not in the DN
The more common scenario to return the uid as part of the RDN in a DN,
However, it's a valid case to not have the uid in the RDN, so we need to
search in the LDAP based on the DN and return the uid in the entire object.
Also, we do not support multivalued attribute id on DN, so the test case
covering this case, it was adjusted for raise NotFound.
Closes-Bug: 1782922 ce4c6b4eb8e124e c948b390bf2 bc6a5c9acebc0eb 752495ae7a)
Change-Id: I87a3bfa94b5907
(cherry picked from commit a1dc21f3d34ae34