Online sample player always returns forbidden

ajsela maslak 0 Reputation points

When trying to play any of the files from:

The player always returns forbidden. Screenshot from 2023-11-28 13-09-27.png

Azure Media Services
Azure Media Services
A group of Azure services that includes encoding, format conversion, on-demand streaming, content protection, and live streaming services.
314 questions
{count} votes

1 answer

Sort by: Most helpful
  1. brtrach-MSFT 15,791 Reputation points Microsoft Employee

    @ajsela maslak It seems that you are having trouble playing the files from the Azure Media Player samples. The error message you shared indicates that the issue might be related to the CORS policy. This error occurs when the server hosting the content does not allow cross-origin requests from your domain.

    To resolve this issue, you can try adding the following code to your server's response headers:

    Access-Control-Allow-Origin: *

    If you do not have access to the server hosting the content, you can try using a proxy server to bypass the CORS policy.

    0 comments No comments