🛡️ Sentinel: [MEDIUM] Fix missing input validation in exported functions - #117
🛡️ Sentinel: [MEDIUM] Fix missing input validation in exported functions#117seonghobae wants to merge 3 commits into
Conversation
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
|
Warning Review limit reachedNext included review available in 36 minutes. View limit detailsLimit details: You’ve used the included review currently available. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Review configuration: ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Team Run ID: 📒 Files selected for processing (3)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
| if (!is.logical(nested) || length(nested) != 1 || is.na(nested)) { | ||
| stop("The 'nested' argument must be a single logical value (TRUE or FALSE).", call. = FALSE) | ||
| } | ||
| if (!is.character(adj) || length(adj) != 1 || is.na(adj) || !(adj %in% c("none", "aic", "bic"))) { | ||
| stop("The 'adj' argument must be a single character string: 'none', 'aic', or 'bic'.", call. = FALSE) |
| if (!is.numeric(conf.level) || length(conf.level) != 1 || is.na(conf.level) || conf.level <= 0 || conf.level >= 1) { | ||
| stop("The 'conf.level' argument must be a single numeric value strictly between 0 and 1.", call. = FALSE) |
|
Fresh successor verification: PR #122 at exact head |
Understood. Acknowledging that this work is now obsolete and superseded by PR #122, and stopping work on this task. |
🚨 Severity: MEDIUM
💡 Vulnerability: Missing type, length, and bound validations on arguments passed to exported functions (
vuongtestandicci).🎯 Impact: Malformed inputs (like
NAor vectors of length > 1) could bypass secure boundaries and trigger raw internal R errors (e.g., "missing value where TRUE/FALSE needed" insideifstatements), leaking internal execution contexts and stack traces to end users.🔧 Fix: Added strict type, length,
is.na(), and bound validations for thenested,adj, andconf.levelarguments at the beginning of the exported functions to fail securely withcall. = FALSE.✅ Verification: Verified locally that passing malformed inputs now gracefully throws a generalized error without leaking the stack trace. All tests pass successfully.
PR created automatically by Jules for task 2887817721635511304 started by @seonghobae