| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
…ng (yahoo#207) * fix(CVE-2020-7660): fix for RegExp.flags and Date.prototype.toISOString * fix: add v
Import strictEqual and throw functions to serialize test
There was a problem hiding this comment.
LGTM!
Sorry, something went wrong.
|
Although this PR has been approved, the remaining conflicts are effectively due to the fact that a 6.0.x maintenance branch hasn’t been created yet. |
Sorry, something went wrong.
|
Can the PR description be updated so that it closes #208? |
Sorry, something went wrong.
|
@luckyabsoluter any idea when a maintenance branch will be created? Currently looking at the vulnerability at my workplace |
Sorry, something went wrong.
|
Hello! Are we merging in this PR and publishing v6.0.3? |
Sorry, something went wrong.
|
Is this being taken to completion? |
Sorry, something went wrong.
|
Hey @long76 @gtcarlos-sage , is this going to be merged and published? |
Sorry, something went wrong.
Hi, you need ask maintainers this repository) |
Sorry, something went wrong.
|
Hey @gtcarlos-sage , are you planning to take this to completion? |
Sorry, something went wrong.
|
While the status of this pull request is "This branch has conflicts that must be resolved", that is just an artifact of the missing v6-maintenance branch that should be the branch target (instead of the current main branch). Commands to fix: git branch v6-maintenance v6.0.2
git push origin v6-maintenance |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Summary
This PR backports the security fix introduced in v7.0.3 to the v6.0.2 codebase.
Versions up to v7.0.2 correctly sanitize RegExp.source, but RegExp.flags is still interpolated into generated output without validation or escaping. Additionally, Date.prototype.toISOString() follows the same code path and can be attacker‑controlled.
When serialized output is later evaluated (e.g., via eval, new Function, script injection, etc.), it is possible for malicious values to trigger arbitrary JavaScript execution. This represents an incomplete remediation of the vulnerability originally addressed under CVE‑2020‑7660.
This backport applies the same sanitization and validation logic used in v7.0.3.
Affected Versions
This PR specifically addresses the issue for the v6.x line (based on tag v6.0.2).
Impact
This vulnerability allows improper neutralization of attacker‑controlled values during code generation, resulting in arbitrary JavaScript execution when the serialized output is evaluated.
If an attacker can influence objects passed into serialize(), they can inject code via:
This backport ensures that:
All new tests from the 7.0.3 fix are included and passing.
Request
Upstream currently maintains only the main branch.
This PR originates from a branch created off the v6.0.2 tag.
Could you please create a 6.0.x maintenance branch?
Once created, I will re‑target this PR so that it merges cleanly into the correct version line.
This will allow you to optionally publish a v6.0.3 release containing this security backport.
Verification
License
I confirm that this contribution is made under the terms of the license found in the root directory of this repository's source tree and that I have the authority necessary to make this contribution on behalf of its copyright owner.