How to generate custom license for widevine DRM

2.5k Views Asked by At

I have been researching about DRM video encryption. All the example in internet I find it needs a lincense link, and a "X-AxDRM-Message" encrypted message as header request. But when I generate widevine encrypted video files with bento4, it don't provide me any sourse to generate the lincese link, it provides me KID and Key. What should I do with these two things? can I create the license link with php or python or js? or how can I get the link for free?

1

There are 1 best solutions below

2
Mick On

You need to either host the DRM service yourself or else use a DRM, or more likely, multi DRM, online service.

This will provide you with the keys, IV etc you need to encrypt and also with the license server URL that your clients need to call to request the license playback key.

Note that for some DRM schemes, PlayReady and FairPlay, the license server URL can be included in the video stream, but for Widevine it usually needs to be configured on the client separately.

Its useful to test online first if possible - there are multiple player sites that will allow you test DRM protected streams, including the open source Shaka Player demo: