test(desktop): net_guard grep-ban matches allow-list by full path + recursive src walk (LC-210-GREPBAN-FULLPATH) #289
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/lc-210-grepban-fullpath"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #285 (LC-210-GREPBAN-FULLPATH). Small fix-in-passing.
The desktop
net_guardureq grep-ban matched its allow-list by basename, diverging from the LC-152/204/206 bans, which match full relative paths specifically so a future same-basename file in a subdirectory cannot inherit the exemption. It was safe only becausedesktop/src/is flat. Compounding it, the walker used a non-recursiveread_dir, so a rawureqadded in any future subdir file would not have been scanned at all.Both holes closed:
src_files()now walkssrc/recursively.src/(forward-slash separated for cross-platform stability), so a hypotheticalsrc/foo/welcome.rsisfoo/welcome.rs(not exempt) and is scanned.BAN_ALLOWED(net_guard.rs,welcome.rs) is unchanged because both files sit at the src root, so today's coverage is identical - the change only removes the latent subdir hole and re-aligns all four grep-bans on one convention. The load-bearing meta-test resolvessrc_root().join(allowed), which handles a future subdir entry too.just test-desktop13/13;just checkclean (both server modes + desktop clippy-D warnings+ fmt). No[operator-action](test-infra hardening, no behavior change).🤖 Generated with Claude Code