{
    "dataType": "CVE_RECORD",
    "dataVersion": "5.2",
    "cveMetadata": {
        "cveId": "CVE-2025-38699",
        "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "state": "PUBLISHED",
        "assignerShortName": "Linux",
        "dateReserved": "2025-04-16T04:51:24.032Z",
        "datePublished": "2025-09-04T15:32:51.420Z",
        "dateUpdated": "2026-05-12T12:05:36.591Z"
    },
    "containers": {
        "cna": {
            "providerMetadata": {
                "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
                "shortName": "Linux",
                "dateUpdated": "2026-05-11T21:33:16.643Z"
            },
            "descriptions": [
                {
                    "lang": "en",
                    "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nscsi: bfa: Double-free fix\n\nWhen the bfad_im_probe() function fails during initialization, the memory\npointed to by bfad->im is freed without setting bfad->im to NULL.\n\nSubsequently, during driver uninstallation, when the state machine enters\nthe bfad_sm_stopping state and calls the bfad_im_probe_undo() function,\nit attempts to free the memory pointed to by bfad->im again, thereby\ntriggering a double-free vulnerability.\n\nSet bfad->im to NULL if probing fails."
                }
            ],
            "affected": [
                {
                    "product": "Linux",
                    "vendor": "Linux",
                    "defaultStatus": "unaffected",
                    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                    "programFiles": [
                        "drivers/scsi/bfa/bfad_im.c"
                    ],
                    "versions": [
                        {
                            "version": "7725ccfda59715ecf8f99e3b520a0b84cc2ea79e",
                            "lessThan": "684c92bb08a25ed3c0356bc7eb532ed5b19588dd",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "7725ccfda59715ecf8f99e3b520a0b84cc2ea79e",
                            "lessThan": "9337c2affbaebe00b75fdf84ea0e2fcf93c140af",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "7725ccfda59715ecf8f99e3b520a0b84cc2ea79e",
                            "lessThan": "ba024d92564580bb90ec367248ace8efe16ce815",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "7725ccfda59715ecf8f99e3b520a0b84cc2ea79e",
                            "lessThan": "8e03dd9fadf76db5b9799583074a1a2a54f787f1",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "7725ccfda59715ecf8f99e3b520a0b84cc2ea79e",
                            "lessThan": "39cfe2c83146aad956318f866d0ee471b7a61fa5",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "7725ccfda59715ecf8f99e3b520a0b84cc2ea79e",
                            "lessThan": "13f613228cf3c96a038424cd97aa4d6aadc66294",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "7725ccfda59715ecf8f99e3b520a0b84cc2ea79e",
                            "lessThan": "8456f862cb95bcc3a831e1ba87c0c17068be0f3f",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "7725ccfda59715ecf8f99e3b520a0b84cc2ea79e",
                            "lessThan": "50d9bd48321038bd6e15af5a454bbcd180cf6f80",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "7725ccfda59715ecf8f99e3b520a0b84cc2ea79e",
                            "lessThan": "add4c4850363d7c1b72e8fce9ccb21fdd2cf5dc9",
                            "status": "affected",
                            "versionType": "git"
                        }
                    ]
                },
                {
                    "product": "Linux",
                    "vendor": "Linux",
                    "defaultStatus": "affected",
                    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                    "programFiles": [
                        "drivers/scsi/bfa/bfad_im.c"
                    ],
                    "versions": [
                        {
                            "version": "2.6.32",
                            "status": "affected"
                        },
                        {
                            "version": "0",
                            "lessThan": "2.6.32",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "5.4.297",
                            "lessThanOrEqual": "5.4.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "5.10.241",
                            "lessThanOrEqual": "5.10.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "5.15.190",
                            "lessThanOrEqual": "5.15.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.1.149",
                            "lessThanOrEqual": "6.1.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.6.103",
                            "lessThanOrEqual": "6.6.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.12.43",
                            "lessThanOrEqual": "6.12.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.15.11",
                            "lessThanOrEqual": "6.15.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.16.2",
                            "lessThanOrEqual": "6.16.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.17",
                            "lessThanOrEqual": "*",
                            "status": "unaffected",
                            "versionType": "original_commit_for_fix"
                        }
                    ]
                }
            ],
            "cpeApplicability": [
                {
                    "nodes": [
                        {
                            "operator": "OR",
                            "negate": false,
                            "cpeMatch": [
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "2.6.32",
                                    "versionEndExcluding": "5.4.297"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "2.6.32",
                                    "versionEndExcluding": "5.10.241"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "2.6.32",
                                    "versionEndExcluding": "5.15.190"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "2.6.32",
                                    "versionEndExcluding": "6.1.149"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "2.6.32",
                                    "versionEndExcluding": "6.6.103"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "2.6.32",
                                    "versionEndExcluding": "6.12.43"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "2.6.32",
                                    "versionEndExcluding": "6.15.11"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "2.6.32",
                                    "versionEndExcluding": "6.16.2"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "2.6.32",
                                    "versionEndExcluding": "6.17"
                                }
                            ]
                        }
                    ]
                }
            ],
            "references": [
                {
                    "url": "https://git.kernel.org/stable/c/684c92bb08a25ed3c0356bc7eb532ed5b19588dd"
                },
                {
                    "url": "https://git.kernel.org/stable/c/9337c2affbaebe00b75fdf84ea0e2fcf93c140af"
                },
                {
                    "url": "https://git.kernel.org/stable/c/ba024d92564580bb90ec367248ace8efe16ce815"
                },
                {
                    "url": "https://git.kernel.org/stable/c/8e03dd9fadf76db5b9799583074a1a2a54f787f1"
                },
                {
                    "url": "https://git.kernel.org/stable/c/39cfe2c83146aad956318f866d0ee471b7a61fa5"
                },
                {
                    "url": "https://git.kernel.org/stable/c/13f613228cf3c96a038424cd97aa4d6aadc66294"
                },
                {
                    "url": "https://git.kernel.org/stable/c/8456f862cb95bcc3a831e1ba87c0c17068be0f3f"
                },
                {
                    "url": "https://git.kernel.org/stable/c/50d9bd48321038bd6e15af5a454bbcd180cf6f80"
                },
                {
                    "url": "https://git.kernel.org/stable/c/add4c4850363d7c1b72e8fce9ccb21fdd2cf5dc9"
                }
            ],
            "title": "scsi: bfa: Double-free fix",
            "x_generator": {
                "engine": "bippy-1.2.0"
            }
        },
        "adp": [
            {
                "title": "CVE Program Container",
                "references": [
                    {
                        "url": "https://lists.debian.org/debian-lts-announce/2025/10/msg00008.html"
                    },
                    {
                        "url": "https://lists.debian.org/debian-lts-announce/2025/10/msg00007.html"
                    }
                ],
                "providerMetadata": {
                    "orgId": "af854a3a-2127-422b-91ae-364da2661108",
                    "shortName": "CVE",
                    "dateUpdated": "2025-11-03T17:41:29.823Z"
                }
            },
            {
                "x_adpType": "supplier",
                "providerMetadata": {
                    "orgId": "0b142b55-0307-4c5a-b3c9-f314f3fb7c5e",
                    "shortName": "siemens-SADP",
                    "dateUpdated": "2026-05-12T12:05:36.591Z"
                },
                "affected": [
                    {
                        "vendor": "Siemens",
                        "product": "SIMATIC CN 4100",
                        "versions": [
                            {
                                "status": "affected",
                                "version": "0",
                                "lessThan": "V5.0",
                                "versionType": "custom"
                            }
                        ],
                        "defaultStatus": "unknown"
                    }
                ],
                "references": [
                    {
                        "url": "https://cert-portal.siemens.com/productcert/html/ssa-032379.html"
                    }
                ]
            }
        ]
    }
}