Topics for DRM / KMS Integration 1970-01-01T00:00:00Z 1 1 0 0 0 1 6994931 How To - Multiscreen Key Management Server (KMS) Interface 2016-05-02T23:39:28Z 2016-05-02T23:39:28Z Ofer Aharon ofer_aharon <b>Introduction</b> <em>Harmonic KMS interface is a XML/SOAP-based interface designed to facilitate encryption key and DRM metadata exchange between an OTT packager/scrambler and Key Management Server.&nbsp;</em><br /><br /> <em><br /></em><br /><br /> <em>This page is meant to describe the general process for DRM partners wishing to integrate VOS 360 and VOS Cloud via Harmonic KMS interface, providing key consideration topics, troubleshooting tips, and links to relevant specifications<br /></em><br /><br /> <em><br />This page is NOT meant to define any specifications, please refer to the References section for links to API specification documents.</em><br /><br /> <br /><br /> <b>Applications</b><br /><br /><em>The interface is applicable for the following ABR formats and encryption types:</em><br /><img /><img /><img src="" title="Image https//d2r1vs3d9006apcloudfrontnet/s3_images/1409233/30744-1ao48ro_inlinepng1462232678" /><img /><br /><em>As seen in the table, different formats/encryption methods may require different KMS API methods. Within specific API methods, there may also be format-specific signalization structures to provide the necessary metadata required for each format.</em> <em>*key rotation not supported due to format-specific limitation</em><br /><br /> <em><b><br />Special notes for Apple HLS/FairPlay DRM</b></em><br /><br /><em>Some custom attributes are mandatory in the GetKeyAndSignalization response when using Apple FairPlay DRM. See example in Sample Exchange section below.</em> &nbsp;&nbsp;<u>KEYFORMAT</u><br /><br /> &nbsp; &nbsp;This attribute is mandatory and shall be “”.<br /><br /> &nbsp; &nbsp;<u>KEYFORMATVERSIONS</u><br /><br /> &nbsp; &nbsp;This attribute is mandatory and shall be “1”.<br /><br /> &nbsp; &nbsp;<u>URI</u><br /><br /> &nbsp; &nbsp;This attribute is mandatory.<br /><br /> <em><b>Special notes for Smooth Streaming/PlayReady DRM with key rotation</b></em><br /><br /><em><em>In Smooth Streaming encryption, the manifestHeader represents the ProtectionSystem header included in the Smooth Streaming manifest. It is mandatory for KMS to provide this in the GetKeyAndSignalization response.</em></em><br /><br /><br /><b>Implementation Best Practices/Guidelines</b><br /><br /><ol><li>For encryption methods utilizing more than one API method, KMS must not assume a fixed ordering in which calls are made. For example, GetKey and GetClientParameters can be called in either order.</li><li>When multiple formats/encryption methods are required for a single service, it may be desirable to include a suffix on the ResourceID to differentiate between key requests for different formats which may have different response fields. For example, since both HLS/AES and SS/PlayReady share the same GetKey method, appending a suffix of "_HLS" or "_SS" to a common ResourceID base string would remove any ambiguity for KMS to return the corresponding DRM data for either formats.</li><li>The original KMS API specifications document describes a Full and Minimum Implementation - we recommend the Minimum Implementation. While the Full Implementation provides the benefit of an additional Key Session layer for redundancy and horizontal scaling, there may already be pre-existing redundancy/scaling methods within the DRM implementation such that the simplicity of the Minimum Implementation makes it an overall better approach.</li><li> element returned in GetClientParameters and GetKeyAndSignalization responses must be in big endian UUID format.</li></ol><br /><b>General Integration Process</b><ol></ol><ol><li>DRM partner on-boarding<ol><li>(Harmonic) Provide KMS API documents</li><li>(Harmonic) Provide VOS 360 testing environment access</li></ol></li><li>(Joint) Discussions and Q&amp;A session with partner for interface clarifications</li><li>(Partner) Self-service testing against provided VOS 360 testing environment. Once deemed acceptable, proceed to step 4.</li><li>(Partner) Provide internet-accessible KMS Server URL, version tracking, list of authorized ResourceID's and RequestorID's, Signer(if applicable). If possible, also share any special clients that may be required to playback the encrypted content.</li><li>(Harmonic) Perform sanity check with provided URL and ID's, record integration status with partner code versions documented. If client is available, attempt playback of encrypted streams.</li></ol><br /><b>Expected System Behavior</b><ul></ul><ul><li>Upon service provisioning, VOS 360 will generate KMS key requests to DRM partner-provided KMS endpoint to retrieve encryption keys. Upon success key retrieval, the encrypted content is produced and published to the Destination server.</li><li>DRM partner should visually verify and/or provide clients to verify the encrypted content for successful playback.</li><li>VOS 360 should provide useful alarms/notifications upon encountering key retrieval failure to ease troubleshooting.</li></ul><br /><b>Sample Exchange</b><br /><br />HLS/Native AES<br /><img src="" title="Image https//d2r1vs3d9006apcloudfrontnet/s3_images/1409236/327-702te2_inlinepng1462232985" /><br /><br /><br />HLS/Apple FairPlay<br /><img src="" title="Image https//d2r1vs3d9006apcloudfrontnet/s3_images/1409237/30744-3ronjk_inlinepng1462233048" /><br /><br /><br />DASH/Common Encryption(PlayReady + Widevine)<br /><img src="" title="Image https//d2r1vs3d9006apcloudfrontnet/s3_images/1409238/30744-14n7hlz_inlinepng1462233096" /><br /><br /><br />Smooth Streaming/PlayReady (No key rotation)<br /><br /><img src="" title="Image https//d2r1vs3d9006apcloudfrontnet/s3_images/1409239/327-1gzlhzw_inlinepng1462233150" /><br /><br />Smooth Streaming/PlayReady (Key rotation)<br /><img src="" title="Image https//d2r1vs3d9006apcloudfrontnet/s3_images/1409240/30742-1ivm0ly_inlinepng1462233261" /><br /><br /><br />FAQ Frequently Asked Questions<br /><br />Q. What port number should the KMS service run on? A. VOS 360 does not require the KMS service to run on a specific port number, though KMS vendor should ensure necessary firewall rules are configured to allow VOS 360 to reach the KMS endpoint.<br /><br /> &nbsp;<br /><br /> Q. Does VOS 360 support HTTPS/SSL?<br /><br /> A. Yes! Use of HTTPS is recommended for security reasons to mitigate risks of Man-in-the-middle(MITM) attacks. However, during initial integrations/development phase, it may be desirable to make available a HTTP endpoint to allow network capturing to identify possible problems in the KMS communications.<br /><br /> &nbsp;<br /><br /> Q. Is it required for unique ResourceID between services?<br /><br /> A. It is not a strict requirement in VOS 360 to have unique ResourceIDs, but in order to have different keys for each service, unique ResourceIDs are recommended per service.<br /><br /> &nbsp;<br /><br /> Q. Is it required for unique ResourceID between different package formats/encryption methods within the SAME service?<br /><br /> A. As different formats may have some format-specific requirements, having unique ResourceIDs or appending a suffix to the end of a common ResourceID would help KMS differentiate between multiple package formats and return the relevant DRM metadata for each. For example:<br /><br /> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Harmonic_HLS<br /><br /> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Harmonic_SSKR<br /><br /> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Harmonic_DASH<br /><br /> &nbsp;<br /><br /> Q. In a key rotation scenario, how often does VOS 360 make key requests to the KMS endpoint?<br /><br /> A. The key rotation interval configuration determines the frequency of making key requests. Currently, VOS 360 does not yet support multiple keys per request(although the multiple ScheduledKey structure is defined in the KMS spec, it is for future consideration only).<br /><br /> &nbsp;<br /><br /> Q. For key rotation, how does VOS 360 identify the key being requested for a given time window?<br /><br /> A. Within the GetKey or GetKeyAndSignalization methods, there is a parameter which denotes the time period for which the key is being requested. For live streams, the time is the POSIX time in seconds.(IEEE Std 1003 Committee, 2008).<br /><br /> &nbsp;<br /><br /> Q. Is it expected for KMS vendor to provide a single shared KMS endpoint for multiple VOS 360 customers? Or a single endpoint per customer?<br /><br /> A. VOS 360 does not have restrictions on KMS endpoints sharing, though for manageability and tracking purposes, it may be desirable to segregate endpoints on a per customer basis. question complete 0 1 1 create encryption, fairplay, integration, kms, key managment, playready, widevine