locked
Silverlight Image binding to Azure blob cross scheme RRS feed

  • Question

  • I am attempting to binding the Source of an Image to a URL that resides in an Azure blob.

    The silverlight site is running on HTTPS, and the URL of the image in Azure storage is HTTP.  I think this is why it's not working.

    Is there anyway to solve this?  Can I put a ClientAccessPolicy in Azure storage to fix this?  If so, can someone provide a sample ClientAccessPolicy xml?

    Or alternatively, is there a way to access the Azure storage through HTTPS so that it is on the same scheme as the Silverlight app?

    Tuesday, March 1, 2011 12:28 PM

Answers

  • I've successfully accessed blobs from a Silverlight client that is hosted in a web role and accessed over ssl so I know it's possible.  Steve Marx has a good post on what the file should look like. 

    Two things to look out for are:

    1. You can't define root containers in the dev fabric so this only works against production blob storage.
    2. You need to make sure permissions are open on the container / files or alternatively use Shared Access Signatures.

    HTH,


    Harin
    • Proposed as answer by Harin Monday, March 7, 2011 12:36 AM
    • Marked as answer by Mog Liang Tuesday, March 22, 2011 7:00 AM
    Tuesday, March 1, 2011 11:45 PM

All replies

  • I've successfully accessed blobs from a Silverlight client that is hosted in a web role and accessed over ssl so I know it's possible.  Steve Marx has a good post on what the file should look like. 

    Two things to look out for are:

    1. You can't define root containers in the dev fabric so this only works against production blob storage.
    2. You need to make sure permissions are open on the container / files or alternatively use Shared Access Signatures.

    HTH,


    Harin
    • Proposed as answer by Harin Monday, March 7, 2011 12:36 AM
    • Marked as answer by Mog Liang Tuesday, March 22, 2011 7:00 AM
    Tuesday, March 1, 2011 11:45 PM
  • Hi Kevin,

    We have the same issue. Were you able to find any solution to it. In our case images are not on Azure, but they are available only over HTTP and our SilverLight site is on HTTPS

    -Abhinav

    Monday, July 4, 2011 11:22 AM
  • Hi,

    I'm having the same problem.
    Silverlight site is in HTTPS and images url in http in a different web site and images are not downloaed.

    This is my ClientAccessPolicy:

    <?xml version="1.0" encoding="utf-8" ?>
    <access-policy>
      <cross-domain-access>
        <policy>
          <allow-from http-request-headers="*">
            <domain uri="*"/>
          </allow-from>
          <grant-to>
            <resource path="/" include-subpaths="true"/>
          </grant-to>
        </policy>
      </cross-domain-access>
    </access-policy>


    Tuesday, May 8, 2012 9:46 AM
  • Hi - sorry we missed this, as it had already been marked as answer.  Did the solution proposed by Steve Marx on his blog work for you?

    -Jeff

    Monday, May 21, 2012 6:16 AM