https://github.com/tomer8007/widevine-l3-decryptor
Raw File
Tip revision: a0b47ff81fedc51ef0652d1dacd96ed318ce7e63 authored by nyuszika7h on 27 October 2020, 22:09:21 UTC
Fix for pages that use iframes
Tip revision: a0b47ff
content_script.js
injectScripts();

async function injectScripts() 
{
    await injectScript('lib/pbf.3.0.5.min.js');
    await injectScript('lib/cryptojs-aes_0.2.0.min.js');
    await injectScript('protobuf-generated/license_protocol.proto.js');


    await injectScript('content_key_decryption.js');
    await injectScript('eme_interception.js');
}

function injectScript(scriptName) 
{
    return new Promise(function(resolve, reject) 
    {
        var s = document.createElement('script');
        s.src = chrome.extension.getURL(scriptName);
        s.onload = function() {
            this.parentNode.removeChild(this);
            resolve(true);
        };
        (document.head||document.documentElement).appendChild(s);
    });
}
back to top