Commit Graph

560 Commits

Author SHA1 Message Date
Takashi Kajinami 307296af5e Deprecate templated catalog driver
Keystone provided two in-tree catalog drivers, sql and templated.
However the templated driver hasn't been properly maintained.
The default template had not been updated for 8 years until it was
recently updated by [1].

This deprecates the driver assuming it's not widely used and sql driver
meets usual requirements.

This also restores the image service endpoints which were wrongly
removed by [1].

[1] c32bedb654

Related-Bug: #2013473
Change-Id: Iadb7bd5d7c4cf82aea2a7dbc1d8c4dbe53b9f763
2024-03-13 22:09:30 +09:00
Takashi Kajinami 6c7020c51a Drop remaining references to eventlet options
Because these were removed by [1]. Also update the previous release
note to document the upgrade impact on catalog information (like
endpoint urls) including string interpolations requiring these removed
options.

[1] 2a3c73c49b

Change-Id: If78d0b93665410b86754ea35653ca9d4c15c81c5
2024-01-27 21:02:14 +09:00
Takashi Kajinami c32bedb654 Fix outdated default catalog template
The file has not been update and is horribly outdated. This updates
the file to adapt to recent API versions available.

Closes-Bug: #2013473
Change-Id: Ibb373f198b528a9aea3546f28545ee4470d9b37b
2023-03-31 18:12:21 +09:00
Lance Bragstad d4a6023de5 Remove policy.v3cloudsample.json
We've make all the default policies keystone supports better by
incorporating default roles and scope types. These changes have made
the ``policy.v3cloudsample.json`` file obsolete.

Let's simply things for users, operators, and develpers by removing
it.

A follow-on patch will remove the test_v3_protection.py file since
those behaviors are passing all the protection tests with the default
policies in code.

Related-Bug: 1805880
Closes-Bug: 1630434
Closes-Bug: 1806762
Change-Id: Ie45955f5cc54563cc9704d7cb2b656b5544ae030
2019-10-02 20:26:05 +00:00
Lance Bragstad 5b995cc8fb Remove limit policies from policy.v3cloudsample.json
By incorporating system-scope and default roles, we've effectively
made these policies obsolete. We can simplify what we maintain and
provide a more consistent, unified view of default limit
behavior by removing them.

Change-Id: Ie0f333a9e8b60154711a24ba7d9ade531217eb71
Closes-Bug: 1805880
2019-09-24 19:25:45 -07:00
Lance Bragstad 8e67249d5b Add default roles and scope checking to project tags
This commit makes it so that project tags adhere to system-scope and
also incorporates default roles into the policy checks by default.

Change-Id: Ie36df5677a08d7d95f056f3ea00eda05e1315ea5
Closes-Bug: 1844194
Closes-Bug: 1844193
Related-Bug: 1806762
2019-09-19 02:48:39 +00:00
Zuul 18e0080af3 Merge "Remove system Domain Config from policy.v3cloudsample.json" 2019-09-15 22:15:24 +00:00
Zuul 778a8c17ce Merge "Remove system EC2 credentials from policy.v3cloudsample.json" 2019-09-15 22:15:22 +00:00
Vishakha Agarwal 6435017c24 Remove system EC2 credentials from policy.v3cloudsample.json
By relying on system-scope and default roles, these policies are now
obsolete.

Change-Id: Ie6be658a8e4dd028834a3fee956689f9513a37e9
Partial-Bug: #1806762
Closes-Bug: #1750678
2019-09-15 20:53:09 +05:30
Vishakha Agarwal 566f8e734d Remove system Domain Config from policy.v3cloudsample.json
By relying on system-scope and default roles, these policies are now
obsolete.

Change-Id: I21473f757611cfd3299d0227eddef89d4ef624ff
Partial-Bug: #1806762
Closes-Bug: #1805366
2019-09-15 20:39:19 +05:30
Lance Bragstad cf22f8004e Remove obsolete grant policies from policy.v3cloudsample.json
This commit also removes an obsolete test case from
test_v3_protection.py.

Co-Authored-By: Colleen Murphy <colleen@gazlene.net>

Change-Id: Ic0a654494f96d5dffa0c4d4d96766ab4a2e090b1
Related-Bug: 1806762
2019-09-14 09:39:21 +00:00
Colleen Murphy 9b694fcd08 Implement system scope for domain role management
The roles API was partially converted to use default roles and system
scope but that work did not include converting the domain roles actions.
This commit completes the rest of the work and closes out the system
scope work for the roles API.

