"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "barbican/api/controllers/secrets.py" between
barbican-11.0.0.tar.gz and barbican-12.0.0.tar.gz

About: OpenStack Barbican is the OpenStack Key Manager service. It provides secure storage, provisioning and management of secret data.
The "Wallaby" series (latest release).

secrets.py  (barbican-11.0.0):secrets.py  (barbican-12.0.0)
skipping to change at line 255 skipping to change at line 255
@index.when(method='DELETE') @index.when(method='DELETE')
@utils.allow_all_content_types @utils.allow_all_content_types
@controllers.handle_exceptions(u._('Secret deletion')) @controllers.handle_exceptions(u._('Secret deletion'))
@controllers.enforce_rbac('secret:delete') @controllers.enforce_rbac('secret:delete')
def on_delete(self, external_project_id, **kwargs): def on_delete(self, external_project_id, **kwargs):
secret_consumers = self.consumer_repo.get_by_secret_id( secret_consumers = self.consumer_repo.get_by_secret_id(
self.secret.id, self.secret.id,
suppress_exception=True suppress_exception=True
) )
# With ACL support, the user token project does not have to be same as
# project associated with secret. The lookup project_id needs to be
# derived from the secret's data considering authorization is already
# done.
external_project_id = self.secret.project.external_id
plugin.delete_secret(self.secret, external_project_id) plugin.delete_secret(self.secret, external_project_id)
LOG.info('Deleted secret for project: %s', external_project_id) LOG.info('Deleted secret for project: %s', external_project_id)
for consumer in secret_consumers[0]: for consumer in secret_consumers[0]:
try: try:
self.consumer_repo.delete_entity_by_id( self.consumer_repo.delete_entity_by_id(
consumer.id, external_project_id) consumer.id, external_project_id)
except exception.NotFound: # nosec except exception.NotFound: # nosec
pass pass
 End of changes. 1 change blocks. 
0 lines changed or deleted 6 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)