Upgrade React to v19.0.3 and react-on-rails-rsc to v19.0.4 (CVE-2025-55183, CVE-2025-55184, CVE-2025-67779)#2233
Conversation
WalkthroughThis PR addresses React Server Components security vulnerabilities (CVE-2025-55183, CVE-2025-55184, CVE-2025-67779) by updating React to v19.0.3 and react-on-rails-rsc to v19.0.4 across all package configurations. The changelog documents the fixes including cycle-detection and server reference masking, while dependency ranges are updated consistently. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes
Possibly related issues
Possibly related PRs
Suggested labels
Suggested reviewers
Poem
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
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 |
PR Review: Upgrade to [email protected]Summary AnalysisThis PR changes the 🚨 Critical Issues1. Misleading PR Title
2. Git Dependencies in ProductionUsing git dependencies ( Concerns:
When git dependencies are acceptable:
Questions to answer:
3. Peer Dependency Version MismatchThe diff shows the git version of
Current state in this repo:
Impact:
📋 Missing Checklist ItemsAccording to the PR template, you need to:
From CLAUDE.md:
This is definitely user-visible since it changes dependency resolution behavior. 🧪 Testing Requirements (from CLAUDE.md)Before merging, you MUST test: # 1. Test clean install (CRITICAL)
rm -rf node_modules pnpm-lock.yaml
pnpm install --frozen-lockfile
# 2. Test build scripts
pnpm run build
# 3. Test yalc publish (if this affects package distribution)
pnpm run yalc:publish
# 4. Run relevant test suites
cd react_on_rails_pro/spec/dummy
bundle exec rake run_rspec:dummyKey quote from CLAUDE.md:
🔍 Code QualityPositive:
Concerns:
🛡️ Security Considerations
💡 Recommendations
✅ Before Merging
Quote from CLAUDE.md:
Let me know if you need help with any of these items! 🚀 |
size-limit report 📦
|
Code ReviewThank you for this PR to upgrade React to 19.0.3! I've reviewed the changes and here's my comprehensive feedback: ✅ Strengths
|
This reverts commit 2eff9e6.
Pull Request Review: Upgrade to [email protected]📋 SummaryThis PR upgrades React and ReactDOM from various 19.0.x versions to 19.0.3/19.2.3 across the monorepo, and switches the Pro package's ✅ Code Quality & Best PracticesGood:
Issues:
🐛 Potential Bugs
🚀 Performance Considerations
🔒 Security ConcernsCRITICAL - Git Dependency Pinning:
🧪 Test CoverageMissing from PR:
CRITICAL - CI Failures: Multiple CI jobs are failing:
Per CLAUDE.md section "CRITICAL - LOCAL TESTING REQUIREMENTS":
Required actions before merge:
📝 Documentation & Process IssuesMissing required items per CLAUDE.md:
🎯 RecommendationsHigh Priority:
Medium Priority: Before Merge:
💡 Questions for Author
📚 References
Overall Assessment: The dependency upgrade is reasonable, but there are several issues that need addressing before merge:
Please address the high-priority items and ensure all CI passes before requesting re-review. |
Code Review: React 19.0.3 UpgradeThank you for working on this React upgrade! I've reviewed the changes and have several important concerns that need to be addressed before this can be merged.
|
Code Review - PR #2233: Upgrade to [email protected]✅ Positive Aspects
|
Code Review - React 19.0.3 Upgrade✅ Overall AssessmentThis PR upgrades React and React DOM from 19.0.0/19.0.1 to 19.0.3, along with the 📋 What Was ChangedDependency Updates:
Files Modified:
✅ Code Quality & Best PracticesStrengths:
|
…, CVE-2025-55184, CVE-2025-67779) - Upgraded React to v19.0.3 - Upgraded react-on-rails-rsc to v19.0.4 - Fixes source code exposure and DoS vulnerabilities in React Server Components - Addresses issue #2223
Code Review: Security Upgrade PRThank you for this important security update! This PR addresses three critical CVEs in React Server Components. Here's my detailed review: ✅ Strengths1. Comprehensive Security Fix
2. Excellent Documentation
3. Appropriate Peer Dependency Strategy
4. Lock File Updates
🔍 Observations & Questions1. Inconsistent Dev Dependencies (Minor)In "devDependencies": {
"react": "^19.0.3",
"react-dom": "^19.0.3",
"react-on-rails-rsc": "^19.0.4"
}But in react:
specifier: ^19.0.3
version: 19.2.0
react-dom:
specifier: ^19.0.3
version: 19.2.0([email protected])
react-on-rails-rsc:
specifier: ^19.0.4
version: 19.0.4([email protected]([email protected]))([email protected])([email protected])Question: Is this intentional? The caret ranges Recommendation: Document this in the PR description if intentional, or consider more restrictive ranges if you want to pin to specific minor versions. 2. Testing CoverageThe PR states:
Questions:
Suggestion: According to issue #2223, you should verify: # Check for security patches in compiled files
grep -r "cycleProtection" node_modules/react-server-dom-webpack/
grep -r "serverReferenceToString" node_modules/react-server-dom-webpack/If you've done this verification, it would be great to document it in the PR description. 3. CI Compatibility (Pre-check Recommendation)According to
Recommendation: Before merging, check if master is currently passing: gh run list --workflow="Integration Tests" --branch master --limit 5If there are any pre-existing failures, document them so they're not attributed to this PR. 🎯 Security AssessmentVulnerability Mitigation ✅
Attack Surface ReductionBefore: Vulnerable to:
After:
📋 Pre-Merge ChecklistBased on
🚀 RecommendationsBefore Merging:
✨ Overall AssessmentRating: ⭐⭐⭐⭐⭐ (5/5) This is an excellent security PR with:
The minor observations above are mostly about verification and documentation improvements, not actual issues with the code changes. Recommendation: Approve and merge after completing the pre-merge checklist above. Great work on addressing these critical security vulnerabilities! 🛡️ |
There was a problem hiding this comment.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (3)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yamlreact_on_rails/spec/dummy/pnpm-lock.yamlis excluded by!**/pnpm-lock.yamlreact_on_rails_pro/spec/dummy/pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (5)
CHANGELOG.md(1 hunks)package.json(1 hunks)packages/react-on-rails-pro/package.json(2 hunks)react_on_rails/spec/dummy/package.json(1 hunks)react_on_rails_pro/spec/dummy/package.json(1 hunks)
🧰 Additional context used
📓 Path-based instructions (5)
**/*.{js,jsx,ts,tsx,json,css,scss,md}
📄 CodeRabbit inference engine (CLAUDE.md)
Use Prettier as the sole authority for formatting non-Ruby files
Files:
react_on_rails/spec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonpackage.jsonCHANGELOG.mdreact_on_rails_pro/spec/dummy/package.json
package.json
📄 CodeRabbit inference engine (CLAUDE.md)
Use
pnpmas the JavaScript package manager, never usenpmoryarn
Files:
package.json
{package.json,Rakefile,**/webpack.config.js,config/**/*.js}
📄 CodeRabbit inference engine (CLAUDE.md)
Validate that no hardcoded paths need updating after resolving merge conflicts in build configuration files
Files:
package.json
CHANGELOG.md
📄 CodeRabbit inference engine (CLAUDE.md)
Update
/CHANGELOG.mdfor open-source features, bug fixes, breaking changes, and performance improvements
Files:
CHANGELOG.md
react_on_rails_pro/**/*.{js,ts,jsx,tsx,json,css,scss}
📄 CodeRabbit inference engine (CLAUDE.md)
The
react_on_rails_pro/directory has its own Prettier/ESLint configuration and will be linted separately in CI
Files:
react_on_rails_pro/spec/dummy/package.json
🧠 Learnings (16)
📓 Common learnings
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-12-16T03:39:07.970Z
Learning: Applies to lib/react_on_rails/**/*.rb : Validate RBS signatures with `bundle exec rake rbs:validate` and run Steep type checker with `bundle exec rake rbs:steep` for Ruby files
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1644
File: lib/react_on_rails/helper.rb:190-197
Timestamp: 2025-02-18T13:08:01.477Z
Learning: RSC support validation in React on Rails Pro is handled through a chain of validations:
1. Pro version check in `run_stream_inside_fiber`
2. RSC support check during pack generation via `ReactOnRailsPro.configuration.enable_rsc_support`
3. RSC support validation during component registration
This makes additional validation in the helper methods unnecessary.
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1644
File: lib/react_on_rails/helper.rb:190-197
Timestamp: 2025-02-18T13:08:01.477Z
Learning: RSC support validation is handled in deeper level calls of the React on Rails Pro codebase, so it doesn't need to be validated again in the `rsc_payload_react_component` helper method.
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-12-16T03:39:07.970Z
Learning: Applies to react_on_rails_pro/**/*.{js,ts,jsx,tsx,json,css,scss} : The `react_on_rails_pro/` directory has its own Prettier/ESLint configuration and will be linted separately in CI
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1696
File: node_package/src/RSCPayloadContainer.ts:0-0
Timestamp: 2025-04-09T12:56:10.756Z
Learning: In the react_on_rails codebase, RSC payloads are already stringified using `JSON.stringify()` before being processed by the `escapeScript` function, which handles escaping of special characters. The function only needs to handle specific HTML markers like comments and closing script tags.
📚 Learning: 2025-01-23T18:20:45.824Z
Learnt from: alexeyr-ci
Repo: shakacode/react_on_rails PR: 1687
File: spec/dummy/package.json:0-0
Timestamp: 2025-01-23T18:20:45.824Z
Learning: When adding or updating dependencies in spec/dummy/package.json, maintain version consistency with other package.json files in the codebase to avoid potential version conflicts.
Applied to files:
react_on_rails/spec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonpackage.jsonreact_on_rails_pro/spec/dummy/package.json
📚 Learning: 2025-04-26T21:55:55.874Z
Learnt from: alexeyr-ci2
Repo: shakacode/react_on_rails PR: 1732
File: spec/dummy/client/app-react16/startup/ReduxSharedStoreApp.client.jsx:40-44
Timestamp: 2025-04-26T21:55:55.874Z
Learning: In the react_on_rails project, files under `app-react16` directories are copied/moved to corresponding `/app` directories during the conversion process (removing the `-react16` suffix), which affects their relative import paths at runtime.
Applied to files:
react_on_rails/spec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonpackage.jsonCHANGELOG.mdreact_on_rails_pro/spec/dummy/package.json
📚 Learning: 2025-02-12T16:38:06.537Z
Learnt from: Romex91
Repo: shakacode/react_on_rails PR: 1697
File: package-scripts.yml:28-28
Timestamp: 2025-02-12T16:38:06.537Z
Learning: The file `node_package/lib/ReactOnRails.full.js` is autogenerated during the build process and should not be present in the repository.
Applied to files:
react_on_rails/spec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonpackage.jsonreact_on_rails_pro/spec/dummy/package.json
📚 Learning: 2025-12-16T03:39:07.970Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-12-16T03:39:07.970Z
Learning: Applies to react_on_rails_pro/**/*.{js,ts,jsx,tsx,json,css,scss} : The `react_on_rails_pro/` directory has its own Prettier/ESLint configuration and will be linted separately in CI
Applied to files:
react_on_rails/spec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonpackage.jsonreact_on_rails_pro/spec/dummy/package.json
📚 Learning: 2025-09-16T08:01:11.146Z
Learnt from: justin808
Repo: shakacode/react_on_rails PR: 1770
File: lib/generators/react_on_rails/templates/base/base/app/javascript/src/HelloWorld/ror_components/HelloWorld.client.jsx:2-2
Timestamp: 2025-09-16T08:01:11.146Z
Learning: React on Rails uses webpack CSS Modules configuration with namedExports: true, which requires the import syntax `import * as style from './file.module.css'` rather than the default export pattern. This configuration enables better tree shaking and bundle size optimization for CSS modules.
Applied to files:
react_on_rails/spec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonpackage.jsonreact_on_rails_pro/spec/dummy/package.json
📚 Learning: 2025-12-16T03:39:07.970Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-12-16T03:39:07.970Z
Learning: Applies to packages/react-on-rails/src/**/*.tsx : For React component files, use TypeScript (.tsx extension) and follow the component registry pattern for registration
Applied to files:
react_on_rails/spec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonpackage.jsonreact_on_rails_pro/spec/dummy/package.json
📚 Learning: 2025-12-16T03:39:07.970Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-12-16T03:39:07.970Z
Learning: Applies to lib/react_on_rails/**/*.rb : Validate RBS signatures with `bundle exec rake rbs:validate` and run Steep type checker with `bundle exec rake rbs:steep` for Ruby files
Applied to files:
react_on_rails/spec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonpackage.jsonCHANGELOG.mdreact_on_rails_pro/spec/dummy/package.json
📚 Learning: 2025-09-15T21:24:48.207Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1781
File: node_package/src/ClientSideRenderer.ts:82-95
Timestamp: 2025-09-15T21:24:48.207Z
Learning: In React on Rails, the force_load feature includes both explicit `data-force-load="true"` usage and the ability to hydrate components during the page loading state (`document.readyState === 'loading'`). Both capabilities require a Pro license, so the condition `!railsContext.rorPro && (isComponentForceLoaded || document.readyState === 'loading')` correctly gates both scenarios.
Applied to files:
react_on_rails/spec/dummy/package.json
📚 Learning: 2025-12-16T03:39:07.970Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-12-16T03:39:07.970Z
Learning: Applies to lib/react_on_rails/**/*.rb : Add RBS type signatures for new Ruby files in `lib/react_on_rails/` by creating corresponding `.rbs` files in `sig/react_on_rails/`
Applied to files:
packages/react-on-rails-pro/package.json
📚 Learning: 2025-12-16T03:39:07.970Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-12-16T03:39:07.970Z
Learning: Applies to {package.json,Rakefile,**/webpack.config.js,config/**/*.js} : Validate that no hardcoded paths need updating after resolving merge conflicts in build configuration files
Applied to files:
packages/react-on-rails-pro/package.jsonpackage.jsonreact_on_rails_pro/spec/dummy/package.json
📚 Learning: 2025-02-18T13:08:01.477Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1644
File: lib/react_on_rails/helper.rb:190-197
Timestamp: 2025-02-18T13:08:01.477Z
Learning: RSC support validation in React on Rails Pro is handled through a chain of validations:
1. Pro version check in `run_stream_inside_fiber`
2. RSC support check during pack generation via `ReactOnRailsPro.configuration.enable_rsc_support`
3. RSC support validation during component registration
This makes additional validation in the helper methods unnecessary.
Applied to files:
packages/react-on-rails-pro/package.json
📚 Learning: 2024-12-12T13:07:09.929Z
Learnt from: alexeyr-ci
Repo: shakacode/react_on_rails PR: 1644
File: node_package/src/ReactOnRailsRSC.ts:87-87
Timestamp: 2024-12-12T13:07:09.929Z
Learning: When handling errors in 'node_package/src/ReactOnRailsRSC.ts', include the error stack in error messages in development and test environments to aid debugging.
Applied to files:
packages/react-on-rails-pro/package.jsonpackage.json
📚 Learning: 2025-12-16T03:39:07.970Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-12-16T03:39:07.970Z
Learning: Exclude directories `/coverage`, `/tmp`, `/gen-examples`, `/packages/react-on-rails/lib`, `/node_modules`, and generated directories from IDE indexing to prevent slowdowns
Applied to files:
packages/react-on-rails-pro/package.jsonpackage.json
📚 Learning: 2025-12-16T03:39:07.970Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-12-16T03:39:07.970Z
Learning: Applies to CHANGELOG.md : Update `/CHANGELOG.md` for open-source features, bug fixes, breaking changes, and performance improvements
Applied to files:
CHANGELOG.md
📚 Learning: 2025-12-16T03:39:07.970Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-12-16T03:39:07.970Z
Learning: Applies to CHANGELOG_PRO.md : Update `/CHANGELOG_PRO.md` for Pro-only features, bug fixes, and performance improvements
Applied to files:
CHANGELOG.md
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (10)
- GitHub Check: dummy-app-integration-tests (3.4, 22, latest)
- GitHub Check: examples (3.4, latest)
- GitHub Check: rspec-package-tests (3.4, latest)
- GitHub Check: build-dummy-app-webpack-test-bundles
- GitHub Check: build-dummy-app-webpack-test-bundles
- GitHub Check: pro-lint-js-and-ruby
- GitHub Check: build
- GitHub Check: check-bundle-size
- GitHub Check: markdown-link-check
- GitHub Check: claude-review
🔇 Additional comments (5)
react_on_rails_pro/spec/dummy/package.json (1)
49-50: LGTM! Security vulnerability fixes applied.The upgrades to React v19.0.3 and react-on-rails-rsc v19.0.4 address three critical security vulnerabilities in React Server Components (CVE-2025-55183, CVE-2025-55184, CVE-2025-67779). The use of caret ranges (
^) allows for automatic patch updates while preventing minor version changes.Note: React and react-dom changed from exact versions (19.0.0) to caret ranges (^19.0.3), which is a minor shift in dependency strategy but appropriate for receiving future security patches automatically.
Also applies to: 55-55
package.json (1)
61-63: LGTM! Workspace devDependencies updated for security patches.The React and react-on-rails-rsc version updates in the root workspace devDependencies align with the security vulnerability fixes (CVE-2025-55183, CVE-2025-55184, CVE-2025-67779). The addition of the caret range to react-on-rails-rsc provides consistency with the other dependency specifications.
CHANGELOG.md (1)
24-27: LGTM! Excellent security vulnerability documentation.The changelog entry comprehensively documents the React Server Components security fixes, including:
- Clear identification of all three CVEs with CVSS scores
- Detailed description of the vulnerabilities and their potential impact
- Technical explanation of the fixes (dual-layer cycle detection, toString() override)
- Proper references to related issue and PR
This level of detail helps users understand the importance of the upgrade and the security risks mitigated.
As per coding guidelines, CHANGELOG.md should be updated for security fixes, bug fixes, and breaking changes.
packages/react-on-rails-pro/package.json (1)
81-83: LGTM! devDependencies updated to patched versions.The devDependencies for React, React DOM, and react-on-rails-rsc have been appropriately updated to the versions containing the security fixes. The caret ranges allow for future patch updates while maintaining compatibility.
react_on_rails/spec/dummy/package.json (1)
22-23: LGTM! Dummy app dependencies updated for security patches.React and React DOM have been updated from exact version 19.0.0 to ^19.0.3, aligning with the security vulnerability fixes. The use of caret ranges is consistent with the version strategy adopted across other package.json files in this PR.
Based on learnings, version consistency is maintained across the codebase.
| "react": ">= 16", | ||
| "react-dom": ">= 16", | ||
| "react-on-rails-rsc": "19.0.3" | ||
| "react-on-rails-rsc": ">= 19.0.2 <= 19.2.3" |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Read package.json to see the current peer dependency setup and check for validation logic
fd -t f "package.json" "packages/react-on-rails-pro" -x head -n 80 {}
# Also search for any version validation or checking logic in the codebase
rg -n "19\\.0\\.[2-4]|peerDependenc|version.*check|validateVersion" --type ts --type js "packages/react-on-rails-pro" -A 2 -B 2 | head -100Repository: shakacode/react_on_rails
Length of output: 2881
Update the minimum peer dependency version to exclude vulnerable React Server Components packages.
The current range ">= 19.0.2 <= 19.2.3" allows installation of version 19.0.2, which is vulnerable to CVE-2025-67779, while versions 19.0.3, 19.1.4, 19.2.3 are safe. Version 19.0.2 remains vulnerable to the DoS exploit (CVE-2025-67779).
Change the peer dependency to ">= 19.0.3 <= 19.2.3" to enforce the secure minimum version and prevent accidental installation of packages with high-severity vulnerabilities.
🤖 Prompt for AI Agents
In packages/react-on-rails-pro/package.json around line 63, the peer dependency
range for react-on-rails-rsc allows the vulnerable 19.0.2 release; update the
minimum bound from 19.0.2 to 19.0.3 so the range becomes >= 19.0.3 <= 19.2.3 to
exclude CVE-2025-67779-affected versions and ensure only secure releases are
accepted.
Code Review: PR #2233 - Security Vulnerability Upgrades✅ Overall Assessment: APPROVEDThis PR successfully addresses three critical security vulnerabilities (CVE-2025-55183, CVE-2025-55184, CVE-2025-67779) by upgrading React and react-on-rails-rsc to patched versions. The changes are well-executed and properly documented. Security Impact: ✅ EXCELLENTAll three CVEs properly mitigated:
Verification:
Code Quality: ✅ EXCELLENTDependency ManagementRoot package.json: "react": "^19.0.3", // ✅ Caret range allows patch updates
"react-dom": "^19.0.3", // ✅ Consistent with react
"react-on-rails-rsc": "^19.0.4" // ✅ Allows future patchesPro package peer dependencies: "react-on-rails-rsc": ">= 19.0.2 <= 19.2.3"The peer dependency range
Impact: Low - The devDependency is correctly set to Recommendation: "react-on-rails-rsc": ">= 19.0.3 <= 19.2.3"Lockfile Consistency✅ All lockfiles updated correctly:
✅ Scheduler transitive dependency:
Best Practices: ✅ EXCELLENT✅ CHANGELOG Documentation
✅ Monorepo Consistency
✅ Non-Breaking Change
Testing ConsiderationsRequired Local Testing (from CLAUDE.md)Per project guidelines, the following should be verified before merge: # 1. Clean install
rm -rf node_modules && pnpm install -r --frozen-lockfile
# 2. Build packages
pnpm run build
# 3. Test relevant specs (if RSC functionality changed)
bundle exec rake run_rspec:gem
bundle exec rake run_rspec:dummy
# 4. Lint
bundle exec rubocop
pnpm run lintAssumption: Author ran these tests locally before merging. Since this PR was merged, CI likely passed. Security ValidationTo confirm the fixes are present in the bundled react-on-rails-rsc: # Check for cycle detection fix (CVE-2025-55184/67779)
grep -r "cycleProtection" node_modules/react-on-rails-rsc/
# Check for toString masking (CVE-2025-55183)
grep -r "serverReferenceToString" node_modules/react-on-rails-rsc/Performance Considerations: ✅ NO ISSUESSecurity fixes add minimal overhead:
Only attacked scenarios affected:
Documentation: ✅ EXCELLENTCHANGELOG entry is comprehensive:
PR description:
Recommendations1. HIGH PRIORITY - Update Peer Dependency RangeCurrent: "react-on-rails-rsc": ">= 19.0.2 <= 19.2.3"Recommended: "react-on-rails-rsc": ">= 19.0.3 <= 19.2.3"Reason: Prevents users from inadvertently installing vulnerable 19.0.2 version. Fix: # Edit packages/react-on-rails-pro/package.json line 63
# Then:
cd packages/react-on-rails-pro
pnpm install2. MEDIUM PRIORITY - Add Security TestConsider adding a regression test for cyclic promise handling: // packages/react-on-rails-pro/tests/security.test.js
describe('Security - CVE-2025-55184/67779', () => {
it('should reject cyclic thenables', async () => {
// Create cyclic promise structure
const cyclic = {};
cyclic.then = () => cyclic;
// Should reject instead of hanging
await expect(handleServerResponse(cyclic))
.rejects.toThrow('Cannot have cyclic thenables');
});
});Note: This may require mocking react-on-rails-rsc internals. 3. LOW PRIORITY - Document Security PracticesAdd a security policy mentioning rapid patching for CVEs: # SECURITY.md
## Security Vulnerability Response
We take security seriously and aim to patch critical vulnerabilities within 48 hours of disclosure.
### Dependency Monitoring
- React/React-DOM: We track React security advisories and upgrade promptly
- react-on-rails-rsc: Security patches are expedited
### Reporting
Report security issues to: [security email]SummaryLGTM - Approved with minor recommendations ✅ This is an excellent security patch:
Only issue: Peer dependency allows vulnerable 19.0.2 (easily fixable) Commit message quality: ✅ Clear and follows project standards Risk assessment: LOW - This is a security patch with no API changes. The lockfile pins ensure production safety even with the peer dependency issue. Quick Stats
Great work addressing these vulnerabilities promptly! 🎉 |
Summary
This PR upgrades React and React Server Components to patched versions that fix three critical security vulnerabilities (CVE-2025-55183, CVE-2025-55184, and CVE-2025-67779) in React Server Components.
Security Vulnerabilities Fixed
This upgrade addresses issue #2223:
Changes
^19.0.0→^19.0.3(includes December 11, 2025 security patches)^19.0.0→^19.0.3^19.0.4(includes PR Consider changing default of rendering to prerender: false #12 fixes with react-server-dom-webpack v19.0.3)0.25.0→0.27.0(transitive from React upgrade)Testing
Pull Request Checklist
Other Information
This PR fully mitigates all React vulnerabilities mentioned in issue #2223. The upgrade is non-breaking and compatible with existing React Server Components implementations.
Summary by CodeRabbit
Bug Fixes
Chores
✏️ Tip: You can customize this high-level summary in your review settings.