This has been filled already zhangjialong :<div><br></div><div><a href="https://bugs.launchpad.net/keystone/+bug/999615">https://bugs.launchpad.net/keystone/+bug/999615</a></div><div><br></div><div>I am not very familiar with how Keystone RBAC u work, AFAIK the current way to do that with policy.json is going to go away in the future, right?</div>
<div><br></div><div>Chmouel.<br><br><div class="gmail_quote">On Tue, May 15, 2012 at 6:37 PM, Nguyen, Liem Manh <span dir="ltr"><<a href="mailto:liem_m_nguyen@hp.com" target="_blank">liem_m_nguyen@hp.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Yeah, that is because the swift/keystone middleware checks for the tenantId to match the accountId in the URL path... Perhaps, we should rely strictly on Swift ACL for granting access to a given Swift container, and rely on Keystone RBAC for what you can do with a given Swift account.<br>
<br>
BTW, we also ran into this issue before... Has a bug/feature request been filed for this yet? If not, I can file one.<br>
<br>
Thanks,<br>
Liem<br>
<br>
-----Original Message-----<br>
From: openstack-bounces+liem_m_nguyen=<a href="mailto:hp.com@lists.launchpad.net">hp.com@lists.launchpad.net</a> [mailto:<a href="mailto:openstack-bounces%2Bliem_m_nguyen">openstack-bounces+liem_m_nguyen</a>=<a href="mailto:hp.com@lists.launchpad.net">hp.com@lists.launchpad.net</a>] On Behalf Of Chmouel Boudjnah<br>
Sent: Tuesday, May 15, 2012 2:55 AM<br>
To: 张家龙<br>
Cc: openstack<br>
Subject: Re: [Openstack] Swift Object Storage ACLs with KeyStone<br>
<br>
Hi,<br>
<br>
In swift+keystone you are not allowed to have ACL between different<br>
account/tenant/project, you can only allow ACL between different<br>
users in a tenant.<br>
This is probably something not too difficult to implement but it may<br>
needs some tinkering to get it right. Please feel free to log a bug in<br>
keystone and we'll try to address that.<br>
<br>
Chmouel.<br>
<br>
On Sat, May 12, 2012 at 4:02 AM, 张家龙 <<a href="mailto:zhangjl@awcloud.com">zhangjl@awcloud.com</a>> wrote:<br>
> Vish ,<br>
> Thank you for answering.<br>
> While ,sorry,I don`t understand your said.<br>
> Do you mean I have to do like follows when I setting up acls:<br>
><br>
> curl -X PUT -i \<br>
> -H "X-Auth-Token: <token of demo:demo>" \<br>
> -H "X-Container-Read: <tenant_id:user_id>" \<br>
> <a href="http://127.0.0.1:8080/v1/AUTH_f1723800c821453d9f22d42d1fbb334b/demodirc" target="_blank">http://127.0.0.1:8080/v1/AUTH_f1723800c821453d9f22d42d1fbb334b/demodirc</a><br>
><br>
> Or,other operations and settings?<br>
> ------------------<br>
> Best Regards<br>
><br>
> ZhangJialong<br>
><br>
><br>
><br>
> ------------------ Original ------------------<br>
> From: "Vishvananda Ishaya"<<a href="mailto:vishvananda@gmail.com">vishvananda@gmail.com</a>>;<br>
> Date: Sat, May 12, 2012 03:03 AM<br>
> To: "张家龙"<<a href="mailto:zhangjl@awcloud.com">zhangjl@awcloud.com</a>>;<br>
> Cc: "openstack"<<a href="mailto:openstack@lists.launchpad.net">openstack@lists.launchpad.net</a>>;<br>
> Subject: Re: [Openstack] Swift Object Storage ACLs with KeyStone<br>
><br>
> I'm not totally sure about this, but you might have to use the project_id<br>
> from keystone instead of the project_name when setting up acls. The same<br>
> may be true of user_id.<br>
><br>
> Vish<br>
><br>
> On Fri, May 11, 2012 at 12:51 AM, 张家龙 <<a href="mailto:zhangjl@awcloud.com">zhangjl@awcloud.com</a>> wrote:<br>
>><br>
>><br>
>> Hello, everyone.<br>
>><br>
>> I encountered some problems when i set permissions (ACLs) on Openstack<br>
>> Swift containers.<br>
>> I installed swift-1.4.8(essex) and use keystone-2012.1 as<br>
>> authentication system on CentOS 6.2 .<br>
>><br>
>> My swift proxy-server.conf and keystone.conf are here:<br>
>> <a href="http://pastebin.com/dUnHjKSj" target="_blank">http://pastebin.com/dUnHjKSj</a><br>
>><br>
>> Then,I use the script named opensatck_essex_data.sh(<br>
>> <a href="http://pastebin.com/LWGVZrK0" target="_blank">http://pastebin.com/LWGVZrK0</a> ) to<br>
>> initialize keystone.<br>
>><br>
>> After these operations,I got the token of demo:demo and<br>
>> newuser:newuser<br>
>><br>
>> curl -s -H 'Content-type: application/json' \<br>
>> -d '{"auth": {"tenantName": "demo", "passwordCredentials":<br>
>> {"username": "demo", "password": "admin"}}}' \<br>
>> <a href="http://127.0.0.1:5000/v2.0/tokens" target="_blank">http://127.0.0.1:5000/v2.0/tokens</a> | python -mjson.tool<br>
>><br>
>> curl -s -H 'Content-type: application/json' \<br>
>> -d '{"auth": {"tenantName": "newuser", "passwordCredentials":<br>
>> {"username": "newuser", "password": "admin"}}}' \<br>
>> <a href="http://127.0.0.1:5000/v2.0/tokens" target="_blank">http://127.0.0.1:5000/v2.0/tokens</a> | python -mjson.tool<br>
>><br>
>> Then,enable read access to newuser:newuser<br>
>><br>
>> curl -X PUT -i \<br>
>> -H "X-Auth-Token: <token of demo:demo>" \<br>
>> -H "X-Container-Read: newuser:newuser" \<br>
>><br>
>> <a href="http://127.0.0.1:8080/v1/AUTH_f1723800c821453d9f22d42d1fbb334b/demodirc" target="_blank">http://127.0.0.1:8080/v1/AUTH_f1723800c821453d9f22d42d1fbb334b/demodirc</a><br>
>><br>
>> Check the permission of the container:<br>
>><br>
>> curl -k -v -H 'X-Auth-Token:<token of demo:demo>' \<br>
>><br>
>> <a href="http://127.0.0.1:8080/v1/AUTH_f1723800c821453d9f22d42d1fbb334b/demodirc" target="_blank">http://127.0.0.1:8080/v1/AUTH_f1723800c821453d9f22d42d1fbb334b/demodirc</a><br>
>><br>
>> This is the reply of the operation:<br>
>><br>
>> HTTP/1.1 200 OK<br>
>> X-Container-Object-Count: 1<br>
>> X-Container-Read: newuser:newuser<br>
>> X-Container-Bytes-Used: 2735<br>
>> Accept-Ranges: bytes<br>
>> Content-Length: 24<br>
>> Content-Type: text/plain; charset=utf-8<br>
>> Date: Fri, 11 May 2012 07:30:23 GMT<br>
>><br>
>> opensatck_essex_data.sh<br>
>><br>
>> Now,the user newuser:newuser visit the container of demo:demo<br>
>><br>
>> curl -k -v -H 'X-Auth-Token:<token of newuser:newuser>' \<br>
>><br>
>> <a href="http://127.0.0.1:8080/v1/AUTH_f1723800c821453d9f22d42d1fbb334b/demodirc" target="_blank">http://127.0.0.1:8080/v1/AUTH_f1723800c821453d9f22d42d1fbb334b/demodirc</a><br>
>><br>
>> While,I got 403 error.Can someone help me?<br>
>><br>
>> ------------------<br>
>> Best Regards<br>
>><br>
>> ZhangJialong<br>
>><br>
>><br>
>> _______________________________________________<br>
>> Mailing list: <a href="https://launchpad.net/~openstack" target="_blank">https://launchpad.net/~openstack</a><br>
>> Post to : <a href="mailto:openstack@lists.launchpad.net">openstack@lists.launchpad.net</a><br>
>> Unsubscribe : <a href="https://launchpad.net/~openstack" target="_blank">https://launchpad.net/~openstack</a><br>
>> More help : <a href="https://help.launchpad.net/ListHelp" target="_blank">https://help.launchpad.net/ListHelp</a><br>
>><br>
><br>
><br>
> _______________________________________________<br>
> Mailing list: <a href="https://launchpad.net/~openstack" target="_blank">https://launchpad.net/~openstack</a><br>
> Post to : <a href="mailto:openstack@lists.launchpad.net">openstack@lists.launchpad.net</a><br>
> Unsubscribe : <a href="https://launchpad.net/~openstack" target="_blank">https://launchpad.net/~openstack</a><br>
> More help : <a href="https://help.launchpad.net/ListHelp" target="_blank">https://help.launchpad.net/ListHelp</a><br>
><br>
<br>
_______________________________________________<br>
Mailing list: <a href="https://launchpad.net/~openstack" target="_blank">https://launchpad.net/~openstack</a><br>
Post to : <a href="mailto:openstack@lists.launchpad.net">openstack@lists.launchpad.net</a><br>
Unsubscribe : <a href="https://launchpad.net/~openstack" target="_blank">https://launchpad.net/~openstack</a><br>
More help : <a href="https://help.launchpad.net/ListHelp" target="_blank">https://help.launchpad.net/ListHelp</a><br>
</blockquote></div><br></div>