New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

pssh-tools

Package Overview
Dependencies
Maintainers
1
Versions
42
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pssh-tools - npm Package Compare versions

Comparing version 1.0.5 to 1.0.6

18

dist/src/lib/pssh/playready.js

@@ -67,2 +67,5 @@ "use strict";

}
xmlArray.push('<CUSTOMATTRIBUTES>');
xmlArray.push('<IIS_DRM_VERSION>8.0.1906.32</IIS_DRM_VERSION>');
xmlArray.push('</CUSTOMATTRIBUTES>');
xmlArray.push('</DATA>');

@@ -72,4 +75,4 @@ xmlArray.push('</WRMHEADER>');

};
const constructProXML = (keyIds, licenseUrl, keySeed) => {
let contentKeys = keyIds.map((k) => {
const constructProXML = (keyPairs, licenseUrl, keySeed) => {
let keyIds = keyPairs.map((k) => {
return keySeed && keySeed.length ? generateContentKey(k.kid, keySeed) : exports.encodeKey(k);

@@ -82,3 +85,3 @@ });

// Construct Key
contentKeys.forEach((key) => {
keyIds.forEach((key) => {
xmlArray.push(`<KID ALGID="AESCTR" CHECKSUM="${key.checksum}" VALUE="${key.kid}">`);

@@ -92,6 +95,6 @@ xmlArray.push('</KID>');

xmlArray.push(`${licenseUrl}?cfg=`);
for (let i = 0; i < contentKeys.length; i++) {
for (let i = 0; i < keyIds.length; i++) {
// TODO: Options to pass predefined contentkey
xmlArray.push(`(kid:${contentKeys[i].kid})`);
if (i < keyIds.length - 1) {
xmlArray.push(`(kid:${keyIds[i].kid})`);
if (i < keyPairs.length - 1) {
xmlArray.push(',');

@@ -102,2 +105,5 @@ }

}
xmlArray.push('<CUSTOMATTRIBUTES>');
xmlArray.push('<IIS_DRM_VERSION>8.0.1906.32</IIS_DRM_VERSION>');
xmlArray.push('</CUSTOMATTRIBUTES>');
xmlArray.push('</DATA>');

@@ -104,0 +110,0 @@ xmlArray.push('</WRMHEADER>');

@@ -221,3 +221,3 @@ "use strict";

};
const decodePRData = (psshData, dataEncoding = 'utf8') => {
const decodePRData = (psshData) => {
// pro header

@@ -235,3 +235,3 @@ let proHeader = Buffer.alloc(10);

recordType: proRecordType,
recordXml: proData.toString(dataEncoding)
recordXml: proData.toString('utf16le')
};

@@ -238,0 +238,0 @@ };

{
"name": "pssh-tools",
"version": "1.0.5",
"version": "1.0.6",
"description": "Tools to generate PSSH Data and PSSH Box",

@@ -11,3 +11,3 @@ "main": "dist/src/index.js",

"pretest": "tslint -p .",
"test": "tsc -p .&& cp -R ./src/lib/pssh/proto ./dist/src/lib/pssh/ && ava ./dist/test/*.js --verbose"
"test": "tsc -p . && cp -R ./src/lib/pssh/proto ./dist/src/lib/pssh/ && ava ./dist/test/*.js --verbose"
},

@@ -14,0 +14,0 @@ "keywords": [

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc