-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SAS Storage Blob Connection string? #4923
Comments
Update: I was able to figure this out, I just didn't fully understand how all these pieces fit together, and the docs don't explain things very well. In case it helps anyone:
|
Thanks for the issue, @sarink. The storage-blob version 10 API that you've been using doesn't provide the support for passing the connection string directly. The new support for the SAS connection string has been added in the version 12.0.0-preview.2 - Link. npm link for 12.0.0-preview.2 version - https://www.npmjs.com/package/@azure/storage-blob/v/12.0.0-preview.2 Here's the sample that shows the usage - withConnString.ts |
@HarshaNalluru is 12.0.0-preview.2 production ready/stable? |
Also, it appears that my code still doesn't work for uploading an image. If you put the SAS Token in the query parameter like that, it looks like the I cannot figure out how to make browser uploads work with SAS. Is there an example anywhere? I got the idea that it might work from here:
|
@HarshaNalluru wow... v12 is like another complete rewrite? Looks like....
None of these exist anymore? I literally just moved from the "legacy SDK", am I already writing outdated code? |
Thanks for the questions, @sarink. Question 1
Is this with V10? Can you provide a little more info or code so that I can repro the issue on my end? Question 2
In case you are referring to V10, you can leverage For V12, you can refer to the 12.0.0 - storage-blob/samples. Question 3
You can refer to the release pages 12.0.0 preview 1 release and 12.0.0 preview 2 release or the CHANGELOG DOCUMENT to see all the API changes in version 12. V10 is the production-ready version. |
@HarshaNalluru the code is the same as above. SDK is v10.4. I've simplified a bit if this helps:
|
@sarink Your SAS is invalid. A valid SAS sample here: ?sv=2017-04-17&ss=bfqt&srt=sco&sp=rwdlacup&se=2019-09-18T05:33:48Z&st=2017-09-16T21:33:48Z&spr=https,http&sig=S4WFjjmiuWEJTPqhaKeCqU90HQWHKrIqXMiDxXgfK1g%3D |
Original issue was solved by parsing it out myself, and it looks like this is fixed in v12. Next problem was the |
Thanks for working with Microsoft on GitHub! Tell us how you feel about your experience using the reactions on this comment. |
How do you connect via a connection string with SAS? The current examples only show something like,
or
Where/how do you get a "url including SAS signature"?
And where does the SAS Token get used?
The text was updated successfully, but these errors were encountered: