Table of contents of this page:

Welcome to Viblast Documentation

Everything you need to know about Viblast Solutions. For more information contact us.

Viblast Documentation

How to enable CORS on Wowza Streaming Engine

Open [wowza-install-dir]/conf/[application]/Application.xml with your favorite text editor, find the xml tag called HTTPStreamer and set the value of the cupertinoUserHTTPHeaders property to

Access-Control-Allow-Origin: *

The whole block should look like this:

<HTTPStreamer>
       <!-- Properties defined here will override any properties defined 
            in conf/HTTPStreamers.xml for any HTTPStreamer loaded by this 
            application -->
      <Properties>
              <Property>
                     <Name>cupertinoUserHTTPHeaders</Name>
                     <Value>Access-Control-Allow-Origin: *</Value>
              </Property>
       </Properties>
</HTTPStreamer>

If there is no HTTPStreamer xml tag in your Application.xml file, you should manually add the above snippet to the file.

If you want to restrict XHR requests only to your website, you can set the value of Access-Control-Allow-Origin to your domain name. For example:

Access-Control-Allow-Origin: http://www.domain.com

After editing Application.xml, you should restart you Wowza app.

To validate that the headers are set appropriately, you can run:

curl -I [http-end-point]

The result should contain the following line:

...
Access-Control-Allow-Origin: *
...