Issue on IFrame Embed

Hello experts, I’m trying to implement Kaltura with this approach on my page:
https://developer.kaltura.com/player/web/embed-types-web#iframe-embed
This is the error that I’m getting:

The video is on a secure channel but I don’t think the problem is related with the token because the same image says that the “ks” has no errors.
Any ideas how I can fix it?

Hello,

Please provide your full embed code (without the actual KS, of course) so we can assist you further.

Cheers,

This is my code:

            <div slot="media-content">
              <iframe type="text/javascript"
                src='https://cdnapisec.kaltura.com/p/3222463/embedPlaykitJs/uiconf_id/47425753?iframeembed=true&entry_id=1_cl5ysiax&config[playback]={"autoplay":true}'
                style="width: 640px;height: 360px" allowfullscreen webkitallowfullscreen mozAllowFullScreen
                frameborder="0">
              </iframe>
            </div>

Hi,

If you check the outgoing HTTP requests when requesting https://www.kaltura.com/index.php/extwidget/preview/partner_id/3222463/uiconf_id/47234743/entry_id/1_cl5ysiax/embed/iframe (you can do that using your browser’s dev tools), you’ll see a https://cdnapisec.kaltura.com/api_v3/service/multirequest request that returns:

message":“No KS where KS is required\nWe’re sorry, access to this content is restricted.”,“code”:“SESSION_RESTRICTED”,“objectType”:“KalturaAccessControlMessage”}],“objectType”:“KalturaPlaybackContext”},{“objects”:[],“totalCount”:0,“objectType”:“KalturaMetadataListResponse”}]

That is because your default access control profile is configured to require a KS.
You can see that by making an accessControlProfile.get() request or from KMC, where, for the default access control profile, Advanced Security and Pay per-view Secure this video with server side secret. is checked.

You can also easily see the message when making a playManifest request:

curl ‘https://cdnapisec.kaltura.com/p/3222463/sp/322246300/playManifest/entryId/1_cl5ysiax/protocol/https/format/applehttp/flavorIds/1_r8sld2i3,1_3olze28d,1_t7md6le8,1_verb1z6x,1_3ip1ifg6’ -v

Which returns with:

< x-kaltura-app: exiting on error 3 - entry restricted due to access-control

Bottom line: you’ve got the following options:

  • Pass a valid KS in the embed code
  • Set a different access control profile for this particular entry
  • Change your default access control profile configuration so that it does not require a KS (will of course affect all entries using this profile)

Another thing to note is that in the URL you’re posted (src of the iframe tag), you are using UI conf ID 47425753, which does not belong to partner ID 3222463
I cannot post a valid KS here as this is a public forum but if you replace KS_HERE in the below with a valid KS, it will play:

<iframe type="text/javascript" src="https://cdnapisec.kaltura.com/p/3222463/embedPlaykitJs/uiconf_id/47234743?iframeembed=true&amp;entry_id=1_cl5ysiax&amp;config[provider]={&quot;ks&quot;:&quot;KS_HERE&quot;}&amp;config[plugins]={&quot;kava&quot;:{&quot;disable&quot;:true}}" style="width: 560px; height: 395px" allowfullscreen="" webkitallowfullscreen="" mozallowfullscreen="" allow="autoplay *; fullscreen *; encrypted-media *" frameborder="0"></iframe>
1 Like

Thanks! Aparrently it worked

Regarding the issue with the partnerID and UIconfigID, these data is what the api is returning. Is there any special configuration that I need to add?

Hello @armin ,

Not sure which API you are referring to?
In order to obtain the player UI conf IDs for a given partner, you can use the uiconf.list() action, passing a KalturaUiConfFilter object with the below members set to these values:

tagsMultiLikeAnd: kalturaPlayerJs
objTypeIn:1,8