-
Type:
Bug
-
Resolution: Unresolved
-
Priority:
Critical - P2
-
None
-
Affects Version/s: 8.0.16
-
Component/s: None
-
None
-
Query Execution
-
ALL
-
-
QE 2026-03-30, QE 2026-04-13
-
None
-
None
-
None
-
None
-
None
-
None
-
None
When executing an aggregation pipeline containing a highly complex regex (which induces catastrophic backtracking, such as excessive negative lookaheads), the mongod process unexpectedly crashes with a Segmentation Fault (Signal 11).
Instead of failing the query gracefully (e.g., throwing a PCRE match limit error or operation time limit exceeded), the server crashes entirely during the cleanup phase. The backtrace shows that the crash occurs inside pcre2_match_data_free_8, called from mongo::RegexMatchExpression::matchesSingleElement via mongo::pcre::MatchData::~MatchData().
This suggests a memory management or cleanup bug (e.g., invalid memory access at address: 0) in the PCRE2 integration when a regex evaluation is aborted due to extreme backtracking.