npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

xgplayer-lexo-decrypt-wasm

v1.0.1

Published

LEXO MEDIA CORPORATION proprietary high-performance HLS decryption loader powered by Rust + WebAssembly

Downloads

262

Readme

xgplayer-lexo-decrypt-wasm

Lexo 公司专有高性能 HLS 解密加载器,基于 Rust + WebAssembly 技术构建,专为 hls.jsxgplayer 设计。

⚠️ 商业机密声明

本项目包含 LEXO MEDIA CORPORATION 的专有技术和商业机密。未经授权,严禁复制、分发或用于非 LEXO MEDIA CORPORATION 公司内部或授权合作伙伴项目。 严禁对本软件包进行反编译、逆向工程或尝试提取核心算法。

版权信息

Copyright (c) 2026 LEXO MEDIA CORPORATION. All Rights Reserved.

特性

  • 🚀 高性能:解密逻辑由 Rust 实现并编译为 WebAssembly,提供接近原生的执行速度。
  • 🔒 安全性:核心逻辑(MD5、AES-CBC)编译为二进制,相比明文 JavaScript 更难被逆向工程。
  • 📦 易于集成:作为 hls.js 加载器的直接替代品,开箱即用。
  • 🛠 零配置:WASM 文件已内联到包中,无需额外的构建配置或静态文件处理。

安装

npm install xgplayer-lexo-decrypt-wasm
# 或
pnpm add xgplayer-lexo-decrypt-wasm
# 或
yarn add xgplayer-lexo-decrypt-wasm

使用方法

配合 hls.js 使用

import Hls from 'hls.js';
import { createLexoHlsLoaderWasm } from 'xgplayer-lexo-decrypt-wasm';

if (Hls.isSupported()) {
  const hls = new Hls({
    loader: createLexoHlsLoaderWasm(),
    loaderConfig: {
      iv: 'your-16-byte-iv-string', // 必需参数:16字节的初始化向量
      onSuccess: (response, stats, context) => {
        // 解密成功回调
      },
      onError: (error, response) => {
        console.error('解密失败', error);
      }
    }
  });
  
  hls.loadSource('https://example.com/video.m3u8');
  hls.attachMedia(videoElement);
}

配合 xgplayer 使用

import Player from 'xgplayer';
import HlsJsPlugin from 'xgplayer-hls.js';
import { createLexoHlsLoaderWasm } from 'xgplayer-lexo-decrypt-wasm';

const player = new Player({
  id: 'mse',
  url: 'https://example.com/video.m3u8',
  plugins: [HlsJsPlugin],
  hlsJsPlugin: {
    hlsOpts: {
      loader: createLexoHlsLoaderWasm(),
      loaderConfig: {
        iv: 'your-16-byte-iv-string', // 必需参数
      }
    }
  }
});

预加载 WASM(可选)

为了提高首个视频分片的加载速度,你可以选择预加载 WASM 模块:

import { preloadWasm } from 'xgplayer-lexo-decrypt-wasm';

// 建议在应用启动早期调用
preloadWasm();

API

createLexoHlsLoaderWasm()

返回一个兼容 hls.js 的自定义 Loader 类。

preloadWasm()

异步初始化 WASM 模块。返回一个 Promise。

isWasmReady()

如果 WASM 模块已初始化完成,返回 true

许可证

UNLICENSED - 保留所有权利。

未经 Lexo Inc. 书面许可,不得以任何形式使用、复制、修改或分发本软件。