<div dir="ltr">Hi Pavlo, I think that there are viable alternatives to your specific use case having single external idp for federated auth.<div>Depending on your IT environment architecture and preferences you have the following possibilities, both of them are providing very smooth user experience:</div><div>- in AD centric environments connect each of Keystone services to AD and leverage Kerberos for SSO. You can consume REMOTE_USER and other variables from AD directly via mod_auth_gssapi and mod_lookup_identity. Advantage of this approach is that you can leverage AD native SSO mechanism based on SPNEGO. So you are not any longer forcing users to perform SAML or OIDC referrals etc.</div><div>- in both AD or non AD centric environments you can leverage 'Tokenless Auth' plugin, which basically can also be used with Keystone to issue tokens (e.g. Fernet) and perform token scoping based on X.509 certificate properties. You can also configure specific X.509 certificate attributes e.g. SAN or subjectDirectoryAttributes to control access for specific region or Keystone instance.</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Dec 8, 2017 at 1:25 AM, Boris Bobrov <span dir="ltr"><<a href="mailto:breton@cynicmansion.ru" target="_blank">breton@cynicmansion.ru</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<div><div class="h5"><br>
> On 12/07/2017 12:27 PM, Colleen Murphy wrote:<br>
>> On Thu, Dec 7, 2017 at 5:37 PM, Pavlo Shchelokovskyy<br>
>> <<a href="mailto:pshchelokovskyy@mirantis.com">pshchelokovskyy@mirantis.com</a>> wrote:<br>
>>> Hi all,<br>
>>><br>
>>> We have a following use case - several independent keystones (say KeyA and<br>
>>> KeyB), using fernet tokens and synchronized fernet keys, and single external<br>
>>> IdP for federated auth.<br>
>>><br>
>>> Is it generally possible to configure both KeyA and KeyB such that scoped<br>
>>> token issued by KeyA for a federated user is valid on KeyB?<br>
>>><br>
>>> Currently we have the next problem - although domains/projects where<br>
>>> keystone's mapping engine assigns federated users are equal by name between<br>
>>> KeyA and KeyB, the UUIDs of projects/domains in KeyA and KeyB are<br>
>>> different, which seems to invalidate the scoped token issued by KeyA when<br>
>>> trying to use it for KeyB. And it is not possible to create projects/domains<br>
>>> with specific UUIDs via keystone API (which would probably solve this<br>
>>> problem for non-autoprovisioned projects).<br>
>>><br>
>>> Is such usage scenario supported? Or one should always use the unscoped<br>
>>> token first to list projects/domains available on a specific keystone<br>
>>> instance and then get a scoped token for usage o this instance only?<br>
>> No, it is not currently possible to use the same token on projects in<br>
>> different keystones, for the reasons you gave. You might be interested<br>
>> in following <a href="https://review.openstack.org/#/c/323499/" rel="noreferrer" target="_blank">https://review.openstack.org/#<wbr>/c/323499/</a> if you're not<br>
>> already aware of it, which has the goal of solving that problem.<br>
>><br>
>> It's also been brought up before:<br>
>><br>
>> <a href="https://review.openstack.org/#/c/403866/" rel="noreferrer" target="_blank">https://review.openstack.org/#<wbr>/c/403866/</a><br>
>> <a href="http://lists.openstack.org/pipermail/openstack-dev/2016-December/108466.html" rel="noreferrer" target="_blank">http://lists.openstack.org/<wbr>pipermail/openstack-dev/2016-<wbr>December/108466.html</a><br>
>><br>
>> And we talked about it a lot at the last Forum (sorry my brief summary<br>
>> does not really do the discussion justice):<br>
>><br>
>> <a href="http://www.gazlene.net/sydney-summit.html#keystone-operator-and-user-feedback" rel="noreferrer" target="_blank">http://www.gazlene.net/sydney-<wbr>summit.html#keystone-operator-<wbr>and-user-feedback</a><br>
> I had a snippet about it in my recap under the "Other Feedback" section<br>
> [0]. The TL;DR in my opinion is that we originally thought we could<br>
> solve the problem with federation 100%, and if we couldn't we wanted to<br>
> try and improve the parts of federation that would make that possible.<br>
><br>
> The interesting bit we came up with during the feedback session in<br>
> Sydney is what happens if a user no longer has a role on a project. For<br>
> example;<br>
><br>
> - A user has a role on Project A and in the us-east region and the<br>
> us-west region, each region has it's own keystone deployment, but let's<br>
> assume the ID for Project A are the same in each region<br>
> - A user authenticates for a token scoped to Project A and starts<br>
> creating instances in both regions<br>
> - The user has their role from Project A removed in us-east, but not in<br>
> us-west<br>
> - The user isn't able to do anything within us-east since they no longer<br>
> have a role assignment on Project A in that region, but they can still<br>
> take the invalid token from the us-east region and effectively use it in<br>
> the us-west region<br>
><br>
> Without replicating revocation events, or syncing the assignment table,<br>
> this will lead to security concerns.<br>
<br>
</div></div>There is also cache invalidation issue. And that would make tokens of<br>
various scope behave in a different manner. A year ago i was -2 on this,<br>
and i still don't think this is a good idea.<br>
<br>
If there is a demand to control several clouds from single place,<br>
K2K support should be added where it is needed.<br>
<br>
<br>______________________________<wbr>______________________________<wbr>______________<br>
OpenStack Development Mailing List (not for usage questions)<br>
Unsubscribe: <a href="http://OpenStack-dev-request@lists.openstack.org?subject:unsubscribe" rel="noreferrer" target="_blank">OpenStack-dev-request@lists.<wbr>openstack.org?subject:<wbr>unsubscribe</a><br>
<a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev" rel="noreferrer" target="_blank">http://lists.openstack.org/<wbr>cgi-bin/mailman/listinfo/<wbr>openstack-dev</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div style="color:rgb(136,136,136);font-size:12.8000001907349px">Adam Heczko</div><div style="color:rgb(136,136,136);font-size:12.8000001907349px">Security Engineer @ Mirantis Inc.</div></div></div>
</div>