Playing a DASH content using SetServerCertificate.

856 views
Skip to first unread message

Adrián Gómez Llorente

unread,
Oct 20, 2017, 4:51:53 AM10/20/17
to Shaka Player Users
Hi,

I'm trying to play a content from the demo page using the SetServerCertificate method to avoid certificate requests. This is the information I'm using:

1. Request the serverCertificate:

var http = new XMLHttpRequest();

http.open('POST', 'https://widevine-proxy.appspot.com/proxy', true);
http.responseType = 'arraybuffer';
http.onload = function() {
  var arrayBuffer = http.response;
  if (arrayBuffer) {
    cert = new Uint8Array(arrayBuffer);
  }
};

http.send(atob('CAQ='));

I have a question here:
  • Body send (CAQ=) in the request to the serverCertificate is always the same or it depends on the proxy/content?
2. Configure serverCertificate in shaka-player

player.configure({
  drm: {
    advanced: {
      'com.widevine.alpha': {
        serverCertificate: cert
      }
    }
  }
});

As you can see above I'm converting the arrayBuffer returned in the response to Uint8Array and this value is passed to the player as it is shown above.

Errors obtained

Results obtained are:
  • LicenseServer is returning a 200OK with a body including what it seems a proper certificate.
  • Player fails playback because SetServerCertificate method rejects with this error: "Rejected with system code (17)"
  • Shaka-player fails fails with a code 6004
SetServerCertificate error:

Shaka-player error:


Would it be possible to have an example of the whole flow to configure the shaka-player with a proper certificate for the content specified above or other?

Jacob Trimble

unread,
Oct 20, 2017, 12:54:01 PM10/20/17
to shaka-pla...@googlegroups.com
Unfortunately, (IIRC) there is no way to publically get the server certificate for Widevine.  You'll need to talk to Widevine support directly to get the certificate and host that file on your server.  It also depends on which license server you are using (not the proxy).  What you are doing will contain the server certificate, but it is a special request the CDM makes to get it.  You can't just pass the response to setServerCertifiacate since it is wrapped.

--
You received this message because you are subscribed to the Google Groups "Shaka Player Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to shaka-player-users+unsub...@googlegroups.com.
To post to this group, send email to shaka-player-users@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/shaka-player-users/be9a83ee-5f96-4558-8c9b-70c260831fb4%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages