Downloads · 30 days
0
ybgwon96/darknet-cfg-layerindex-oob-poc
darknet-cfg-layerindex-oob-poc is a machine learning model from ybgwon96. Use it for the machine learning task on the model card, and read the license before you ship it in a product. The card lists the license as mit.
huntr MFV PoC vs hank-ai/darknet src-lib/darknetcfg.cpp. Authorized security research (responsible disclosure via huntr).
Downloads · 30 days
0
Access
Public
Updated Jul 4, 2026
Repo size
—
Likes
0
Public
Click a slice to open those files.
.md2.8 KB · 46%
From the Hugging Face model README
net.layers[] accesshuntr MFV PoC vs hank-ai/darknet src-lib/darknet_cfg.cpp.
Authorized security research (responsible disclosure via huntr).
parse_shortcut_section (darknet_cfg.cpp:1773-1783) uses the .cfg from= index to subscript
net.layers[] with no bounds check; parse_route_section (:1534-1548) checks only the upper bound
(route_index >= parms.index), omitting the lower bound, so negative indices pass. A malicious .cfg
(loaded alongside .weights) with from=2000000000 (or a large negative) causes a wild OOB access of
net.layers[index] at load — SIGSEGV, plus propagation of wild .output/.delta pointers into the
shortcut layer's forward pass.
poc_shortcut_oob.cfg — malicious Darknet config ([shortcut] from=2000000000).layerindex_repro.c / CRASH_PROVEN.md — isolated repro; EXC_BAD_ACCESS at net.layers[index].cc -O0 -g layerindex_repro.c -o layerindex_repro && ./layerindex_repro 2000000000 # -> SIGSEGV
# end-to-end: load poc_shortcut_oob.cfg with darknet -> crash in parse_shortcut_section.
Bound-check index/route_index to [0, net.n) (or [0, parms.index)) in parse_shortcut_section and
add the missing route_index < 0 check in parse_route_section.