Problem
DONATION is read from config.json (rigforge.sh:107) and then sed'd into the XMRig source (donate.h, :235/:242) and --argjson'd into jq (:359) with no validation. A non-integer/garbage value breaks the build opaquely or risks injecting into source before compile. Other inputs (hostname) are also unvalidated.
Proposed
- Validate
DONATION is an integer within XMRig's allowed range (0–100) before patching/build; fail fast with a clear message.
- Sanity-check
P2POOL_NODE_HOSTNAME (non-empty, reasonable charset).
Acceptance
Problem
DONATIONis read fromconfig.json(rigforge.sh:107) and thensed'd into the XMRig source (donate.h,:235/:242) and--argjson'd intojq(:359) with no validation. A non-integer/garbage value breaks the build opaquely or risks injecting into source before compile. Other inputs (hostname) are also unvalidated.Proposed
DONATIONis an integer within XMRig's allowed range (0–100) before patching/build; fail fast with a clear message.P2POOL_NODE_HOSTNAME(non-empty, reasonable charset).Acceptance
DONATION/hostname is rejected with a clear error before any source patch or build.