Change-Id: Iea5a1559e9bece2c0f310170f05260a978e27b47
Closes-bug: #1805400
Partial-bug: #1805880
2019-09-13 08:23:13 -07:00
Colleen Murphy afb312529b Remove implied roles policies from v3cloudsample
By incorporating system scope and default roles into keystone's default
policies for implied roles, we've effectively made these policies
obsolete.

Change-Id: I75515d3491517ea6e6fa17473a7890ce4653b481
Partial-bug: #1806762
Closes-bug: #1805371
2019-09-11 08:47:15 -07:00
Vishakha Agarwal 704cb2590e Remove system policy and its association from policy.v3cloudsample.json
By relying on system-scope and default roles, these policies are now
obsolete.

Change-Id: Ib2aa3e9023194ee578c617cdf2d53c6264c0e785
Partial-Bug: #1806762
Closes-Bug: #1805409
2019-09-08 12:48:48 +00:00
Lance Bragstad bb141b1fb4 DRY: Remove redundant policies from policy.v3cloudsample.json
The policies contained in policy.v3cloudsample.json pre-dated any of
the work to move policy defaults into code. Since deploying a policy
file is now optional, we can remove the redundant policies from this
file and make it more maintainable by not repeating ourselves and
violating the DRY principal.

The only policies left are ones that are testing workarounds for bug
968696. Meanwhile, we're pursuing fixes for scope types and default
roles:

  http://tinyurl.com/y5kj6fn9

These fixes are specific to certain resources to make reviews more
understandable for reviewers. As fixes for those bugs land, we will
be removing the remaining checks in this file, since the behavior will
be captured in new default check strings or in code.

Eventually, we will delete this file entirely since we will have
defaults in code that work for `admins`, `members`, and `readers` on
projects, domains, and the deployment system.

Change-Id: Ibbabe8fdc7989f15aa0edda2bf7b550a0dc16f83
Partial-Bug: 1806762
2019-04-02 19:09:53 +00:00
Colleen Murphy 8877e9f01c Remove redundant policies from v3cloudsample
By incorporating system and domain scope and default roles into
keystone's default policies for domains, we've effectively made these
policies obsolete. This change also removes the redundant group
management tests from the v3cloudsample tests.

Change-Id: I4e3b19f9cc025a472fb27a33955856c2cd17fd1d
Partial-Bug: #1806762
2019-03-27 21:02:02 +01:00
Lance Bragstad d2cc4c83c0 Consolidate user protection tests
This commit removes user policies from policy.v3cloudsample.json. By
incorporating system-scope, domain-scope, project-scope, and default
roles, we've effectively made these policies obsolete. We can simplify
what we maintain and provide a more consistent, unified view of
default user behavior by removing them.

This commit also adds an important filter to the GET /v3/users API by
making sure the users in the response are filtered properly if the API
was called with a domain-scoped token. This is needed in case domain
configuration isn't setup and short-circuits normalization of the
domain ID, which sometimes comes from the token if it is
domain-scoped.  Regardless of domain configuration being used, we
should protect against cases where data leaks across domains in the
name of security.

Finally, this commit moves a couple of tests from test_v3_protection
to test_users protection tests that ensures we do reasonable filtering
while normalizing domain IDs. The remaining tests from
test_v3_protection have been removed because they are no longer
applicable. These tests were testing an HTTP 403 was returned when a
domain users attempted to filter users for domains they didn't have
authorization on. We don't use this approach consistently in keystone.
Most other places where filtering is implemented, we ignore invalid
filters and instead return an empty list. For domain users attempting
to fish information out of another domain, they will receive an empty
list to be consistent with other parts of the API.

Change-Id: I60b2e2b8af172c369eab0eb2c29f056f5c98ad16
Parial-Bug: 1806762
2019-03-26 12:58:15 +00:00
Zuul 9940021f3c Merge "Remove assignment policies from policy.v3cloudsample.json" 2019-03-26 06:42:41 +00:00
Zuul e3e5913846 Merge "Remove system assignment policies from policy.v3cloudsample.json" 2019-03-26 01:31:48 +00:00
Vishakha Agarwal 64a455ef94 Remove assignment policies from policy.v3cloudsample.json
By incorporating system-scope and default roles, we've
effectively made these policies obsolete. We can simplify
what we maintain and provide a more consistent, unified
view of default service behavior by removing them.

