Using CORS in private buckets

Using CORS in private buckets

Because browsers are specifically mandated to strip user-headers from CORS requests, it is not possible to use the AUTHENTICATION header in download requests from private buckets when those requests come from a browser.

Use the alternative authentication method of appending the authentication string to the download URL. For example, to download the file helloworld.html from a public bucket publichello the url might be:

https://f000.backblaze2.com/files/publichello/helloworld.html

To download a similar file from a bucket privatehello might be:

https://f000.backblaze2.com/files/privatehello/helloworld.html?Authentication=3_20181021181348_1654aeb9046d1bcdd60dff3c_06314b74a8fc99f72def5a18c1b3c87ab35f329c_000_20181030221348_0000_dnld

Please note: Although web standards are to ignore case in the headers, URLS are case sensitive. Authentication must have the first letter capitalized, and the remainder in lower case.

Have more questions? Submit a request

1 Comments

  • 0
    Avatar
    gregfig

    This article was confusing until I found in the documentation that it should be

    ?Authorization=

    NOT

    ?Authentication=


    Hopefully I save someone some time looking through this not so organized documentation.

Please sign in to leave a comment.
Powered by Zendesk