Azure Storage Block Blobs
Introduction
Azure Block Blobs are the equivalent of AWS S3 and allows to store objects. Access to these objects can then be done over HTTP using a URL that is generated.
What are we going to cover?
We will look at
misconfigurations with Azure Block Blobs (AWS S3 equivalent)
Steps to Setup a Azure Block Blob
Create a new Blob Storage object using the following steps
Click on
Storage Accountfrom the favorites menu and clickCreate storage accountor the+ Addbutton.Provide a unique storage account name. For example
azuretestbucket. This has to be unique across the Internet. So you can use your unique-name to proceed.Under account kind select
BlobStoragefrom the drop down.Leave all the remaining options at default

Click
Next: Networkingand let the defaultPublic endpoint (all networks)Click
Next:Advanced. Do not change anything here. Click onReview + CreateClick
Createafter validation is successful, to setup your Azure Block Blob.Click on
Go to resource

Under
Settings, click onPropertiesand copy thePRIMARY BLOB SERVICE ENDPOINT. Forazuretestbucket, it will behttps://azuretestbucket.blob.core.windows.net/
Adding data to the Blob
To add data to the Blob, a container inside the Blob must be created. This can be done via the Storage Explorer.
Azure Storage can also be managed using an external Storage manager (download link in references).
We will use the portal to upload and manage data to our Blob.
Click on
Storage Explorerin the left pane of the Storage account.Right click on
BLOB CONTAINERSand selectCreate Blob Container.Give it a name and set the
Public access leveltoContainer (annonymous read access for containers and blobs)Click on the newly created container and select
Uploadon the container menu

Select a file (non-sensitive).
Under Advanced, make sure the
Account keytoggle button is selectedSelect
Blob typetoBlock blobClick
UploadOnce Upload is completed, click on the object that was uploaded and click on
Copy URLNavigate to the URL to view the object.
To generate a signed URL
Right click on the uploaded object and select
Get Shared Access Signature (SAS)You can enable the
DELETEpermission as well.To access the uploaded file using the SAS browse to the SAS URL created.
To delete the object, use
curl -X DELETE https://SAS-URL-HERE
Additional References
Last updated