3

Is there a way to generate a SAS token or policy for a virtual path within blob container ?

E.g. I have a blob container called mycontainer. Inside it have the following blobs

FolderA/PathA/file.pdf

FolderA/PathA/file2.mpg

FolderA/PathC/file.doc

FolderB/PathA/file.pdf

I want to generate SAS token such that the client/application can perform operations inside of FolderA only within container mycontainer

Is that possible ?

Alternate approach is either to

a) Create a list of SAS tokens for each file (i.e. blockblob) within FolderA

b) Re-design such that FolderA is a blob container instead

1 Answer 1

3

I want to generate SAS token such that the client/application can perform operations inside of FolderA only within container mycontainer

Is that possible ?

No, it is not possible because Folder inside a blob container is a virtual entity. Azure blob storage supports only two level hierarchy - container and blob. A folder is simply the prefix in a blob's name.

Both of the solutions you mentioned below are good alternatives and you would be able to use either of them depending on your use case. My recommendation would be to use approach (b) as it provides a nice isolation for individual users in the sense that each user gets her/his own container where they can save their own files.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.