The Middleware Authorization is a client authorization on the third-party service, known as Middleware.
To configure Middleware Authorization open Settings -> HTTP Auth. From there, select the desired "Backend Type" and enter the appropriate "Backend Address" based on the selected type.
In the Ministra / Stalker settings turn on option "Temporary URL - Flussonic support"
Backend Address for cloud platform:
For local platform will be address of your server.
In the portal settings open "Keys" menu and create a new key:
In portal channel settings:
If you need to implement custom authentication logic, you can create your own backend. Select "HTTP Request" in "Backend Type" and specify URL to your Middleware endpoint.
Astra sends an HTTP GET request to the Middleware endpoint, appending all query parameters from the original request, and session information in the HTTP headers:
X-Session-ID- unique session number
X-Channel-ID- unique channel identifier
X-Real-IP- client's IP address
X-Real-Path- client's request path
X-Real-UA- client's User-Agent
X-Real-Host- client's Host request
In a response backend may send next HTTP headers:
X-Session-Name- client login or any other name for session
X-Real-Path: /play/a001/index.m3u8and other headers depending of clients request
If backend is not available, then Astra allows access.
If you get access to the channel without authorization, probably your HTTP backend is unavailable. You can check it with
curl command. Open console on your server with Astra. And try to send request to the HTTP backend manually:
curl -v "https://auth.example.com/check"
Of course address should be same as in your settings.
If you see something like
Connection refused or connection is stuck without any response, then issue with access to the backend.