diff options
| author | Yogeshwar Srikrishnan <yoga80@yahoo.com> | 2011-09-21 16:45:36 -0500 |
|---|---|---|
| committer | Yogeshwar Srikrishnan <yoga80@yahoo.com> | 2011-09-21 16:51:46 -0500 |
| commit | 5f4ed9b70555d8dcef3c4e824ec8637fae9a8f32 (patch) | |
| tree | fb2293d29fbfe7660b54a745dd8c7e7434d4cf66 | |
| parent | ac00c1b6c6ffe5f4bf1f35ea879095c61877d913 (diff) | |
Adding tenantid to user roles and endpoints.
Change-Id: I7c468d3d0862a72195cc27dfbb907b4136eff0c0
| -rw-r--r-- | keystone/content/common/samples/auth.json | 13 | ||||
| -rw-r--r-- | keystone/content/common/samples/auth.xml | 10 | ||||
| -rw-r--r-- | keystone/content/common/samples/authwithgroups.json | 9 | ||||
| -rw-r--r-- | keystone/content/common/samples/authwithgroups.xml | 8 | ||||
| -rw-r--r-- | keystone/content/common/samples/endpoint.json | 1 | ||||
| -rw-r--r-- | keystone/content/common/samples/endpoint.xml | 1 | ||||
| -rw-r--r-- | keystone/content/common/samples/endpoints.json | 5 | ||||
| -rw-r--r-- | keystone/content/common/samples/endpoints.xml | 6 | ||||
| -rw-r--r-- | keystone/content/common/samples/validatetoken.json | 7 | ||||
| -rw-r--r-- | keystone/content/common/samples/validatetoken.xml | 6 | ||||
| -rw-r--r-- | keystone/content/common/xsd/endpoints.xsd | 13 |
11 files changed, 64 insertions, 15 deletions
diff --git a/keystone/content/common/samples/auth.json b/keystone/content/common/samples/auth.json index d18e8e6a..09863be6 100644 --- a/keystone/content/common/samples/auth.json +++ b/keystone/content/common/samples/auth.json @@ -1,5 +1,5 @@ { - "auth":{ + "access":{ "token":{ "id":"asdasdasd-adsasdads-asdasdasd-adsadsasd", "expires":"2010-11-01T03:32:15-05:00" @@ -10,7 +10,12 @@ "roles":[{ "id":"234", "name":"compute:admin" - } + }, + { + "id":"235", + "name":"object-store:admin", + "tenantId":"1" + } ], "roles_links":[] }, @@ -18,6 +23,7 @@ "name":"Cloud Servers", "type":"compute", "endpoints":[{ + "tenantId":"1", "publicURL":"https://compute.north.host/v1/1234", "internalURL":"https://compute.north.host/v1/1234", "region":"North", @@ -26,6 +32,7 @@ "versionList":"https://compute.north.host/" }, { + "tenantId":"2", "publicURL":"https://compute.north.host/v1.1/3456", "internalURL":"https://compute.north.host/v1.1/3456", "region":"North", @@ -40,6 +47,7 @@ "name":"Cloud Files", "type":"object-store", "endpoints":[{ + "tenantId":"11", "publicURL":"https://compute.north.host/v1/blah-blah", "internalURL":"https://compute.north.host/v1/blah-blah", "region":"South", @@ -48,6 +56,7 @@ "versionList":"uri" }, { + "tenantId":"2", "publicURL":"https://compute.north.host/v1.1/blah-blah", "internalURL":"https://compute.north.host/v1.1/blah-blah", "region":"South", diff --git a/keystone/content/common/samples/auth.xml b/keystone/content/common/samples/auth.xml index 62d7baf6..de188fee 100644 --- a/keystone/content/common/samples/auth.xml +++ b/keystone/content/common/samples/auth.xml @@ -6,22 +6,25 @@ xmlns="http://docs.openstack.org/identity/api/v2.0"> <user id="testId" name="test"> <roles> <role id="123" name="compute:admin"/> + <role id="234" name="object-store:admin" tenantId="1"/> </roles> </user> <serviceCatalog> <service type="compute" name="Computers in the Cloud"> <endpoint + tenantId="3456" region="North" publicURL="https://north.compute.public.com/v2.0/1234" internalURL="https://north.compute.internal.com/v2.0/1234"> <version id="2.0" info="https://north.compute.public.com/v2.0/" - list="https://north.compute.public.com/" /> + list="https://north.compute.public.com/" + tenantId="1"/> </endpoint> <endpoint + tenantId="3456" region="South" - tenantId="1234" publicURL="https://south.compute.public.com/v2.0/3456" internalURL="https://south.compute.internal.com/v2.0/3456"> <version @@ -32,6 +35,7 @@ xmlns="http://docs.openstack.org/identity/api/v2.0"> </service> <service type="object-store" name="HTTP Object Store"> <endpoint + tenantId="3456" region="North" publicURL="https://north.object-store.public.com/v1/1234" internalURL="https://north.object-store.internal.com/v1/1234"> @@ -41,6 +45,7 @@ xmlns="http://docs.openstack.org/identity/api/v2.0"> list="https://north.object-store.public.com/" /> </endpoint> <endpoint + tenantId="3456" region="South" publicURL="https://south.object-store.public.com/v2.0/3456" internalURL="https://south.object-store.internal.com/v2.0/3456"> @@ -52,6 +57,7 @@ xmlns="http://docs.openstack.org/identity/api/v2.0"> </service> <service type="dnsextension:dns" name="DNS-as-a-Service"> <endpoint + tenantId="3456" publicURL="https://dns.public.com/v2.0/blah-blah"> <version id="2.0" diff --git a/keystone/content/common/samples/authwithgroups.json b/keystone/content/common/samples/authwithgroups.json index 00309408..527c639f 100644 --- a/keystone/content/common/samples/authwithgroups.json +++ b/keystone/content/common/samples/authwithgroups.json @@ -1,5 +1,5 @@ { - "auth":{ + "access":{ "token":{ "id":"asdasdasd-adsasdads-asdasdasd-adsadsasd", "expires":"2010-11-01T03:32:15-05:00" @@ -10,7 +10,12 @@ "roles":[{ "id":"234", "name":"compute:admin" - } + }, + { + "id":"235", + "name":"object-store:admin", + "tenantId":"1" + } ], "roles_links":[], "RAX-KSGRP:groups":[{ diff --git a/keystone/content/common/samples/authwithgroups.xml b/keystone/content/common/samples/authwithgroups.xml index 107bd69d..f8c6981b 100644 --- a/keystone/content/common/samples/authwithgroups.xml +++ b/keystone/content/common/samples/authwithgroups.xml @@ -1,10 +1,10 @@ <?xml version="1.0" encoding="UTF-8"?> -<auth xmlns="http://docs.openstack.org/identity/api/v2.0"> +<access xmlns="http://docs.openstack.org/identity/api/v2.0"> <token expires="2010-11-01T03:32:15-05:00" id="ab48a9efdfedb23ty3494"/> <serviceCatalog> <service type="compute" name="Computers in the Cloud"> - <endpoint region="North" tenantId="1234" + <endpoint region="North" tenantId="1" publicURL="https://north.compute.public.com/v2.0/1234" internalURL="https://north.compute.internal.com/v2.0/1234"> <version id="2.0" @@ -57,7 +57,9 @@ <user xmlns="http://docs.openstack.org/identity/api/v2.0" id="123" username="jqsmith"> <roles xmlns="http://docs.openstack.org/identity/api/v2.0"> - <role id="234" name="Admin" tenantId="1234" description="All Access" /> + <role id="123" name="Admin" tenantId="1234" description="All Access" /> + <role id="234" name="object-store:admin" tenantId="1"/> + </roles> <groups xmlns="http://docs.rackspace.com/identity/api/ext/RAX-KSGRP/v1.0"> <group id="test_global_group_add"> diff --git a/keystone/content/common/samples/endpoint.json b/keystone/content/common/samples/endpoint.json index 1f597408..e65fc36b 100644 --- a/keystone/content/common/samples/endpoint.json +++ b/keystone/content/common/samples/endpoint.json @@ -1,6 +1,7 @@ { "endpoint": { "id": 1, + "tenantId":1, "region": "North", "type": "compute", "publicURL": "https://compute.north.public.com/v1", diff --git a/keystone/content/common/samples/endpoint.xml b/keystone/content/common/samples/endpoint.xml index dc4b0111..cd09b24a 100644 --- a/keystone/content/common/samples/endpoint.xml +++ b/keystone/content/common/samples/endpoint.xml @@ -2,6 +2,7 @@ <endpoint id="1" + tenantId="1" type="compute" name="Compute" region="North" diff --git a/keystone/content/common/samples/endpoints.json b/keystone/content/common/samples/endpoints.json index ef407b27..0ff86a63 100644 --- a/keystone/content/common/samples/endpoints.json +++ b/keystone/content/common/samples/endpoints.json @@ -1,6 +1,7 @@ { "endpoints":[{ "id":1, + "tenantId":"1", "region":"North", "type":"compute", "publicURL":"https://compute.north.public.com/v1", @@ -11,6 +12,7 @@ }, { "id":2, + "tenantId":"1", "region":"South", "type":"compute", "publicURL":"https://compute.north.public.com/v1", @@ -21,6 +23,7 @@ }, { "id":3, + "tenantId":"1", "region":"East", "type":"compute", "publicURL":"https://compute.north.public.com/v1", @@ -31,6 +34,7 @@ }, { "id":4, + "tenantId":"1", "region":"West", "type":"compute", "publicURL":"https://compute.north.public.com/v1", @@ -41,6 +45,7 @@ }, { "id":5, + "tenantId":"1", "region":"Global", "type":"compute", "publicURL":"https://compute.north.public.com/v1", diff --git a/keystone/content/common/samples/endpoints.xml b/keystone/content/common/samples/endpoints.xml index 0180af89..b09819a1 100644 --- a/keystone/content/common/samples/endpoints.xml +++ b/keystone/content/common/samples/endpoints.xml @@ -4,6 +4,7 @@ xmlns="http://docs.openstack.org/identity/api/v2.0"> <endpoint id="1" + tenantId="1" type="compute" name="Compute" region="North" @@ -18,6 +19,7 @@ </endpoint> <endpoint id="2" + tenantId="2" type="compute" name="Compute" region="South" @@ -32,15 +34,18 @@ </endpoint> <endpoint id="3" + tenantId="1" type="compute" name="Compute" region="East" publicURL="https://compute.north.public.com/v1" internalURL="https://compute.north.internal.com/v1" adminURL="https://compute.north.internal.com/v1" + tenantId="1" /> <endpoint id="4" + tenantId="1" type="compute" name="Compute" region="West" @@ -55,6 +60,7 @@ </endpoint> <endpoint id="5" + tenantId="1" type="compute" name="Compute" region="Global" diff --git a/keystone/content/common/samples/validatetoken.json b/keystone/content/common/samples/validatetoken.json index 004b9110..51be89fd 100644 --- a/keystone/content/common/samples/validatetoken.json +++ b/keystone/content/common/samples/validatetoken.json @@ -10,7 +10,12 @@ "roles":[{ "id":"234", "name":"compute:admin" - } + }, + { + "id":"234", + "name":"object-store:admin", + "tenantId":"1" + } ], "roles_links":[] } diff --git a/keystone/content/common/samples/validatetoken.xml b/keystone/content/common/samples/validatetoken.xml index 9578498f..b389ad63 100644 --- a/keystone/content/common/samples/validatetoken.xml +++ b/keystone/content/common/samples/validatetoken.xml @@ -4,10 +4,8 @@ id="ab48a9efdfedb23ty3494"/> <user id="123" username="jqsmith"> <roles xmlns="http://docs.openstack.org/identity/api/v2.0"> - <role xmlns="http://docs.openstack.org/identity/api/v2.0" - id="234" name="Admin" tenantId="one"/> - <role xmlns="http://docs.openstack.org/identity/api/v2.0" - id="345" name="compute:cloud_admin"/> + <role id="123" name="Admin" tenantId="one"/> + <role id="234" name="object-store:admin" tenantId="1"/> </roles> </user> </access> diff --git a/keystone/content/common/xsd/endpoints.xsd b/keystone/content/common/xsd/endpoints.xsd index 5f230761..acc82d72 100644 --- a/keystone/content/common/xsd/endpoints.xsd +++ b/keystone/content/common/xsd/endpoints.xsd @@ -14,7 +14,7 @@ xmlns:atom="http://www.w3.org/2005/Atom" targetNamespace="http://docs.openstack.org/identity/api/v2.0" > - + <include schemaLocation="api.xsd"/> <!-- Import ATOM specific schema definitions --> <import vc:minVersion="1.1" namespace="http://www.w3.org/2005/Atom" schemaLocation="atom/atom.xsd" /> @@ -136,6 +136,17 @@ </xsd:documentation> </annotation> </attribute> + <attribute name="tenantId" type="xsd:string" use="optional"> + <annotation> + <xsd:documentation + xml:lang="EN" + xmlns="http://www.w3.org/1999/xhtml"> + <p> + Tenant id to which the endpoints belong. + </p> + </xsd:documentation> + </annotation> + </attribute> <anyAttribute namespace="##other" processContents="lax"/> </complexType> <complexType name="EndpointList"> |