This commit also removes some redundant tests in test_v3_protection
or corrects them.

Partial-Bug: 1806762
Change-Id: I008aed9c01b9e834a197444ff2dc1f6eb1ba25b1
2019-03-25 18:02:01 +00:00
Lance Bragstad 0dbc8a88e8 Remove system assignment policies from policy.v3cloudsample.json
By relying on system-scope and default roles, these policies are now
obsolete.

Change-Id: I7a17c2baa6e23b6a5d8fe21668a66ea8c8a89232
Partial-Bug: 1806762
2019-03-21 19:28:08 +00:00
Lance Bragstad 546b7f1bba Remove project policies from policy.v3cloudsample.json
By incorporating system-scope, domain-scope, project-scope, and
default roles, we've effectively made these policies obsolete. We can
simplify what we maintain and provide a more consistent, unified view
of default project behavior by removing them.

Change-Id: I80221b72ce0f234440e6d6aaea51869bd5f1c6e7
Related-Bug: 1806762
2019-03-20 20:22:03 +00:00
Lance Bragstad c83fcbc42a Remove service policies from policy.v3cloudsample.json
By incorporating system-scope and default roles, we've effectively
made these policies obsolete. We can simplify what we maintain and
provide a more consistent, unified view of default service behavior by
removing them.

Change-Id: Ifa2282481ee3fc544c1d50ac8e8972b0d3a5332e
Closes-Bug: 1804462
2019-03-04 15:39:27 +00:00
Zuul 7076d704ab Merge "Remove protocol policies from v3cloudsample.json" 2019-03-02 03:03:45 +00:00
Zuul 60ae125107 Merge "Remove endpoint policies from policy.v3cloudsample.json" 2019-03-01 21:29:45 +00:00
Lance Bragstad 24b8db9e06 Remove protocol policies from v3cloudsample.json
By incorporating system-scope and default roles, we've effectively
made these policies obsolete. We can simplify what we maintain and
provide a more consistent, unified view of default protocol
behavior by removing them.

Related-Bug: 1806762
Closes-Bug: 1804518
Change-Id: Ia839555d8211596213311c4246135cdae4f46ab2
2019-02-28 16:24:56 +00:00
Zuul a0091f6a09 Merge "Remove role policies from policy.v3cloudsample.json" 2019-02-28 03:46:50 +00:00
Lance Bragstad 6d756ad612 Remove role policies from policy.v3cloudsample.json
By incorporating system-scope and default roles, we've effectively
made these policies obsolete. We can simplify what we maintain and
provide a more consistent, unified view of default role behavior by
removing them.

Note that these changes are slightly different from the
policy.v3cloudsample.json role policies, hence the removed tests. In
policy.v3cloudsample.json, domain users were allowed to get and list
global roles. So were project users. This behavior is changing because
global roles are considered global resources of the deployment, and
they should be managed by system users. Domain users should be able to
add and remove domain specific roles, which will come in a subsequent
series of patches. This approach is being taken because it is a safer
default for a system level resource (global roles) and still allows
the same functionality for domain users through domain-specific roles.

Change-Id: Iddaa59024a1dcefd4d791b95413602865888c1ff
Closes-Bug: 1806713
2019-02-27 21:57:17 +00:00
Lance Bragstad 6c6c6049f5 Remove endpoint policies from policy.v3cloudsample.json
By incorporating system-scope and default roles, we've effectively
made these policies obsolete. We can simplify what we maintain and
provide a more consistent, unified view of default endpoint behavior
by removing them.

Change-Id: I423e54c359b787efdda70f5d141f21e9103f3524
Closes-Bug: 1804482
2019-02-27 16:17:26 +00:00
Lance Bragstad 87e50c029e Remove domain policies from policy.v3cloudsample.json
By incorporating system scope and default roles into keystone's
default policies for domains, we've effectively made these policies
obsolete.

Related-Bug: 1806762

Change-Id: I96079b15c980de6a4ba71f49d7b39790c1115767
2019-02-27 16:13:49 +00:00
Lance Bragstad c0e6d4498a Remove idp policies from policy.v3cloudsample.json
By incorporating system-scope and default roles, we've effectively
made these policies obsolete. We can simplify what we maintain and
provide a more consistent, unified view of default idp behavior
by removing them.

