diff --git a/keystoneauth1/identity/v3/base.py b/keystoneauth1/identity/v3/base.py index 51b78d5c..1f8f8de0 100644 --- a/keystoneauth1/identity/v3/base.py +++ b/keystoneauth1/identity/v3/base.py @@ -154,7 +154,7 @@ class Auth(BaseAuth): elif self.trust_id: body['auth']['scope'] = {'OS-TRUST:trust': {'id': self.trust_id}} elif self.unscoped: - body['auth']['scope'] = {'unscoped': {}} + body['auth']['scope'] = 'unscoped' # NOTE(jamielennox): we add nocatalog here rather than in token_url # directly as some federation plugins require the base token_url diff --git a/keystoneauth1/tests/unit/identity/test_identity_v3.py b/keystoneauth1/tests/unit/identity/test_identity_v3.py index 27018213..5c88105b 100644 --- a/keystoneauth1/tests/unit/identity/test_identity_v3.py +++ b/keystoneauth1/tests/unit/identity/test_identity_v3.py @@ -550,7 +550,7 @@ class V3IdentityPlugin(utils.TestCase): self.assertEqual(token.user_id, ident['password']['user']['id']) self.assertEqual(password, ident['password']['user']['password']) - self.assertEqual({}, body['auth']['scope']['unscoped']) + self.assertEqual('unscoped', body['auth']['scope']) def test_unscoped_with_scope_data(self): a = v3.Password(self.TEST_URL,