Skip to main content

Protect a Video

Extend your encoding job with DRM protection. The Encoding Service contacts the Key Service on your behalf to acquire encryption keys, so no key material is ever handled by your code.

tip

If you encode through the Video Service rather than the API, you do not need this page at all. Enable the DRM Service, switch on DRM Protection in your processing profile, and encode - see Protecting Videos in Mosaic.

1. Set up DRM for your environment

Enable the Mosaic DRM Service for your environment. That is all the setup you need; there is nothing else to configure to get started.

Then open the DRM Service station in the Management System, under Admin Settings, and copy the Key Service Management API URL. That is the only DRM value your job request needs.

2. Add DRM settings to your job request

Add the following to the ContentProcessing element:

{
"ContentProcessing": {
"DrmProtection": "Managed",
"DrmManagedV2": {
"ApiUrl": "<Key Service Management API URL>",
"MultiKey": false,
"Proxy": false
}
}
}

Submit the job with your Mosaic JWT, as described under How to authenticate a service account. The Encoding Service passes the token on to the Key Service, which resolves your DRM tenant and key seed from it. No management key, tenant ID, or key seed goes into the request, and no credentials protection is needed for DRM.

note

Addressing Axinom Key Service from outside a Mosaic environment, for example with a DRM configuration created in Axinom Portal, is still supported. See Using Managed Mode with Axinom DRM Credentials.

3. Run encoding and store the key ID

Submit the job as described in Encode a Video. The response will include a KeyId:

{
"JobId": "6a062671-596a-4f09-acfc-0ab800f9e3f1",
"ExternalId": "<job_reference_id>",
"ExternalType": "movie",
"KeyId": "5a601de9-6075-461b-955c-0a155b93b0d3"
}

Store this KeyId - the Axinom DRM License Service uses it to reconstruct the encryption key (KeySeed model).

4. Play the protected video

Play your protected video as described in Play an existing DRM-protected video, using your DASH manifest URL and the KeyId from above.

Take the License Service URLs for your player from the DRM Service station, as described under Service endpoints.

See also

Was this page helpful?