Change-Id: I6091d1cdbc4e1fa3a3d5f83a707f003416a43ea0
Closes-Bug: 1804517
2019-02-25 22:03:35 +00:00
Lance Bragstad 65f76c1722 Remove mapping policies from policy.v3cloudsample.json
By incorporating system-scope and default roles, we've effectively
made these policies obsolete. We can simplify what we maintain and
provide a more consistent, unified view of default mapping
behavior by removing them.

Change-Id: Ie01b5a79aaf363b3783c92578f56654b993b5e76
Closes-Bug: 1804519
2019-02-19 01:49:28 +00:00
Lance Bragstad 1b7db4a062 Remove region policies from policy.v3cloudsample.json
By incorporating system-scope and default roles, we've effectively
made these policies obsolete. We can simplify what we maintain and
provide a more consistent, unified view of default region behavior
by removing them.

Change-Id: I0f982d71fc4a5d33ed66cb34d7388f3c4655e3ef
Closes-Bug: 1804292
2019-02-11 17:52:11 +00:00
Lance Bragstad 6bac9930eb Remove service provider policies from v3cloudsample.json
By incorporating system-scope and default roles, we've effectively
made these policies obsolete. We can simplify what we maintain and
provide a more consistent, unified view of default service provider
behavior by removing them.

Change-Id: I01b0e7152ae282c49644b3bad1bcb2c8119aed58
Closes-Bug: 1804520
2019-01-25 16:31:30 +00:00
Lance Bragstad 7af769278a Remove registered limit policies from policy.v3cloudsample.json
By incorporating system-scope and default roles, we've effectively
made these policies obsolete. We can simplify what we maintain and
provide a more consistent, unified view of default registered limit
behavior by removing them.

Change-Id: I1ee7fb53a71361966584363687051615dc832329
Related-Bug: 1805880
2019-01-08 18:17:02 +00:00
Lance Bragstad 7c129f1c70 Remove obsolete credential policies
The policy.v3cloudsample.json policy file attempted to solve
admin-ness issues with elaborate policy checks. These checks are no
longer needed with advent of system scope and incorporating system
scope into keystone APIs.

This commit removes the credential policies from the
policy.v3cloudsample.conf policy file since the new defaults introduce
more flexibility by consuming scope, rendering the policies in
policy.v3cloudsample.conf obsolete. More specific test coverage has
also been added for each new case in
keystone.tests.unit.protection.v3.test_credentials.

Change-Id: I6c74f40640da23375574f4a26ee60779ef08d120
Related-Bug: 1788415
2018-10-30 13:25:24 +00:00
Morgan Fainberg ea6755a825 Remove paste-ini
Remove the paste-ini for Stein release. It has not been used since
Rocky and was maintained for simplicity of deployment projects.

Change-Id: Iec0c204e8521694e4d48dbef03a72ecdb173e435
2018-10-15 17:57:59 +00:00
Lance Bragstad 0022adb6ae Add policy for limit model protection
We plan to expose the enforcement model a deployment is using via
the limit API. This commit prepares for that implementation by
introducing the policy for it.

Change-Id: I03c9cec3646ee354ebcdd4ddc1168e00d611171b
Related-Bug: 1765193
2018-06-19 20:27:00 +08:00
wangxiyuan b385864c5d Unified limit update APIs Refactor
According to the API-WG's suggestion, the update registered
limit/project limit APIs should be refactored as:
1. Change PUT to PATCH
2. Remove batch update limits support for PATCH

Closes-Bug: #1754184
Change-Id: I1102166ab425a55d8eaf85c75d8fd3a7dfbaceb6
2018-06-15 09:05:35 +08:00
Morgan Fainberg 8bf335bb01 Remove pastedeploy
This patchset removes the lingering code that supported paste.deploy
that is obsolted by the loader wrapped around keystone's use of Flask.

 * The keystone-paste.ini file has been removed.

 * All options have been removed (without deprecation) as they are no
   longer referenced.

 * The TokenAuthMiddleware code (with deprecation warning) has been
   removed as it was only provided to ensure compatibility with paste.ini
   files that were not updated (ensuring not breaking a deployer that
   did not update paste.ini file to remove it from the pipeline).

 * Paste deploy entrypoints have been removed.

Change-Id: I35064a440ef718f50c7e644e8b2d56a99c3ec74f
2018-06-06 19:30:26 +00:00
Jamie Lennox b39132daa0 Remove the TokenAuth middleware
The entire purpose of this confusingly named middleware is to take token
values out of headers and put them into a dictionary. There's no point
in this, we have a request class that can abstract this for us.

Deprecate the middleware, it's unnecessary.

bp: deprecated-as-of-rocky
Change-Id: I09310bab6bd728127288ba4c3cf8f884a31e2b98
2018-05-10 14:40:39 +00:00
Jesse Pretorius 3ffee23599 Remove the sample .conf file
The sample configuration file is almost never up to date as it has to
be updated by a person submitting a patch.

The implementation of published autogenerated sample config files in
documentation was done in I88a2429dd3cacd1d014b5b441b98fbfee7e1e208
and in If00cd3bcc654a45944c0bc8b3f146c75bd970f9a. These generate
sample configuration files and publish them in the documentation on
every commit, ensuring that they are always up to date, and not
requiring human intervention to be updated.

As has been done with nova (in Mitaka), cinder (in Newton), and
neutron (in Newton) this patch removes the sample config file from the
git tree and replaces it with a README file explaining how to generate
them, or where to find the latest published versions in the online
documentation.

This commit also breaks a related testcase into two distinct tests for
easier readability, making it clearer what the behavior is through one
assertion/concept per test.

Depends-On: https://review.openstack.org/#/c/562007/
Change-Id: Ic4d6a98035f59b6ebe48d9c85af50fc9408fc3ab
2018-04-18 19:41:37 +00:00
Lance Bragstad ae7c7a0f07 Update sample configuration file for Queens
This patch was generated using the tox environment for generating
sample configuration files:

  tox -e genconfig

Change-Id: I225432d54b28ed5e83de7f33adee38b07e0fa6e3
2018-02-06 21:19:35 +00:00
Colleen Murphy 166eced28b Add Application Credentials controller
Add the controller, router, schema, and policies for application
credentials. If a secret is not provided, one is generated at the
controller layer.

bp application-credentials

Depends-on: Id26a2790acae25f80bd28a8cb121c80cb5064645
Depends-on: Icbd58464182b082854fb5d73ccc93c900ede020c

Change-Id: I7a371d59c19a11e55f17baf12d92327c1258533d
2018-01-27 11:55:05 +01:00
Zuul d8a0c5e3d0 Merge "Implement policies for limits" 2018-01-26 13:08:41 +00:00
wangxiyuan 9ba24b91a4 Implement policies for limits
This commit lays down the policies needed to protect the unified limit
API. A subsequent patch will expose the implementation.

bp unified-limits

Change-Id: I952fe6213adce86a92d7d607c9b639076b279f6c
2018-01-25 15:45:51 +08:00
Lance Bragstad a50fafd246 Implement GET /v3/auth/system
Keystone has APIs for retrieving projects and domains based on the
role assignments a user has on projects and domains. We should
introduce similar functionality for system assignments. This will
make discovering system access for users and client easier.

bp system-scope

Change-Id: Iab577fcd1b57b8b5593c3f9d50a772466383a999
2018-01-24 01:09:16 +00:00
Gage Hugo 3bcaec39a4 Remove whitespace from policy sample file
This change removes a rogue whitespace character from the
policy.v3cloudsample file.

Change-Id: Ie46e7dc6a01de87bad5966f6a960b7fac11ae83e
2018-01-10 04:37:28 +00:00
Lance Bragstad cd9064d2b9 Add group system grant policies
This commit introduces new policies that control RBAC for assigning
groups roles on the system. Since the management of system roles is a
system-level operation, each policy has `system` set for scope_types.

bp system-scope

Change-Id: Ide491be9563f74f758c5de55990916292228e0d9
2017-12-22 01:56:37 +00:00
Lance Bragstad 616542a051 Add user system grant policies
This commit introduces new policies that control RBAC for assigning
users roles on the system. Since the management of system roles is a
system-level operation, each policy has `system` set as scope_types.

bp system-scope

Change-Id: Ie606e769427a5ca422997efe92402e712f3cf45f
2017-12-20 15:56:04 +00:00