diff --git a/barbican/common/config.py b/barbican/common/config.py index 30c6a2b35..a07c8f56e 100644 --- a/barbican/common/config.py +++ b/barbican/common/config.py @@ -287,15 +287,12 @@ def set_lib_defaults(): set_middleware_defaults() - # TODO(gmann): Remove setting the default value of config policy_file - # once oslo_policy change the default value to 'policy.yaml'. - # https://github.com/openstack/oslo.policy/blob/a626ad12fe5a3abd49d70e3e5b95589d279ab578/oslo_policy/opts.py#L49 - DEFAULT_POLICY_FILE = 'policy.yaml' + # TODO(gmann): Remove setting the default value of the RBAC + # config options once barbican is ready for new RBAC. policy_opts.set_defaults( CONF, - DEFAULT_POLICY_FILE, - enforce_scope=True, - enforce_new_defaults=True) + enforce_scope=False, + enforce_new_defaults=False) def set_middleware_defaults(): diff --git a/barbican/common/policy.py b/barbican/common/policy.py index c95435338..1c24c0527 100644 --- a/barbican/common/policy.py +++ b/barbican/common/policy.py @@ -24,14 +24,10 @@ ENFORCER = None # TODO(gmann): Remove setting the default value of config: -# - policy_file once oslo_policy change the default value to 'policy.yaml'. -# https://github.com/openstack/oslo.policy/blob/a626ad12fe5a3abd49d70e3e5b95589d279ab578/oslo_policy/opts.py#L49 # - 'enforce_scope', and 'enforce_new_defaults' once barbican is ready with the # new RBAC (oslo_policy enable them by default) -DEFAULT_POLICY_FILE = 'policy.yaml' opts.set_defaults( CONF, - DEFAULT_POLICY_FILE, enforce_scope=False, enforce_new_defaults=False) diff --git a/requirements.txt b/requirements.txt index 047b6c788..56418e009 100644 --- a/requirements.txt +++ b/requirements.txt @@ -14,7 +14,7 @@ oslo.i18n>=3.15.3 # Apache-2.0 oslo.messaging>=14.1.0 # Apache-2.0 oslo.middleware>=3.31.0 # Apache-2.0 oslo.log>=4.3.0 # Apache-2.0 -oslo.policy>=3.11.0 # Apache-2.0 +oslo.policy>=4.5.0 # Apache-2.0 oslo.serialization!=2.19.1,>=2.18.0 # Apache-2.0 oslo.service!=1.28.1,>=1.24.0 # Apache-2.0 oslo.upgradecheck>=1.3.0 # Apache-2.0