<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/windows-azure-storage-magic-with-shared-access-signatures-bbc1g5brb" -->

---
title: Windows Azure Storage magic with Shared Access Signatures
description: A walkthrough of Windows Azure Blob Storage Shared Access Signatures (SAS), showing how to grant temporary read access to a blob, how to combine SAS with an...
canonical: https://daily.dev/posts/windows-azure-storage-magic-with-shared-access-signatures-bbc1g5brb
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Windows Azure Storage magic with Shared Access Signatures | daily.dev
og:description: A walkthrough of Windows Azure Blob Storage Shared Access Signatures (SAS), showing how to grant temporary read access to a blob, how to combine SAS with an...
og:url: https://daily.dev/posts/windows-azure-storage-magic-with-shared-access-signatures-bbc1g5brb
og:image: https://api.daily.dev/og/posts/bbc1G5Brb.png
og:image:alt: Windows Azure Storage magic with Shared Access Signatures
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Windows Azure Storage magic with Shared Access Signatures

**[Maarten Balliauw](https://daily.dev/sources/maartenballiauw)** · 5 min read · 0 upvotes · 0 comments

## Summary

A walkthrough of Windows Azure Blob Storage Shared Access Signatures (SAS), showing how to grant temporary read access to a blob, how to combine SAS with an ASP.NET MVC redirect action to keep business logic on the web server while offloading downloads to blob storage, and how to use the SAS content disposition and content type headers to serve human-friendly filenames. Includes a note that this header feature requires setting the DefaultServiceVersion to 2013-08-15 on the blob client.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://blog.maartenballiauw.be/posts/2014-02-13-windows-azure-storage-magic-with-shared-access-signatures>

## Questions this post answers

### How do I set a custom filename and content type for a blob download using Azure Shared Access Signatures?

Pass a SharedAccessBlobHeaders object to GetSharedAccessSignature alongside the SharedAccessBlobPolicy, setting ContentDisposition to something like 'attachment; filename=invoice.pdf' and ContentType to 'application/pdf'. This lets a technically-named blob (e.g. a customer ID plus invoice ID) download with a human-readable filename. The storage account's DefaultServiceVersion must be set to 2013-08-15 or later via SetServiceProperties for this header feature to work.

_Developers building secure file downloads on Azure can keep SAS techniques like this handy via daily.dev._

### How can I let users download a file directly from Azure Blob Storage without routing the bytes through my web server?

Generate a Shared Access Signature (SAS) on the blob granting temporary read permission, then redirect the user's request to the signed blob URL instead of streaming the file through the web application. An ASP.NET MVC action can authenticate the user, run business logic like tracking download counts, build the SAS-signed URL, and issue an HTTP redirect, letting blob storage handle the actual network I/O.

_Anyone offloading downloads to cloud storage can revisit SAS and redirect patterns like this through daily.dev._

## Similar posts on daily.dev

- [Holiday Hack 2025: Blob Storage Challenge in the Neighborhood](https://daily.dev/posts/holiday-hack-2025-blob-storage-challenge-in-the-neighborhood-5g5cxjw5f) · 0xdf hacks stuff · 0 upvotes · 0 comments
- [Azure Blob Storage Misconfigurations: Attacker’s Gateway to Data](https://daily.dev/posts/azure-blob-storage-misconfigurations-attacker-s-gateway-to-data-fpe7a3uix) · InfoSec Write-ups · 0 upvotes · 0 comments
- [Faster blob copying in Azure Blob Storage](https://daily.dev/posts/faster-blob-copying-in-azure-blob-storage-iv8ss6p2m) · Mark Heath · 0 upvotes · 0 comments
- [Unlock insights about your data using Azure Storage Discovery](https://daily.dev/posts/unlock-insights-about-your-data-using-azure-storage-discovery-yc7hlueum) · Microsoft Azure · 0 upvotes · 0 comments
- [Holiday Hack 2025: Spare Key](https://daily.dev/posts/holiday-hack-2025-spare-key-kqsy1tzkh) · 0xdf hacks stuff · 0 upvotes · 0 comments

---

Tags: [#cloud](https://daily.dev/tags/cloud), [#azure](https://daily.dev/tags/azure), [#c#](https://daily.dev/tags/c#)

[View this post on daily.dev](https://daily.dev/posts/windows-azure-storage-magic-with-shared-access-signatures-bbc1g5brb)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Windows Azure Storage magic with Shared Access Signatures","url":"https://daily.dev/posts/windows-azure-storage-magic-with-shared-access-signatures-bbc1g5brb","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/windows-azure-storage-magic-with-shared-access-signatures-bbc1g5brb"},"datePublished":"2026-10-04T13:04:10.854Z","dateModified":"2026-10-04T13:05:41.969Z","description":"A walkthrough of Windows Azure Blob Storage Shared Access Signatures (SAS), showing how to grant temporary read access to a blob, how to combine SAS with an...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/71b0597fdb1db5537b1cea418b58d46a?_a=AQAEuop","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/71b0597fdb1db5537b1cea418b58d46a?_a=AQAEuop","isAccessibleForFree":true,"articleSection":"Maarten Balliauw","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Maarten Balliauw","logo":"https://media.daily.dev/image/upload/s--rOTg3VYO--/f_auto,q_auto/v1791119043/logos/maartenballiauw?_a=BAMAMicg0","url":"https://daily.dev/sources/maartenballiauw"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/windows-azure-storage-magic-with-shared-access-signatures-bbc1g5brb","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":0},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"cloud,azure,c#","timeRequired":"PT5M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Maarten Balliauw","item":"https://daily.dev/sources/maartenballiauw"},{"@type":"ListItem","position":3,"name":"Windows Azure Storage magic with Shared Access Signatures"}]}
{"@context":"https://schema.org","@type":"FAQPage","@id":"https://daily.dev/posts/windows-azure-storage-magic-with-shared-access-signatures-bbc1g5brb#faq","mainEntity":[{"@type":"Question","name":"How do I set a custom filename and content type for a blob download using Azure Shared Access Signatures?","acceptedAnswer":{"@type":"Answer","text":"Pass a SharedAccessBlobHeaders object to GetSharedAccessSignature alongside the SharedAccessBlobPolicy, setting ContentDisposition to something like 'attachment; filename=invoice.pdf' and ContentType to 'application/pdf'. This lets a technically-named blob (e.g. a customer ID plus invoice ID) download with a human-readable filename. The storage account's DefaultServiceVersion must be set to 2013-08-15 or later via SetServiceProperties for this header feature to work. Developers building secure file downloads on Azure can keep SAS techniques like this handy via daily.dev."}},{"@type":"Question","name":"How can I let users download a file directly from Azure Blob Storage without routing the bytes through my web server?","acceptedAnswer":{"@type":"Answer","text":"Generate a Shared Access Signature (SAS) on the blob granting temporary read permission, then redirect the user's request to the signed blob URL instead of streaming the file through the web application. An ASP.NET MVC action can authenticate the user, run business logic like tracking download counts, build the SAS-signed URL, and issue an HTTP redirect, letting blob storage handle the actual network I/O. Anyone offloading downloads to cloud storage can revisit SAS and redirect patterns like this through daily.dev."}}]}
```

