CVE-2026-39853

Source
https://cve.org/CVERecord?id=CVE-2026-39853
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-39853.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2026-39853
Aliases
  • GHSA-hx87-8754-xvh4
Downstream
Published
2026-04-09T15:50:26.548Z
Modified
2026-08-12T16:23:58.289345Z
Severity
  • 7.8 (High) CVSS_V3 - CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H CVSS Calculator
Summary
osslsigncode has a Stack Buffer Overflow via Unbounded Digest Copy During Signature Verification
Details

osslsigncode is a tool that implements Authenticode signing and timestamping. Prior to 2.12, A stack buffer overflow vulnerability exists in osslsigncode in several signature verification paths. During verification of a PKCS#7 signature, the code copies the digest value from a parsed SpcIndirectDataContent structure into a fixed-size stack buffer (mdbuf[EVPMAXMD_SIZE], 64 bytes) without validating that the source length fits within the destination buffer. This pattern is present in the verification handlers for PE, MSI, CAB, and script files. An attacker can craft a malicious signed file with an oversized digest field in SpcIndirectDataContent. When a user verifies such a file with osslsigncode verify, the unbounded memcpy can overflow the stack buffer and corrupt adjacent stack state. This vulnerability is fixed in 2.12.

Database specific
{
    "cna_assigner": "GitHub_M",
    "cwe_ids": [
        "CWE-121",
        "CWE-787"
    ],
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/39xxx/CVE-2026-39853.json"
}
References

Affected packages

Git / github.com/mtrojnar/osslsigncode

Affected ranges

Type
GIT
Repo
https://github.com/mtrojnar/osslsigncode
Events
Introduced
0 Unknown introduced commit / All previous commits are affected
Fixed
Fixed
Database specific
Show details
{
    "extracted_events": [
        {
            "introduced": "0"
        },
        {
            "fixed": "2.12"
        }
    ],
    "source": [
        "CPE_RANGE",
        "REFERENCES"
    ],
    "cpe": "cpe:2.3:a:osslsigncode_project:osslsigncode:*:*:*:*:*:*:*:*"
}

Affected versions

