CVE-2026-58270: @sync in/server Denial of Service Vulnerability
MODERATECVE-2026-58270 is a MODERATE (CVSS 6.5) denial of service vulnerability (CWE-1333: Inefficient Regular Expression Complexity) affecting @sync in/server libraries in the npm ecosystem. The issue involves sync-in server has a redos via unsanitized regex in sync diff `pathfilters`. Remediation is available by upgrading affected packages to version 2.4.0.
CVE-2026-58270 at a Glance
Security Impact
CVSS: 6.5
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H).
How to Fix CVE-2026-58270
To remediate this vulnerability, upgrade all affected @sync in/server dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
npm install @sync-in/server@2.4.0
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls @sync-in/server
How to Check if You Are Affected
To determine whether your Node.js application is affected by CVE-2026-58270, inspect your project dependencies using npm:
npm ls @sync-in/server
Analyze the terminal output to locate any version of @sync in/server in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.4.0), your application is affected.
Note: The npm ls @sync-in/server command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-1333: Inefficient Regular Expression Complexity, where the product uses a regular expression with a worst-case computational complexity that is inefficient and possibly exponential. In @sync in/server, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2026-58270 Affected @sync in/server Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
@sync-in/server
|
npm |
< 2.4.0
|
2.4.0
|
References
Frequently Asked Questions
What is CVE-2026-58270?
Which @sync in/server versions are affected?
What version fixes CVE-2026-58270?
Is @sync-in/server affected?
What is the CVSS score of CVE-2026-58270?
What CWE is associated with CVE-2026-58270?
How can I check npm dependencies for CVE-2026-58270?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-jx63-h26r-8cph",
"modified" : "2026-09-22T14:47:56Z",
"published" : "2026-09-22T14:47:56Z",
"aliases" : [ "CVE-2026-58270" ],
"summary" : "Sync-in Server has a ReDoS via Unsanitized Regex in Sync Diff `pathFilters`",
"details" : "**Affected component:** Sync-in Server v2.3.0, `POST /api/app/sync/operation/diff/:id`, vulnerable implementation of `pathFilters` in `backend/src/applications/sync/dtos/sync-operations.dto.ts`.\n\n## Summary\n\nIn the vulnerable version, the sync diff endpoint accepted a user-controlled regex pattern through `pathFilters` and compiled it into a `RegExp` without complexity validation. The resulting regex was then executed synchronously against relative file paths during diff generation.\n\nA catastrophic-backtracking pattern, such as `^(a+)+b`, can block the affected Node.js event loop when evaluated against a worst-case path shape. In a single-process deployment, this can make the server unavailable to other users while the regex evaluation is running. Repeated malicious requests can sustain the denial of service.\n\n## Details\n\n`SyncDiffDto` transformed user input directly into a `RegExp` without validating regex complexity:\n```typescript\n// backend/src/applications/sync/dtos/sync-operations.dto.ts\n@IsOptional()\n@Transform(({ value }) => (typeof value === 'string' && value.length > 0 ? new RegExp(value, 'i') : null))\npathFilters?: RegExp = null\n```\nThe compiled regex was then executed synchronously during sync diff traversal:\n```typescript\n// backend/src/applications/sync/services/sync-manager.service.ts\nif (ctx.syncDiff.pathFilters && ctx.syncDiff.pathFilters.test(filePath)) {\n```\nBecause `.test()` is synchronous, a catastrophic-backtracking pattern can block the Node.js event loop for the duration of the regex evaluation.\n\nThe impact depends on the file paths being tested. For example, the pattern `^(a+)+b` is most effective when the sync tree contains a relative path beginning with a long sequence of `a` characters and not followed by `b`.\n\n## PoC\n\n**Prerequisites:** Valid non-guest account, a registered sync client, and a sync path containing at least one file or directory whose relative path triggers catastrophic backtracking for the supplied pattern.\n\nFor the payload `^(a+)+b`, an effective test case is a path containing a long name made of repeated `a` characters.\n\n**Steps:**\n\n1. Register a sync client: `POST /api/app/sync/register` with credentials and `clientId`.\n2. Authenticate: `POST /api/app/sync/auth/cookie` to get a JWT with `clientId` embedded.\n3. Create or use a sync path targeting an application-managed directory containing files.\n4. Ensure the sync path contains a worst-case filename or directory name for the regex, for example a long sequence of `a` characters.\n5. Send a diff request with the ReDoS pattern:\n```http\nPOST /api/app/sync/operation/diff/1\nContent-Type: application/json\nsync-in-csrf: <csrf-token>\nCookie: sync-in-access=<jwt>\n\n{\"secureDiff\":false,\"firstSync\":true,\"defaultFilters\":[],\"pathFilters\":\"^(a+)+b\",\"snapshot\":{}}\n```\n**Evidence from live test on Sync-in Server v2.3.0, Node.js v24.16.0:**\n```text\n[+] Baseline (no pathFilters): 0.019s, 15 files\n[*] Sending ReDoS pattern: ^(a+)+b\n[!] TIMEOUT after 20.022s - ReDoS CONFIRMED\n\n# Server state during ReDoS:\n$ docker stats sync-in --no-stream\nCONTAINER CPU % MEM USAGE\nsync-in 398.82% 745.2MiB / 7.709GiB\n\n# Other endpoints did not respond during the timeout window:\n$ curl -m 5 http://target:8080/\n(exit code 28 - connection timeout)\n```\nThe container-level CPU spike indicates severe resource saturation while the endpoint was unresponsive. The request timeout demonstrates event-loop blocking during the observed window, but does not by itself prove permanent failure after the malicious request stops.\n\n## Impact\n\nAn authenticated user with desktop sync access can submit a malicious `pathFilters` regex that blocks the affected Node.js event loop during sync diff generation.\n\nIn a single-process deployment, this can prevent other HTTP requests, including health checks, from receiving responses while the regex evaluation is running. Repeated malicious requests can keep the service unavailable and may require administrative intervention.\n\n## Remediation\n\nValidate `pathFilters` before using the resulting regex during diff traversal.\n\nRecommended controls:\n\n- Reject empty or non-string values.\n- Enforce a maximum regex pattern length.\n- Reject invalid regex syntax.\n- Reject unsafe regex patterns using `safe-regex2` or an equivalent safety checker.\n- Return a `BadRequestException` for invalid or unsafe patterns.\n\nExample remediation:\n```typescript\n@IsOptional()\n@Transform(({ value }) => {\n if (typeof value !== 'string' || value.length === 0) return null\n\n if (value.length > MAX_PATH_FILTER_PATTERN_LENGTH) {\n throw new BadRequestException('Path filter pattern is too long')\n }\n\n let pathFilter: RegExp\n try {\n pathFilter = new RegExp(value, 'i')\n } catch {\n throw new BadRequestException('Invalid path filter pattern')\n }\n\n if (!isSafePattern(pathFilter)) {\n throw new BadRequestException('Unsafe path filter pattern')\n }\n\n return pathFilter\n})\npathFilters?: RegExp = null\n```\nWhere `isSafePattern` uses `safe-regex2` or equivalent to reject patterns likely to cause catastrophic backtracking, including nested quantifier patterns such as `^(a+)+b`.\n\nA regression test should assert that `^(a+)+b` is rejected before the regex is used against file paths.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "@sync-in/server"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "2.4.0"
} ]
} ],
"database_specific" : {
"last_known_affected_version_range" : "<= 2.3.0"
}
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/Sync-in/server/security/advisories/GHSA-jx63-h26r-8cph"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-58270"
}, {
"type" : "WEB",
"url" : "https://github.com/Sync-in/server/pull/228"
}, {
"type" : "WEB",
"url" : "https://github.com/Sync-in/server/commit/b1dcaa1d1c1bb17ab6c31a404cc9cead7efdd979"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/Sync-in/server"
}, {
"type" : "WEB",
"url" : "https://github.com/Sync-in/server/releases/tag/v2.4.0"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-1333" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2026-09-22T14:47:56Z",
"nvd_published_at" : "2026-09-21T21:17:06Z"
}
}