Skip to content

[6.32] [r] Sanitize R package and repo names in TRInterface helpers#22204

Merged
guitargeek merged 1 commit into
root-project:v6-32-00-patchesfrom
root-project-bot:BP_6.32_pull_22181
May 9, 2026
Merged

[6.32] [r] Sanitize R package and repo names in TRInterface helpers#22204
guitargeek merged 1 commit into
root-project:v6-32-00-patchesfrom
root-project-bot:BP_6.32_pull_22181

Conversation

@root-project-bot
Copy link
Copy Markdown

Backport of #22181, requested by @guitargeek.

`TRInterface::IsInstalled`, `::Require`, and `::Install` built R source by
concatenating the caller-provided package name into a string literal and
passing it to the embedded R interpreter.

Validate pkg against CRAN's package-name rule (starts with an ASCII
letter, only letters, digits, and dots, does not end in a dot) before
putting it into the R command, and emit an Error and return `kFALSE` on
any other input.

The `repos` argument of Install is validated to be a valid URL.

(cherry picked from commit 12173d5)
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 9, 2026

Test Results

     6 files       6 suites   19h 42m 31s ⏱️
 2 562 tests  2 561 ✅ 0 💤 1 ❌
14 957 runs  14 956 ✅ 0 💤 1 ❌

For more details on these failures, see this check.

Results for commit a18f313.

@guitargeek guitargeek merged commit a735d93 into root-project:v6-32-00-patches May 9, 2026
7 of 9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants