Azure / azure-sdk-for-python

This repository is for active development of the Azure SDK for Python. For consumers of the SDK we recommend visiting our public developer docs at https://learn.microsoft.com/python/azure/ or our versioned developer docs at https://azure.github.io/azure-sdk-for-python.
MIT License
4.63k stars 2.84k forks source link

Expose `ownership` and `permissions` permission in `ContainerSasPermissions` #38637

Open janjagusch opened 16 hours ago

janjagusch commented 16 hours ago

Is your feature request related to a problem? Please describe.

The ContainerSasPermissions class doesn't expose a way to set the ownership or permissions permission: https://github.com/Azure/azure-sdk-for-python/blob/a71376d5d0942c08f431178c40ec230d851f54a0/sdk/storage/azure-storage-blob/azure/storage/blob/_models.py#L929-L950

As a workaround, I have to provide the string repesentation directly to the generate_sas_container function:

generate_container_sas(permission="op")

Describe the solution you'd like

I want to use the ContainerSasPermissions class:

generate_container_sas(permission=ContainerSasPermissions(ownership=True, permissions=True))
github-actions[bot] commented 16 hours ago

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @jalauzon-msft @vincenttran-msft.