Skip to content

pckg_m3u8_enc_key_uri returns enc.key #223

@samek

Description

@samek

Hi,

using the sample configuration provided for drm-fps key is set via pckg_m3u8_enc_key_uri

But when requesting the manifest it's not set.

Also one more question - in nginx-vod project there was vod_drm_upstream_location (for getting key info) - is there something similar in this one or we need to use Lua/xx to fill in the var $pckg_var_drm_cbcs_json in this case ?

location /drm-fps/ {
            set $pckg_var_drm_cbcs_json '{"key":"U2ESLm9KOuoHjb21F4b4mg==","key_id":"vZ23gB5+J6HZ+Q8C015uFA==","iv":"vZ23gB5+J6HZ+Q8C015uFA=="}';

            pckg;

            pckg_enc_scheme cbcs;
            pckg_enc_json $pckg_var_drm_cbcs_json;

            pckg_m3u8_enc_output_iv off;
            pckg_m3u8_enc_key_uri 'skd://channel-$channel_id';
            pckg_m3u8_enc_key_format 'com.apple.streamingkeydelivery';
            pckg_m3u8_enc_key_format_versions 1;
        }
curl 'http://localhost:8777/drm-fps/ch/ch1/index-ss1-v.m3u8'
#EXTM3U
#EXT-X-TARGETDURATION:6
#EXT-X-VERSION:9
#EXT-X-MEDIA-SEQUENCE:1747151187
#EXT-X-DISCONTINUITY-SEQUENCE:11
#EXT-X-INDEPENDENT-SEGMENTS
#EXT-X-ALLOW-CACHE:YES
#EXT-X-SERVER-CONTROL:CAN-BLOCK-RELOAD=YES,CAN-SKIP-UNTIL=36.000
#EXT-X-SKIP:SKIPPED-SEGMENTS=13
#EXT-X-KEY:METHOD=SAMPLE-AES,URI="enc.key",KEYFORMAT="com.apple.streamingkeydelivery",KEYFORMATVERSIONS="1"
#EXT-X-PROGRAM-DATE-TIME:2025-05-14T10:30:39.117+00:00
#EXTINF:6.000,
seg-1747151203-ss1-v.ts

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions