Exploit databaseDownload repository ZIP
GH-19962432990af15d1c08913e3ea41264
theori-io/reactguard
Sources for CVE-2025-55182
257 sourcesPreferred order: Exploit-DB, Metasploit, then GitHub repositories by stars. Open preferred source
Repository files11
theori-io/reactguardRevision a16b6e87f09e
- ↑..Parent directory
- __init__.py
- base.py
- expo.py
- generic_rsc.py
- nextjs.py
- react_router.py
- rsc_dec2025.py
- rsc_dec2025_evidence.py
- rsc_dec2025_probes.py
- rsc_dec2025_signatures.py
- waku.py
Files from this repository share one source choice. Supporting files may cover other vulnerabilities.
src/reactguard/vulnerability_detection/assessors/rsc_dec2025.py
Python · 3,822 bytes# SPDX-FileCopyrightText: 2025 Theori Inc.
# SPDX-License-Identifier: AGPL-3.0-or-later
"""Assessors for Dec 2025 React Server Components advisories (CVE-2025-55184/67779/55183)."""
from __future__ import annotations
from dataclasses import dataclass
from typing import Any, Literal
from ...utils import normalize_version_map
from ..interpreters.rsc_dec2025_interpreter import RscDec2025Interpreter
from ..journal import PocJournal, get_current_journal
from ..snapshots import DetectContext
from .base import BaseAssessor
from .rsc_dec2025_probes import Dec2025ProbeOrchestrator, dec2025_cache, dec2025_fingerprint_cache
@dataclass(frozen=True)
class RscDec2025Spec:
cve_id: Literal["CVE-2025-55184", "CVE-2025-67779", "CVE-2025-55183"]
title: str
class ReactServerComponentsDec2025Assessor(BaseAssessor):
"""
Non-DoS assessor for the Dec 2025 RSC advisories.
Fingerprints patch sets using bounded probes:
- PR #35345 fingerprint: server reference marker `$h` parsing behavior ($F vs $h differential).
- PR #35351 fingerprint: finite promise chain threshold (cycleProtection guard).
"""
framework_name = "rsc"
def __init__(self, spec: RscDec2025Spec):
self.spec = spec
self.cve_id = spec.cve_id
def evaluate(
self,
base_url: str,
detected_versions: dict[str, Any],
detect_context: DetectContext | None = None,
) -> dict[str, Any]:
detect_context = self._resolve_detect_context(detect_context)
journal = get_current_journal() or PocJournal()
normalized_versions = normalize_version_map(detected_versions)
invocation_enabled = detect_context.invocation_enabled if detect_context else None
invocation_confidence = detect_context.invocation_confidence if detect_context else None
cache = dec2025_cache()
fingerprint_cache = dec2025_fingerprint_cache(cache)
cache_key = str(base_url or "")
cached = fingerprint_cache.get(cache_key) if isinstance(fingerprint_cache, dict) else None
if isinstance(cached, dict) and "patch_fingerprint" in cached and "evidence" in cached and "framework" in cached:
patch_level = cached.get("patch_fingerprint")
evidence = cached.get("evidence") or {}
framework = str(cached.get("framework") or "rsc")
journal.add_event(
"dec2025-cache-hit",
"Reused cached Dec 2025 patch fingerprint for target",
data={"cache_key": cache_key, "patch_fingerprint": patch_level, "framework": framework},
)
else:
journal.add_event(
"dec2025-cache-miss",
"No cached Dec 2025 patch fingerprint; probing endpoints",
data={"cache_key": cache_key},
)
orchestrator = Dec2025ProbeOrchestrator(
base_url=base_url,
detect_context=detect_context,
journal=journal,
cache=cache,
)
patch_level, evidence, framework = orchestrator.fingerprint_patch_level()
cache_entry = {"patch_fingerprint": patch_level, "evidence": evidence, "framework": framework}
if isinstance(fingerprint_cache, dict):
fingerprint_cache[cache_key] = dict(cache_entry)
interpreter = RscDec2025Interpreter(cve_id=self.spec.cve_id, framework=framework)
return interpreter.to_report(
patch_fingerprint=patch_level,
detected_versions=normalized_versions,
evidence=evidence,
journal=journal,
invocation_enabled=invocation_enabled,
invocation_confidence=invocation_confidence,
)
__all__ = ["ReactServerComponentsDec2025Assessor", "RscDec2025Spec"]