2.*
2.0
2.1
2.10
2.11
2.2
2.3
2.4
2.5
2.6
2.7
2.8
2.9

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-39853.json"
vanir_signatures
[
    {
        "target": {
            "function": "msi_verify_digests",
            "file": "msi.c"
        },
        "deprecated": false,
        "source": "https://github.com/mtrojnar/osslsigncode/commit/cbee1e723c5a8547302bd841ad9943ed8144db68",
        "id": "CVE-2026-39853-1c46e99e",
        "signature_version": "v1",
        "digest": {
            "length": 3442.0,
            "function_hash": "7082838060947355442102594181268479517"
        },
        "signature_type": "Function"
    },
    {
        "target": {
            "file": "helpers.h"
        },
        "deprecated": false,
        "source": "https://github.com/mtrojnar/osslsigncode/commit/cbee1e723c5a8547302bd841ad9943ed8144db68",
        "id": "CVE-2026-39853-245900bc",
        "signature_version": "v1",
        "digest": {
            "threshold": 0.9,
            "line_hashes": [
                "135713086926393218447926872216326261372",
                "199914932917842896028731767519076129123"
            ]
        },
        "signature_type": "Line"
    },
    {
        "target": {
            "file": "cat.c"
        },
        "deprecated": false,
        "source": "https://github.com/mtrojnar/osslsigncode/commit/cbee1e723c5a8547302bd841ad9943ed8144db68",
        "id": "CVE-2026-39853-25e54eff",
        "signature_version": "v1",
        "digest": {
            "threshold": 0.9,
            "line_hashes": [
                "68415973127219734331714277347035975712",
                "325540716297678602498258335186037007802",
                "140759284760969063668494452973539589512",
                "337882276697824980006384321900902187802",
                "115427071862798010042693710436358850595",
                "67522959823450650990004599689480862185"
            ]
        },
        "signature_type": "Line"
    },
    {
        "target": {
            "function": "cat_print_content_member_digest",
            "file": "cat.c"
        },
        "deprecated": false,
        "source": "https://github.com/mtrojnar/osslsigncode/commit/cbee1e723c5a8547302bd841ad9943ed8144db68",
        "id": "CVE-2026-39853-496a7c8c",
        "signature_version": "v1",
        "digest": {
            "length": 840.0,
            "function_hash": "330075126843529403136055493081121401"
        },
        "signature_type": "Function"
    },
    {
        "target": {
            "file": "msi.c"
        },
        "deprecated": false,
        "source": "https://github.com/mtrojnar/osslsigncode/commit/cbee1e723c5a8547302bd841ad9943ed8144db68",
        "id": "CVE-2026-39853-4c28ce3e",
        "signature_version": "v1",
        "digest": {
            "threshold": 0.9,
            "line_hashes": [
                "294196164287761961589666703434750257173",
                "60495124532956490106045270096232172204",
                "151216767925243767661756542210958922717",
                "337882276697824980006384321900902187802",
                "115427071862798010042693710436358850595",
                "165970862720636573206245504323385944522"
            ]
        },
        "signature_type": "Line"
    },
    {
        "target": {
            "function": "pe_verify_digests",
            "file": "pe.c"
        },
        "deprecated": false,
        "source": "https://github.com/mtrojnar/osslsigncode/commit/cbee1e723c5a8547302bd841ad9943ed8144db68",
        "id": "CVE-2026-39853-63fe31a9",
        "signature_version": "v1",
        "digest": {
            "length": 1556.0,
            "function_hash": "98387009644364892356896584865388264656"
        },
        "signature_type": "Function"
    },
    {
        "target": {
            "file": "osslsigncode.c"
        },
        "deprecated": false,
        "source": "https://github.com/mtrojnar/osslsigncode/commit/cbee1e723c5a8547302bd841ad9943ed8144db68",
        "id": "CVE-2026-39853-7edc3891",
        "signature_version": "v1",
        "digest": {
            "threshold": 0.9,
            "line_hashes": [
                "177243898153687793868340892984033007942",
                "188228084852164090110183459134525021076",
                "222957626769235363520763389406175655106",
                "337882276697824980006384321900902187802",
                "211883438698217851110911666084850698172",
                "209386534667382533773141099439571757428"
            ]
        },
        "signature_type": "Line"
    },
    {
        "target": {
            "function": "cab_verify_digests",
            "file": "cab.c"
        },
        "deprecated": false,
        "source": "https://github.com/mtrojnar/osslsigncode/commit/cbee1e723c5a8547302bd841ad9943ed8144db68",
        "id": "CVE-2026-39853-95e8b7e0",
        "signature_version": "v1",
        "digest": {
            "length": 1118.0,
            "function_hash": "317210793094659141246130368244393693107"
        },
        "signature_type": "Function"
    },
    {
        "target": {
            "file": "helpers.c"
        },
        "deprecated": false,
        "source": "https://github.com/mtrojnar/osslsigncode/commit/cbee1e723c5a8547302bd841ad9943ed8144db68",
        "id": "CVE-2026-39853-ace119bd",
        "signature_version": "v1",
        "digest": {
            "threshold": 0.9,
            "line_hashes": [
                "36272731860730000053498603403996601283",
                "85397026836763774827995722626512084907",
                "272474611131647023760888946609624306382"
            ]
        },
        "signature_type": "Line"
    },
    {
        "target": {
            "file": "script.c"
        },
        "deprecated": false,
        "source": "https://github.com/mtrojnar/osslsigncode/commit/cbee1e723c5a8547302bd841ad9943ed8144db68",
        "id": "CVE-2026-39853-d31659a0",
        "signature_version": "v1",
        "digest": {
            "threshold": 0.9,
            "line_hashes": [
                "294196164287761961589666703434750257173",
                "60495124532956490106045270096232172204",
                "151216767925243767661756542210958922717",
                "337882276697824980006384321900902187802",
                "115427071862798010042693710436358850595",
                "165970862720636573206245504323385944522"
            ]
        },
        "signature_type": "Line"
    },
    {
        "target": {
            "function": "script_verify_digests",
            "file": "script.c"
        },
        "deprecated": false,
        "source": "https://github.com/mtrojnar/osslsigncode/commit/cbee1e723c5a8547302bd841ad9943ed8144db68",
        "id": "CVE-2026-39853-e2a27dba",
        "signature_version": "v1",
        "digest": {
            "length": 1193.0,
            "function_hash": "297053246920564782174884000374205904393"
        },
        "signature_type": "Function"
    },
    {
        "target": {
            "function": "verify_content_member_digest",
            "file": "osslsigncode.c"
        },
        "deprecated": false,
        "source": "https://github.com/mtrojnar/osslsigncode/commit/cbee1e723c5a8547302bd841ad9943ed8144db68",
        "id": "CVE-2026-39853-e5f53135",
        "signature_version": "v1",
        "digest": {
            "length": 1717.0,
            "function_hash": "162772363341062063893543784638959021372"
        },
        "signature_type": "Function"
    },
    {
        "target": {
            "file": "cab.c"
        },
        "deprecated": false,
        "source": "https://github.com/mtrojnar/osslsigncode/commit/cbee1e723c5a8547302bd841ad9943ed8144db68",
        "id": "CVE-2026-39853-eb077b2a",
        "signature_version": "v1",
        "digest": {
            "threshold": 0.9,
            "line_hashes": [
                "294196164287761961589666703434750257173",
                "60495124532956490106045270096232172204",
                "151216767925243767661756542210958922717",
                "337882276697824980006384321900902187802",
                "115427071862798010042693710436358850595",
                "165970862720636573206245504323385944522"
            ]
        },
        "signature_type": "Line"
    },
    {
        "target": {
            "file": "pe.c"
        },
        "deprecated": false,
        "source": "https://github.com/mtrojnar/osslsigncode/commit/cbee1e723c5a8547302bd841ad9943ed8144db68",
        "id": "CVE-2026-39853-efe8cca2",
        "signature_version": "v1",
        "digest": {
            "threshold": 0.9,
            "line_hashes": [
                "213052994559488522703551477998432787905",
                "144174570826663442529232161926665724338",
                "222957626769235363520763389406175655106",
                "337882276697824980006384321900902187802",
                "115427071862798010042693710436358850595",
                "165970862720636573206245504323385944522"
            ]
        },
        "signature_type": "Line"
    }
]
vanir_signatures_modified
"2026-08-12T16:23:58Z"