Reputation: 1
Is it a good idea for the client to communicate directly to Azure Blob Storage? If we do it this way, how will we perform server side validation?
For example. Say I want to use blob storage to manage my uploaded images. But I want to prevent users from uploading certain image types and also files that are larger than 10 mb. How can I implement server side validation for this?
Upvotes: 0
Views: 279
Reputation: 58733
You have to handle the files in your back-end, you cannot allow them to upload the files directly in this case.
So you take the file in, validate it, and then upload it to Storage. And don't give the keys to the client.
Upvotes: 1