Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix principals_allowed #281

Merged
merged 3 commits into from
Feb 5, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@ snovault
Change Log
----------

11.9.1.0b0
==========

* Removes strip of ``role.`` permissions so smaht-portal roles work


11.9.0
======
Expand Down Expand Up @@ -71,7 +76,7 @@ Change Log
11.0.1
======

* Repair reference to ``load_data_by_type`` to resolve correctly when loadxl
* Repair reference to ``load_data_by_type`` to resolve correctly when loadxl
is absent entirely from the application repo


Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "dcicsnovault"
version = "11.9.0"
version = "11.9.1.0b0" # to become 11.10.0
description = "Storage support for 4DN Data Portals."
authors = ["4DN-DCIC Team <[email protected]>"]
license = "MIT"
Expand Down
5 changes: 4 additions & 1 deletion snovault/resources.py
Original file line number Diff line number Diff line change
Expand Up @@ -736,8 +736,11 @@ def principals_allowed(self):
elif Authenticated in principals:
principals = [Authenticated]
# Filter our roles
# NOTE: previously, we removed things that began with role. however this
# breaks how smaht-portal permissioning is implemented, so we are no longer
# suppressing them - Will Jan 31 2024
allowed[permission] = [
p for p in sorted(principals) if not p.startswith('role.')
p for p in sorted(principals) # if not p.startswith('role.')
]
return allowed

Expand Down
Loading