[OpenStack-fr] Fwd: Mitaka keystone avec identity->ldap et assignment->sql

Kourosh VIVAN kourosh.vivan at osones.com
Mar 13 Sep 09:58:51 UTC 2016


Bonjour,

Votre conf semble correct, la doc officielle explique comment utiliser le
LDAP pour l'identity et l'assignment:
http://docs.openstack.org/admin-guide/keystone-integrate-with-ldap.html

J'ai trouvé un article (de 2014) d'un blog qui donne la methode pour
utiliser ldap pour l'identity et SQL pour l'assignment:
https://www.mattfischer.com/blog/?p=545

L'erreur que vous avez n'en est peut etre pas une, avez-vous ajouter un
role au user sur un projet ? Si oui, activez le debug pour comprendre
pourquoi la partie assignment ne fonctionne pas correctement au moment de
l'ajout de droit.

Si les droits ont été donné avant le passage sur ldap, il faut utiliser
l'admin token pour tout remettre (expliqué dans le blog):

The problem once you switch the authentication mechanism to LDAP, you’ve
“lost” all the old roles and users that puppet setup, like the admin user
who actually has permissions to do stuff like list users. The fix as any
keystone expert will know is to bypass the main API and use the service
token directly. In the keystone.conf a service token is defined as
admin_token. To use it, unset everything like OS_USERNAME and set:

export SERVICE_TOKEN=
export SERVICE_ENDPOINT=http://localhost:35357/v2.0

Then you need to give your user, in my case, “id=mfischer” permission to do
stuff. I ended up giving mfischer the admin and _member_ role in both of my
tenants since he/me is the new admin. Finally, I switched my settings back
to what’s in my rc file, mfischer as the user, my LDAP password, and the
normal keystone endpoint, and… finally my user-list query worked and I got
results from LDAP.


Cordialement,

Kourosh VIVAN
Ingenieur Openstack | +33 6 84 88 19 76 | osones.com

*Osones. Audit, intégration, support, formation.*


Sujet : [OpenStack-fr] Mitaka keystone avec identity->ldap et
assignment->sql
Date : Tue, 13 Sep 2016 11:20:53 +0200
De : Stéphane Delmotte <stephane.delmotte at univ-lyon1.fr>
Pour : openstack-fr at lists.openstack.org

Bonjour,
Je ne sais pas si c'est le bon endroit pour poser une question technique,
si ce n'est pas le cas je suis désolé.
Je n'arrive pas à paramétrer keystone version Mitaka pour qu'il s’appuie à
la fois sur note annuaire LDAP et la base de donnée MariaDB (intégré à
OpenStack).

voici les extraits de mon fichier keystone.conf
[identity]

#driver = sql
driver = ldap

*
*
*
[assignment]
driver = keystone.assignment.backends.sql.Assignment
#
# From keystone
#
# Entrypoint for the assignment backend driver in the keystone.assignment
# namespace. Only an SQL driver is supplied. If an assignment driver is not
# specified, the identity driver will choose the assignment driver (driver
# selection based on `[identity]/driver` option is deprecated and will be
# removed in the "O" release). (string value)
#driver = <None>

# A list of role names which are prohibited from being an implied role.
(list
# value)
prohibited_implied_role = <None>

[ldap]
#
# From keystone
#

# URL(s) for connecting to the LDAP server. Multiple LDAP URLs may be
specified
# as a comma separated string. The first URL to successfully bind is used
for
# the connection. (string value)

url = ldap://x.x.x.x
user_tree_dn = ou=People,dc=lbbe,dc=local
user_objectclass = inetOrgPerson

group_tree_dn = ou=Group,dc=lbbe,dc=local
group_objectclass = groupOfNames

allow_subtree_delete = False
debug_level = 9

user_enabled_default = True
user_enabled_attribute = enabled
user_enabled_emulation = False
user_allow_create = False
user_allow_update = False
user_allow_delete = False
group_allow_create = False
group_allow_update = False
group_allow_delete = False



La fonction [identity] est opérationnelle :
lorsque j'utilise un mauvais mot de passe j'ai le message sur l'interface
Horizon :  Invalid credentials.
dans le cas d'un authentification correcte j'ai : You are not authorized
for any projects or domains.
Il semblerait que ce soit la partie qui "assignment" qui pose problème.

Nous avons essayé de "bidouiller" la base de donnée MariaDB mais ça me
semble compliqué..
Ce que je cherche étant il me semble très simple.

La question est comment s'appuyer sur LDAP pour l'authentification et
MariaDB pour le reste ?
Avez-vous des documents, des liens qui peuvent m'aider ?


Cordialement
Stéphane Delmotte


-- 
Delmotte Stéphane
UMR CNRS 5558 Biometrie et Biologie Evolutive
Bat 711                            |
Universite Claude Bernard - Lyon I | Tel : +33 04 72 43 11 68
43, Bd du 11 Novembre 1918         | Fax : 04 72 43 13 88
69622 Villeurbanne cedex FRANCE


_______________________________________________
OpenStack-fr mailing list
OpenStack-fr at lists.openstack.org
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-fr




-- 
-- 
Kourosh VIVAN
Ingenieur Openstack | +33 6 84 88 19 76 | osones.com

*Osones. Audit, intégration, support, formation.*
-------------- section suivante --------------
Une pièce jointe HTML a été nettoyée...
URL: <http://lists.openstack.org/pipermail/openstack-fr/attachments/20160913/8c8c4406/attachment.html>


Plus d'informations sur la liste de diffusion OpenStack-fr