fix(framework/tools): eval injection, broken JSON, and tmpfile leak in git wrappers #548
Reference in New Issue
Block a user
Delete Branch "%!s()"
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?
Three confirmed defects in packages/mosaic/framework/tools/git/:
F-01 (HIGH, shell injection) — issue-edit.sh and issue-assign.sh build commands via string interpolation then run eval. A title/body/label containing $(id) will execute arbitrary code.
F-07 (MED, broken JSON) — milestone-create.sh builds GitHub API JSON payload via string interpolation. A title containing a double-quote breaks the JSON, causing the API call to fail.
F-13 (LOW, tmpfile leak) — pr-metadata.sh creates a tmpfile via mktemp inside curl_gitea_pull() but only removes it in the success paths. A set -e early exit leaks the file.
Fix branch: fix/tooling-eval-injection-jq-json