1754 Commits

Author SHA1 Message Date
Jenkins
4e62c2832e Merge "Remove unused fixtures" 2015-05-14 06:52:53 +00:00
Jenkins
3548c78f70 Merge "Pass OS_* env vars fix for tox 2.0" 2015-05-14 04:38:02 +00:00
Jenkins
8897bc6db8 Merge "Don't autodoc the test suite" 2015-05-14 00:44:06 +00:00
Brant Knudson
26f8e3ff3d Pass OS_* env vars fix for tox 2.0
Tox 2.0 stopped passing environment variables from the parent to
the tests, so the functional tests were failing since they rely
on keystone CLI getting the OS_* environment variables.

Change-Id: I4f05379df41a3f6ca24ce8eb6911144a381f058e
2015-05-13 19:31:33 -05:00
Jenkins
6a3f1fd730 Merge "Removes temporary fix for doc generation" 2015-05-13 00:40:59 +00:00
Victor Stinner
e7853b8909 Remove unused fixtures
DisableModuleFixture and NoModuleFinder fixtures are no more used.

Change-Id: I55a5e106b5d4d618918ee21b33afd0154e22f6b7
2015-05-12 23:07:35 +02:00
OpenStack Proposal Bot
9f630bc178 Updated from global requirements
Change-Id: I36854e21c8fd478e4d202bb82be5146612ac161e
2015-05-12 14:35:26 +00:00
Dolph Mathews
5c0c8ce2a1 Use 'mapping_id' instead of 'mapping' in federation protocol tests
Change-Id: I7abf8413b949f38fd53e806dc90365986a31d921
Closes-Bug: 1453865
2015-05-11 16:14:25 +00:00
Dolph Mathews
3f757656a4 Use 'id' instead of 'protocol_id' in federation protocol tests
The actual attribute returned in object references of the /protocols API
is 'id', as in all other keystone APIs that return objects. The
implementation of new_ref() here doesn't actually include an 'id'
reference though, and goes out of it's way to test the wrong thing. This
patch fix that, eliminates the workarounds, and does a touch of
refactoring to bring these tests in line with tests of other client
managers.

Change-Id: I9a272b3ef91934e780106d89b5091b4bfb87ad29
Closes-Bug: 1453847
2015-05-11 15:40:33 +00:00
Doug Hellmann
3eb89ad7cc Drop use of 'oslo' namespace package
The Oslo libraries have moved all of their code out of the 'oslo'
namespace package into per-library packages. The namespace package was
retained during kilo for backwards compatibility, but will be removed by
the liberty-2 milestone. This change removes the use of the namespace
package, replacing it with the new package names.

The patches in the libraries will be put on hold until application
patches have landed, or L2, whichever comes first. At that point, new
versions of the libraries without namespace packages will be released as
a major version update.

Please merge this patch, or an equivalent, before L2 to avoid problems
with those library releases.

Blueprint: remove-namespace-packages
https://blueprints.launchpad.net/oslo-incubator/+spec/remove-namespace-packages

Change-Id: I387a7a1a817058a4daca313fe6df60612cb84864
2015-05-08 13:37:43 +00:00
David Stanek
d0ca84c16e Don't autodoc the test suite
Don't build API documentation for the keystoneclient tests.
These are not public functions, pollute the existing docs, and extend
the time required to build docs.

A re-implementation of be1e94f

Change-Id: Ib0e91ebfe4234bc3332b7c3051dba98248312a34
2015-05-07 16:31:09 +00:00
Jenkins
91de8422de Merge "Adapter version is a tuple" 2015-05-07 11:54:45 +00:00
Jamie Lennox
dfda42b331 Sync from oslo incubator
Sync with oslo incubator to remove the oslo namespaced packages. These
will be removed during the liberty cycle.

Blueprint: remove-namespace-packages
Oslo-incubator commit: 691b2c40be88e44d9377be782db813432c572653

