Foliovision › Forums › FV Player › Bug Reports › DRM encrypted hls video not playing
-
Good Day! We added DRM encryption to safeguard our videos from downloading it but the issue is when we input it in fv player, the video is not playing and will display an error ‘Video not properly encoded’.
The set-up was made by a contractual developers and they insisted that the set-up is working 4 other sites except ours and we need tor each out to you guys to help. Hope you helps us
Regards,
-
-
Hello Slogin,
Thanks for reaching out to us!
Please turn on our Admin Video checker and let us know what does it say or sent us a screenshot of the report.
Thanks,
JurajHLS Link:
https://id.cloudfront.net/1be….b1/hls/test2.m3u8
HLS Key: bcb5f….9095
DRM URL: https://site.com/?fv_player_hls_key=test2Static Key and URL properly set up in AWS Media Convert as shown in the screenshot attached.
Hello Slogin,
Is “1beb2ca1-8fce-4110-81ba-843c171a2eb1” name of your bucket?
If yes, in this case the DRM URL should be: https://everyerotube.com/?fv_player_hls_key=hls/test2
Thanks,
JurajHello Slogin,
that fv_player_hls_key has to be unique across your entire website (fvplayer shortcodes in post content and FV Player database). Otherwise you might be getting the incorrect decryption key – which is why Juraj is suggesting you to try something better than just “test2”.
In fasct it would be best to use 1beb2ca1-8fce-4110-81ba-843c171a2eb1/hls/test2 as I believe that first part is a result of using the AWS Video on Demand and it should be really unique for each video: https://aws.amazon.com/solutions/implementations/video-on-demand-on-aws/
Thanks,
MartinOur engineer did a new convert as instructed above but it still having the same issues.
Hello Slogin,
please try to open your browser developer console (here’s how https://kb.mailster.co/how-can-i-open-the-browsers-console/), then try to play that video again and see if any error appears on the console.
Also try to actually save the player and use it on some real post or page – will it play there?
We are also happy to help you troubleshoot the issue with your custom video encoding directly on your website if you purchase our Pro support: https://foliovision.com/pro-support
Otherwise we can keep sending over some troubleshooting steps.
Thanks,
MartinAs instructed, we put the video in page and tried to see if we will caught any errors from the console and we got an error (see attached file below).
Hello Slogin,
As you can see in the Error log, CORS headers are missing. Please follow our guide: How to enable CORS
Thanks,
JurajGood Day! We have added CORS configuration the same with the referred link but the video still don’t play.
We’re catching “Uncaught TypeError: Cannot read property ‘src’ of undefined” error now instead of the cors config error.
Hello Slogin,
that JavaScript error might be or might not be related to the playback issue you are having. Please post it again, but this time click that tiny triangular arrow on the first line of the error notice to reveal the full error trace. Best if you can do with SCRIPT_DEBUG set to true in wp-config.php – if you have a good enough understanding of PHP and file editing.
There is still a chance that the playback engine is getting invalid decryption key though. Remember that the fv_player_hls_key argument in the HLS license URL has to match the URL of the stream and it must be the only stream that is matched. Previously you used something that was way too general.
If you follow our guide you will see that it’s written in a way that avoids these mistakes. I’m sorry to see how much trouble you are running into, but it seems to me it’s mostly because you are working on your own video encryption workflow. So it might take couple more messages back and forth and some additional checks on your end before it all works.
Thanks,
MartinHello Slogin,
I think the Multisite is the key to the issue here. If your blog address is https://site.com/actor-a then you must not use https://site.com/?fv_player_hls_key=1beb2ca1-8fce-4110-81ba-843c171a2eb1/hls/test2 but https://site.com/actor-a/?fv_player_hls_key=1beb2ca1-8fce-4110-81ba-843c171a2eb1/hls/test2 – if the blog runs in a “actor-a” folder, it needs to be part of the DRM URL.
Thanks,
Martin