# Receiving error when using serviceCert to include out-of-band Widevine certificate

**URL:** <https://forum.developer.roku.com/t/receiving-error-when-using-servicecert-to-include-out-of-band-widevine-certificate/11608>\
**Category:** Roku Developer Program\
**Created:** [September 28, 2026, 7:56pm UTC](https://forum.developer.roku.com/t/receiving-error-when-using-servicecert-to-include-out-of-band-widevine-certificate/11608 "2026-09-28T19:56:41Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![nthingvall](https://sea3.discourse-cdn.com/roku/user_avatar/forum.developer.roku.com/nthingvall/32/114_2.png) [@nthingvall](https://forum.developer.roku.com/u/nthingvall)\
**Post date:** [September 28, 2026, 7:56pm UTC](https://forum.developer.roku.com/t/receiving-error-when-using-servicecert-to-include-out-of-band-widevine-certificate/11608/1 "2026-09-28T19:56:41Z")

</div>

Hi, all! I am trying to use the `serviceCert` property of the Content Node to include a DRM certificate for an asset. Other platforms can use this certificate, but on Roku, I get

```auto
{
  "error": "Protected content license error.",
  "errorObject": {
    "code": -6,
    "message": "buffer:loop:unset:DRM exception: DRM exception: setDrmParams: [sess.decrsamp] setServiceCertificate() failed : 1(Cdm::kTypeError):extra:content_id:2:err_clip_idx:0:etype:buffer:num_keys:0:num_lic:1:program_id:"
  }
}

```

I’ve tried base-64 encoded, non-base-64 encoded, and wrapped versions of the cert string and always receive the same error. Is something extra needed to implement the out-of-band certificate?

---

<div class="post-metadata">

**Author:** ![nthingvall](https://sea3.discourse-cdn.com/roku/user_avatar/forum.developer.roku.com/nthingvall/32/114_2.png) [@nthingvall](https://forum.developer.roku.com/u/nthingvall)\
**Post date:** [September 29, 2026, 2:50pm UTC](https://forum.developer.roku.com/t/receiving-error-when-using-servicecert-to-include-out-of-band-widevine-certificate/11608/2 "2026-09-29T14:50:07Z")

</div>

Looks like it needed to be converted from base 64 to hex encoding. This is despite google results insisting that it needs to be base 64 encoded, when the docs don’t say that. Of course, the docs don’t say _which_ encoding to use either.

```auto
bytes = createObject("roByteArray")
bytes.fromBase64String(certificate)
contentNode.drmParams.serviceCert = bytes.toHexString()

```