Change-Id: Ia267f84ec35d3e282bec69f48024a14350ace896
2015-05-07 21:08:17 +10:00
David Stanek
045e47938f Removes temporary fix for doc generation
A temporary fix was added to get around a bug in how pbr handles
its autodoc_tree_index_modules setting. Since this bug is fixed we no
longer need the work around.

Change-Id: Id8274ef5c244bf50a34702ed9b4e50d3b82d8028
Closes-Bug: #1260495
2015-05-07 03:12:18 +00:00
Jamie Lennox
c7ec27a448 Ensure that failing responses are logged
The boolean value of a failed response is False and so the way we
populate the log output does not work when the request failed.

When logging check that a response is not None rather than simply
checking it's boolean value.

Change-Id: I07fb46f156fdf8267fd3d4dc7c587cd604838d73
Closes-Bug: #1451625
2015-05-05 11:02:35 +10:00
ZhiQiang Fan
8994d901ad add --slowest flag to testr
with --slowest flag, the slowest unit test cases will be printed,
which is useful to check performance issue.

Change-Id: I282845967877ed9298ca6f7f8bd6699a118fec1a
2015-05-04 16:07:31 +08:00
Jamie Lennox
17d51f771e Prompt for password on CLI if not provided
load_from_argparse_arguments is very specifically for use with argparse.
We can therefore safely prompt for a password from the user if none is
provided and it won't affect config options or other loading mechanisms.

Change-Id: Ib76743b768c5f0eef756184f1da49613423298f0
2015-05-02 14:09:22 +10:00
Brant Knudson
99e3b48a21 Adapter version is a tuple
The docstring for Adapter says that the version is a tuple like
(3,0), but the HttpClient was passing a string like "v3".

Closes-Bug: 1450272
Change-Id: I74b009d68f5601bda3ae92b3c8de1ecef00d8316
2015-04-30 01:28:34 +00:00
Jenkins
39b7f963f5 Merge "Add endpoint and service ids to fixtures" 2015-04-30 00:33:39 +00:00
Jenkins
fc7fb0d76b Merge "Document non-standard encoding of the PKI token." 2015-04-29 16:04:28 +00:00
Victor Stinner
37742ec520 Remove keystoneclient.middleware
The code has been moved to the new keystonemiddleware project and
keystone.middleware was deprecated since Juno. It's time to drop it in
Liberty.

Remove the directory keystoneclient/middleware/.

Remove test_auth_token_middleware.py, test_memcache_crypt.py and
test_s3_token_middleware.py in keystoneclient/tests/unit/.

Remove the create_middleware_cert shell function from
examples/pki/gen_pki.sh. And remove the call from
examples/pki/run_all.sh.

Remove netaddr, pycrypto and WebOb test dependencies, only needed to
test the removed middleware.

DocImpact: The keystoneclient.middleware module has been removed

Closes-Bug: #1449066
Change-Id: I88ddfdb674db1ec9c0fd4f9a62ae8347785ea10c
2015-04-27 16:41:46 +02:00
Deepti Ramakrishna
d5a39ad14a Document non-standard encoding of the PKI token.
More details by the code author in his blog post at
http://adam.younglogic.com/2014/02/compressed-tokens/.

Change-Id: I35c5eca2e04a74236bd8c7fb6daab3ea46b59b0e
Closes-Bug: #1352314
2015-04-21 21:56:25 -07:00
Jenkins
08fd4b1cd7 Merge "Inherited role domain calls on keystoneclient v3" 2015-04-18 18:37:40 +00:00
Jenkins
81ff5a277a Merge "Uncap library requirements for liberty" 2015-04-17 17:45:18 +00:00
Jenkins
039c6396f8 Merge "Make process_header private" 2015-04-17 15:01:16 +00:00
Jamie Lennox
0abcaff9f7 Add endpoint and service ids to fixtures
The service catalog should contain an endpoint id and service id in the
v3 token and an endpoint id in the v2 token.

Change-Id: I8835bcb7c68ae8d0175b6f58a4750cd6e25fd84c
2015-04-17 09:16:00 +10:00
Doug Hellmann
8b8009792b Uncap library requirements for liberty
Change-Id: Iedcc83c838ba91de90ab089728e6d0cde371394d
Depends-On: Ib948b756b8e6ca47a4c9c44c48031e54b7386a06
2015-04-16 18:13:09 +00:00
Jamie Lennox
f5e2aab08b Provide a means to get all installed plugins
Particular for use in writing error messages and help text it can be
useful to get a list of all the plugins that are installed on the
system. Provide a version that returns the classes as well so that you
don't have to reload the modules if the user is picking one.

Closes-Bug: #1423711
Change-Id: I021249eac8156c2d3ccbbacb7503184b6eb6e784
2015-04-15 11:36:15 +10:00
Brant Knudson
85eeecbd3d Fix s3_token middleware parsing insecure option
The "insecure" option was being treated as a bool when it was
actually provided as a string. The fix is to parse the string to
a bool.

Closes-Bug: 1411063
Change-Id: Id674f40532215788675c97a8fdfa91d4420347b3
2015-04-14 15:09:22 +00:00
Jamie Lennox
b3c18675cb Make process_header private
This should never have been added in a public way. I feel we are ok
making this private as there is no public use i can foresee.

Change-Id: Ib95365a11fa21146d51bea103c7709943aafdae8
2015-04-14 15:06:56 +10:00
Brant Knudson
a335b7f6f2 Fix tests to work with requests<2.3
The tests didn't pass with requests<2.3 because of the cookies
monkey-patching.

To test this, make sure the requests library in your tox venv is
the right level:

 $ .tox/py27/bin/pip install -U "requests<2.3"

Then run the tests.

Closes-Bug: 1442919
Change-Id: Ie93906ba2370dada2386a50ae2137337ccf98f10
2015-04-11 11:13:55 -05:00
Jamie Lennox
e79d571aa6 Increase minimum token life required
MIN_TOKEN_LIFE_SECONDS is the number of seconds that the token provided
must be valid for to be used when making authentication requests. 1
second has always been a dumb number and was not based on any existing
value.

Because a user token may be reused by a service to make requests on
behalf of a user if the token is valid when sent it may not be valid for
the life of the request.

2 minutes is also an arbitrary value, but it should allow plenty of time
for service requests to complete before being rejected.

Closes-Bug: #1441910
Change-Id: I395a0770e72d1ec7904e656ca382a5270f793a8b
2015-04-09 10:48:30 +10:00
Jenkins
eb98b08568 Merge "Update sample data with audit ids" 2015-04-09 00:25:59 +00:00
Jenkins
45daed6cf4 Merge "pep8 fix for CMS" 2015-04-09 00:25:20 +00:00
Jenkins
045c9dab6d Merge "Provide a generic auth plugin loader" 2015-04-08 06:47:31 +00:00
Jenkins
53dc900025 Merge "Return None for missing trust_id in fixture" 2015-04-08 04:13:41 +00:00
Adam Young
52e4305f38 Update sample data with audit ids
Change-Id: Ib288b6ff63982fb2cb1e200d2d23798482cfa346
2015-04-06 23:39:30 -04:00
Adam Young
6ee6af2c01 pep8 fix for CMS
Change-Id: I5bd4f46b34f0bbb21f1b6a6bfeeb2a26f5544156
2015-04-06 22:47:54 -04:00
henriquetruta
57b0fe2c8f Inherited role domain calls on keystoneclient v3
This patch allows the user to perform the
following API calls through the
python-keystoneclient:

Assign role to user on projects owned by a domain:
PUT /OS-INHERIT/domains/{domain_id}/users/{user_id}/roles/inherited_to_projects
List user's inherited project roles on a domain:
GET /OS-INHERIT/domains/{domain_id}/users/{user_id}/roles/inherited_to_projects
Check if user has an inherited project role on domain:
HEAD /OS-INHERIT/domains/{domain_id}/users/{user_id}/roles/{role_id}/inherited_to_projects
Revoke an inherited project role from user on domain:
DELETE /OS-INHERIT/domains/{domain_id}/users/{user_id}/roles/{role_id}/inherited_to_projects

These same operations regarding groups instead of users are also available.

Co-Authored-By: Raildo Mascena <raildo@lsd.ufcg.edu.br>
Co-Authored-By: Samuel Medeiros <samuel@lsd.ufcg.edu.br>

Change-Id: I877168e3922cdd19868d508ef9fc34d0c7e7abcb
Closes-bug: 1367866
2015-04-06 13:41:41 -03:00
Jenkins
cf472fa6d7 Merge "Make non-import packages lazy" 2015-04-06 07:06:49 +00:00
Jenkins
ebca445c46 Merge "Don't autodoc the test suite" 2015-04-02 01:58:22 +00:00
Jenkins
a2e7a7ea57 Merge "Add support to create ECP assertion based on a token" 2015-04-02 01:44:45 +00:00
Jenkins
d717e219d2 Merge "Add support to create SAML assertion based on a token" 2015-04-02 01:32:33 +00:00
Steve Martinelli
1628b77a79 Add support to create ECP assertion based on a token
A user should be able to exchange their token for an ECP wrapped
SAML assertion.

implements bp generate-saml-assertions

Change-Id: Ic9c20aebc5cd91650576ad050c09779df54f1d94
2015-03-31 12:47:16 -04:00
Steve Martinelli
a2fc6cf4f4 Add support to create SAML assertion based on a token
A user should be able to exchange their token for a SAML assertion
that is valid on a service provider (the user should must provide
this data).

implements bp generate-saml-assertions

Change-Id: I5cb635929c7f6823ab1e4b1db5e48045be9e0737
2015-03-31 12:43:16 -04:00
Jamie Lennox
389c3ee836 Allow requesting an unscoped Token
The keystone server understands that specifying unscoped in the scope
section of an auth request means that it should ignore the
default_project_id of a user and return an unscoped token.

This is the client side change to allow requesting these tokens via an
auth plugin.

Change-Id: Iba5ebcea0bf0d8e5a31d552977276fc03e536c67
Implements: bp explicit-unscoped
2015-03-31 10:03:20 +11:00
Jamie Lennox
831ba037b0 Support /auth routes for list projects and domains
The /auth routes are the preferred mechanism for listing the projects
and domains that the current token can be authenticated to as they
supports both federated and regular tokens.

Expose these routes via the client so that they can be consumed.

Change-Id: I9724a648ebd9d21edf8ffcc64f4cdb897a99101c
2015-03-31 08:47:25 +11:00
Jamie Lennox
fd16240be4 Support discovery on the AUTH_INTERFACE
We need to allow get_endpoint(interface=auth.AUTH_INTERFACE, version=X)
to support the same version negotiation that the service catalog goes
through. This is required to support generic plugins where you often
provide an unversioned auth_url to the plugin but need a versioned URL
to query for available projects.

Change-Id: Id423a538c169264a81c5714e6a9eff9b33912a55
Closes-Bug: #1438013
2015-03-30 15:59:30 +11:00
Jenkins
3b8a5d0276 Merge "Expose audit_id via AccessInfo" 2015-03-30 01:14:08 +00:00
Jamie Lennox
dfc90092a7 Expose audit_id via AccessInfo
The audit_id is now a standard part of the v2 and v3 tokens. Expose it
via AccessInfo so that it is usable for services and middleware.

Change-Id: I14ddcfee5434084ad9da73c384e6f456602fdd2b
Closes-Bug: #1437129
2015-03-28 14:33:15 +11:00