Keystone create user and permissions by api
<p>I have an instance of Keyrock in fiware lab.</p>

<p>in my app, im trying to create user with api as <a href="https://stackoverflow.com/questions/36737454/fiware-keystone-api-create-user-and-access-with-horizon">Fiware keystone api create user and access with horizon</a>.</p>

<p>now i check user:</p>

<p>curl -s -H "X-Auth-Token:17007fe11124bd71eb60" <a href="http://localhost:5000/v3/users/admin" rel="nofollow noreferrer">http://localhost:5000/v3/users/admin</a> | python -mjson.tool</p>

<p>response:</p>

<pre><code>&gt; {
&gt;     "user": {
&gt;         "default_project_id": "d0f384973b9f4a57b975fcd9bef10c6e",
&gt;         "description": "admin",
&gt;         "domain_id": "default",
&gt;         "email": "admin@gmail.com",
&gt;         "enabled": true,
&gt;         "id": "admin",
&gt;         "links": {
&gt;             "self": "http://localhost:5000/v3/users/admin1"
&gt;         },
&gt;         "name": "admin@gmail.com",
&gt;         "username": "admin"
&gt;     } }
</code></pre>

<p>now name field is correct, but i cant log with this user in my Horizon. If i check the keystone.log, i can see this:</p>

<pre><code>2016-09-21 12:28:50.353 1483 WARNING keystone.common.wsgi [-] Authorization failed. The request you have made requires authentication. from 127.0.0.1
2016-09-21 12:28:50.445 1482 WARNING keystone.auth.controllers [-] User admin doesn't have access to default project d0f384973b9f4a57b975fcd9bef10c6e. The token will be unscoped rather than scoped to the project.
2016-09-21 12:28:50.767 1481 WARNING keystone.common.wsgi [-] You are not authorized to perform the requested action: identity:revoke_token
2016-09-21 12:29:42.900 1483 WARNING keystone.common.controller [-] RBAC: Bypassing authorization
</code></pre>

<p>and in Horizon:</p>

<p><a href="https://i.stack.imgur.com/rws5i.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/rws5i.png" alt="enter image description here"></a></p>

<p>Of course, the log explains problem: "<em>User admin doesn't have access to default project d0f384973b9f4a57b975fcd9bef10c6e</em>" But, how can i set permissions to this user in project?</p>