{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2018-16395","id":"CVE-2018-16395","title":"Ruby Openssl Allows Incorrect Value Comparison","description":"An issue was discovered in the OpenSSL library in Ruby before 2.3.8, 2.4.x before 2.4.5, 2.5.x before 2.5.2, and 2.6.x before 2.6.0-preview3. When two OpenSSL::X509::Name objects are compared using ==, depending on the ordering, non-equal objects may return true. When the first argument is one character longer than the second, or the second argument contains a character that is one less than a cha","descriptionLong":"An issue was discovered in the OpenSSL library in Ruby before 2.3.8, 2.4.x before 2.4.5, 2.5.x before 2.5.2, and 2.6.x before 2.6.0-preview3. When two OpenSSL::X509::Name objects are compared using ==, depending on the ordering, non-equal objects may return true. When the first argument is one character longer than the second, or the second argument contains a character that is one less than a character in the same position of the first argument, the result of == will be true. This could be leveraged to create an illegitimate certificate that may be accepted as legitimate and then used in signing or encryption operations.","published":"2018-11-16T18:00:00.000Z","updated":"2026-10-24T10:30:35.893506376Z","reserved":"2018-09-03T00:00:00.000Z","status":"Modified","rejected":false,"assigner":"mitre","metric":{"version":"3.0","score":9.8,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","rating":"critical","source":"NVD"},"metrics":[{"version":"3.0","score":9.8,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","rating":"critical","source":"NVD"},{"version":"3.0","score":9.8,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","rating":"critical","source":"OSV"},{"version":"3.0","score":9.8,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","rating":"critical","source":"GitHub"},{"version":"2.0","score":7.5,"vector":"AV:N/AC:L/Au:N/C:P/I:P/A:P","rating":"high","source":"NVD"}],"rating":"critical","products":[],"affectedProducts":[{"vendor":"n/a","product":"n/a","defaultStatus":null,"versions":[{"status":"affected","version":"n/a"}],"platforms":[]}],"packages":[{"ecosystem":"RubyGems","name":"openssl","purl":"pkg:gem/openssl","ranges":["<2.0.9",">=2.1.0 <2.1.2"],"fixed":["2.0.9","2.1.2"],"advisory":"GHSA-mmrq-6999-72v8"}],"cwes":[],"aliases":["GHSA-mmrq-6999-72v8"],"references":[{"url":"https://www.ruby-lang.org/en/news/2018/10/17/openssl-x509-name-equality-check-does-not-work-correctly-cve-2018-16395/","tags":["x_refsource_CONFIRM","x_transferred","Mitigation","Vendor Advisory","advisory"]},{"url":"https://access.redhat.com/errata/RHSA-2018:3738","tags":["vendor-advisory","x_refsource_REDHAT","x_transferred","Third Party Advisory","advisory","web"]},{"url":"https://www.ruby-lang.org/en/news/2018/11/06/ruby-2-6-0-preview3-released/","tags":["x_refsource_CONFIRM","x_transferred","Release Notes","Vendor Advisory","advisory"]},{"url":"https://access.redhat.com/errata/RHSA-2018:3729","tags":["vendor-advisory","x_refsource_REDHAT","x_transferred","Third Party Advisory","advisory","web"]},{"url":"https://hackerone.com/reports/387250","tags":["x_refsource_MISC","x_transferred","Patch","Third Party Advisory","fix","web"]},{"url":"https://access.redhat.com/errata/RHSA-2018:3730","tags":["vendor-advisory","x_refsource_REDHAT","x_transferred","Third Party Advisory","advisory","web"]},{"url":"https://access.redhat.com/errata/RHSA-2018:3731","tags":["vendor-advisory","x_refsource_REDHAT","x_transferred","Third Party Advisory","advisory","web"]},{"url":"https://www.ruby-lang.org/en/news/2018/10/17/ruby-2-3-8-released/","tags":["x_refsource_CONFIRM","x_transferred","Release Notes","Vendor Advisory","advisory"]},{"url":"https://www.debian.org/security/2018/dsa-4332","tags":["vendor-advisory","x_refsource_DEBIAN","x_transferred","Third Party Advisory","advisory","web"]},{"url":"https://usn.ubuntu.com/3808-1/","tags":["vendor-advisory","x_refsource_UBUNTU","x_transferred","Third Party Advisory","advisory"]},{"url":"https://www.ruby-lang.org/en/news/2018/10/17/ruby-2-4-5-released/","tags":["x_refsource_CONFIRM","x_transferred","Release Notes","Vendor Advisory","advisory"]},{"url":"https://security.netapp.com/advisory/ntap-20190221-0002/","tags":["x_refsource_CONFIRM","x_transferred","Third Party Advisory","advisory"]},{"url":"https://www.ruby-lang.org/en/news/2018/10/17/ruby-2-5-2-released/","tags":["x_refsource_CONFIRM","x_transferred","Release Notes","Vendor Advisory","advisory"]},{"url":"https://lists.debian.org/debian-lts-announce/2018/10/msg00020.html","tags":["mailing-list","x_refsource_MLIST","x_transferred","Third Party Advisory","advisory","web"]},{"url":"http://www.securitytracker.com/id/1042105","tags":["vdb-entry","x_refsource_SECTRACK","x_transferred","Third Party Advisory","VDB Entry","advisory"]},{"url":"http://lists.opensuse.org/opensuse-security-announce/2019-07/msg00036.html","tags":["vendor-advisory","x_refsource_SUSE","x_transferred","Mailing List","Third Party Advisory","advisory","web"]},{"url":"https://access.redhat.com/errata/RHSA-2019:1948","tags":["vendor-advisory","x_refsource_REDHAT","x_transferred","Third Party Advisory","advisory","web"]},{"url":"https://access.redhat.com/errata/RHSA-2019:2565","tags":["vendor-advisory","x_refsource_REDHAT","x_transferred","advisory","web"]},{"url":"https://www.oracle.com/security-alerts/cpujan2020.html","tags":["x_refsource_MISC","x_transferred","web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2018-16395","tags":["advisory"]},{"url":"https://github.com/ruby/openssl/commit/f653cfa43f0f20e8c440122ea982382b6228e7f5","tags":["web"]},{"url":"https://www.ruby-lang.org/en/news/2018/11/06/ruby-2-6-0-preview3-released","tags":["web"]},{"url":"https://www.ruby-lang.org/en/news/2018/10/17/ruby-2-5-2-released","tags":["web"]},{"url":"https://www.ruby-lang.org/en/news/2018/10/17/ruby-2-4-5-released","tags":["web"]},{"url":"https://www.ruby-lang.org/en/news/2018/10/17/ruby-2-3-8-released","tags":["web"]},{"url":"https://www.ruby-lang.org/en/news/2018/10/17/openssl-x509-name-equality-check-does-not-work-correctly-cve-2018-16395","tags":["web"]},{"url":"https://web.archive.org/web/20211206015239/https://securitytracker.com/id/1042105","tags":["web"]},{"url":"https://usn.ubuntu.com/3808-1","tags":["web"]},{"url":"https://security.netapp.com/advisory/ntap-20190221-0002","tags":["web"]},{"url":"https://github.com/rubysec/ruby-advisory-db/blob/master/gems/openssl/CVE-2018-16395.yml","tags":["web"]}],"patchReferenced":true,"fixAvailable":true,"exploitReferenced":false,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":null,"epss":0.10715,"epssPercentile":0.9591,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2018-16395","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2018-16395","ok":true,"note":"Modified"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2018-16395","ok":true,"note":"1 package"},{"name":"GitHub Advisory","url":"https://github.com/advisories/GHSA-mmrq-6999-72v8","ok":true,"note":"GHSA-mmrq-6999-72v8"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2018-16395","ok":true,"note":"scored 2026-11-18"}],"aiTitle":false,"tech":["openssl"],"critical":["CVSS 9.8 in a widely used technology","EPSS 11% with CVSS 9.8"],"attention":null}