Skip to content
New issue

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

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

Already on GitHub? # to your account

Improve behaviour with restricted application keys #27

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Katharine
Copy link

It is now possible to create application keys with restrictions. These keys only have one access to one bucket, and to a subset of possible API calls.

Most importantly, these restricted keys cannot freely call b2_list_buckets, which renders them unusable with b2blaze. This PR makes a minimal change to make these keys work: when using such a restricted key, only try listing the one permitted bucket.

This is an incomplete solution: a key could theoretically not have the ability to call b2_list_buckets even for its single permitted bucket, and b2blaze has little reason to require that they can. However, it solves the most common case where the keys are created via the web UI, which always grants access to b2_list_buckets.

I've tested this using the subset of the integration tests that don't involve creating/destroying buckets, but by the nature of the problem and the current testing setup, I can't really include these tests in the repo usefully.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant