CVE-2018-16982: Opencc Denial of Service Vulnerability
MODERATECVE-2018-16982 is a MODERATE (CVSS 5.5) denial of service vulnerability (CWE-125: Out-of-bounds Read) affecting Opencc libraries in the npm ecosystem. The issue involves open chinese convert subject to denial of service via out-of-bounds read. Remediation is available by upgrading affected packages to version 1.1.2.
CVE-2018-16982 at a Glance
Security Impact
CVSS: 5.5
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.0/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H).
How to Fix CVE-2018-16982
To remediate this vulnerability, upgrade all affected Opencc 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 opencc@1.1.2
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls opencc
How to Check if You Are Affected
To determine whether your Node.js application is affected by CVE-2018-16982, inspect your project dependencies using npm:
npm ls opencc
Analyze the terminal output to locate any version of Opencc in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.1.2), your application is affected.
Note: The npm ls opencc 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-125: Out-of-bounds Read, where the product reads data past the end, or before the beginning, of the intended buffer. In Opencc, 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-2018-16982 Affected Opencc Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
opencc
|
npm |
< 1.1.2
|
1.1.2
|
References
Frequently Asked Questions
What is CVE-2018-16982?
Which Opencc versions are affected?
What version fixes CVE-2018-16982?
Is opencc affected?
What is the CVSS score of CVE-2018-16982?
What CWE is associated with CVE-2018-16982?
How can I check npm dependencies for CVE-2018-16982?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-9qh2-6fxg-9m4g",
"modified" : "2024-11-22T17:59:52Z",
"published" : "2022-05-14T01:55:28Z",
"aliases" : [ "CVE-2018-16982" ],
"summary" : "Open Chinese Convert subject to Denial of Service via Out-of-bounds Read",
"details" : "Open Chinese Convert (OpenCC) 1.0.5 allows attackers to cause a denial of service (segmentation fault) because BinaryDict::NewFromFile in BinaryDict.cpp may have out-of-bounds keyOffset and valueOffset values via a crafted .ocd file.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.0/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "opencc"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "1.1.2"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2018-16982"
}, {
"type" : "WEB",
"url" : "https://github.com/BYVoid/OpenCC/issues/303"
}, {
"type" : "WEB",
"url" : "https://github.com/BYVoid/OpenCC/pull/309"
}, {
"type" : "WEB",
"url" : "https://github.com/BYVoid/OpenCC/pull/560"
}, {
"type" : "WEB",
"url" : "https://github.com/BYVoid/OpenCC/pull/560/commits/e1b8c7949738100e4747dd4109ef1f16e1bd99c4"
}, {
"type" : "WEB",
"url" : "https://github.com/BYVoid/OpenCC/commit/4a4f9e58e505fca93605f22363c133df66a91a5e"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/BYVoid/OpenCC"
}, {
"type" : "WEB",
"url" : "https://github.com/pypa/advisory-database/tree/main/vulns/opencc-py/PYSEC-2018-153.yaml"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-125" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2022-09-30T13:10:06Z",
"nvd_published_at" : "2018-09-13T02:29:00Z"
}
}