Skip to content

Instantly share code, notes, and snippets.

@sedouard
sedouard / SAStoken.cs
Created July 10, 2015 02:15
Generates a SAS Token for Azure REST Api Calls (Particularly for Service Bus Services like Event Hub & Queues)
/// <summary>
/// Code for generating of SAS token for authorization with Service Bus
///
/// This handy function can be found on this helpful blog post:
/// http://developers.de/blogs/damir_dobric/archive/2013/10/17/how-to-create-shared-access-signature-for-service-bus.aspx
/// </summary>
/// <param name="resourceUri"></param>
/// <param name="keyName"></param>
/// <param name="key"></param>
/// <returns></returns>