{"api_version":"1","generated_at":"2026-07-23T13:25:16+00:00","cve":"CVE-2024-50120","urls":{"html":"https://cve.report/CVE-2024-50120","api":"https://cve.report/api/cve/CVE-2024-50120.json","docs":"https://cve.report/api","cve_org":"https://www.cve.org/CVERecord?id=CVE-2024-50120","nvd":"https://nvd.nist.gov/vuln/detail/CVE-2024-50120"},"summary":{"title":"smb: client: Handle kstrdup failures for passwords","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nsmb: client: Handle kstrdup failures for passwords\n\nIn smb3_reconfigure(), after duplicating ctx->password and\nctx->password2 with kstrdup(), we need to check for allocation\nfailures.\n\nIf ses->password allocation fails, return -ENOMEM.\nIf ses->password2 allocation fails, free ses->password, set it\nto NULL, and return -ENOMEM.","state":"PUBLISHED","assigner":"Linux","published_at":"2024-11-05 18:15:15","updated_at":"2026-04-06 14:01:16"},"problem_types":["NVD-CWE-noinfo"],"metrics":[{"version":"3.1","source":"nvd@nist.gov","type":"Primary","score":"5.5","severity":"MEDIUM","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","data":{"version":"3.1","vectorString":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","baseScore":5.5,"baseSeverity":"MEDIUM","attackVector":"LOCAL","attackComplexity":"LOW","privilegesRequired":"LOW","userInteraction":"NONE","scope":"UNCHANGED","confidentialityImpact":"NONE","integrityImpact":"NONE","availabilityImpact":"HIGH"}}],"references":[{"url":"https://git.kernel.org/stable/c/9a5dd61151399ad5a5d69aad28ab164734c1e3bc","name":"https://git.kernel.org/stable/c/9a5dd61151399ad5a5d69aad28ab164734c1e3bc","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":["Patch"],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/35dbac8c328d6afe937cd45ecd41d209d0b9f8b8","name":"https://git.kernel.org/stable/c/35dbac8c328d6afe937cd45ecd41d209d0b9f8b8","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":["Patch"],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/35488799b0ab6e4327f82e1d9209a60805665b37","name":"https://git.kernel.org/stable/c/35488799b0ab6e4327f82e1d9209a60805665b37","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":["Patch"],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://www.cve.org/CVERecord?id=CVE-2024-50120","name":"CVE Program record","refsource":"CVE.ORG","tags":["canonical"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2024-50120","name":"NVD vulnerability detail","refsource":"NVD","tags":["canonical","analysis"]}],"affected":[{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 7e8cffa4f85e6839335d75e6b47f918d90c1d194 35dbac8c328d6afe937cd45ecd41d209d0b9f8b8 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected c1eb537bf4560b3ad4df606c266c665624f3b502 35488799b0ab6e4327f82e1d9209a60805665b37 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected c1eb537bf4560b3ad4df606c266c665624f3b502 9a5dd61151399ad5a5d69aad28ab164734c1e3bc git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected e78308a6dcab1e53b38b8dd952e69c515cd324d7 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 2a0fc63f1f4fccfeb367d0c57b8a243cec60c26c git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 6.9","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 6.9 semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 6.6.59 6.6.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 6.11.6 6.11.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 6.12 * original_commit_for_fix","platforms":[]}],"timeline":[],"solutions":[],"workarounds":[],"exploits":[],"credits":[],"nvd_cpes":[{"cve_year":"2024","cve_id":"50120","vulnerable":"1","versionEndIncluding":"","cpe1":"cpe","cpe2":"2.3","cpe3":"o","cpe4":"linux","cpe5":"linux_kernel","cpe6":"*","cpe7":"*","cpe8":"*","cpe9":"*","cpe10":"*","cpe11":"*","cpe12":"*","cpe13":"*"}],"vendor_comments":[],"enrichments":{"kev":null,"epss":null,"legacy_qids":[]},"source_records":{"cve_program":{"containers":{"cna":{"affected":[{"defaultStatus":"unaffected","product":"Linux","programFiles":["fs/smb/client/fs_context.c"],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","vendor":"Linux","versions":[{"lessThan":"35dbac8c328d6afe937cd45ecd41d209d0b9f8b8","status":"affected","version":"7e8cffa4f85e6839335d75e6b47f918d90c1d194","versionType":"git"},{"lessThan":"35488799b0ab6e4327f82e1d9209a60805665b37","status":"affected","version":"c1eb537bf4560b3ad4df606c266c665624f3b502","versionType":"git"},{"lessThan":"9a5dd61151399ad5a5d69aad28ab164734c1e3bc","status":"affected","version":"c1eb537bf4560b3ad4df606c266c665624f3b502","versionType":"git"},{"status":"affected","version":"e78308a6dcab1e53b38b8dd952e69c515cd324d7","versionType":"git"},{"status":"affected","version":"2a0fc63f1f4fccfeb367d0c57b8a243cec60c26c","versionType":"git"}]},{"defaultStatus":"affected","product":"Linux","programFiles":["fs/smb/client/fs_context.c"],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","vendor":"Linux","versions":[{"status":"affected","version":"6.9"},{"lessThan":"6.9","status":"unaffected","version":"0","versionType":"semver"},{"lessThanOrEqual":"6.6.*","status":"unaffected","version":"6.6.59","versionType":"semver"},{"lessThanOrEqual":"6.11.*","status":"unaffected","version":"6.11.6","versionType":"semver"},{"lessThanOrEqual":"*","status":"unaffected","version":"6.12","versionType":"original_commit_for_fix"}]}],"cpeApplicability":[{"nodes":[{"cpeMatch":[{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"6.6.59","versionStartIncluding":"6.6.24","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"6.11.6","versionStartIncluding":"6.9","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"6.12","versionStartIncluding":"6.9","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.7.12","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.8.3","vulnerable":true}],"negate":false,"operator":"OR"}]}],"descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nsmb: client: Handle kstrdup failures for passwords\n\nIn smb3_reconfigure(), after duplicating ctx->password and\nctx->password2 with kstrdup(), we need to check for allocation\nfailures.\n\nIf ses->password allocation fails, return -ENOMEM.\nIf ses->password2 allocation fails, free ses->password, set it\nto NULL, and return -ENOMEM."}],"providerMetadata":{"dateUpdated":"2025-05-04T12:59:34.110Z","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","shortName":"Linux"},"references":[{"url":"https://git.kernel.org/stable/c/35dbac8c328d6afe937cd45ecd41d209d0b9f8b8"},{"url":"https://git.kernel.org/stable/c/35488799b0ab6e4327f82e1d9209a60805665b37"},{"url":"https://git.kernel.org/stable/c/9a5dd61151399ad5a5d69aad28ab164734c1e3bc"}],"title":"smb: client: Handle kstrdup failures for passwords","x_generator":{"engine":"bippy-1.2.0"}}},"cveMetadata":{"assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","assignerShortName":"Linux","cveId":"CVE-2024-50120","datePublished":"2024-11-05T17:10:49.887Z","dateReserved":"2024-10-21T19:36:19.953Z","dateUpdated":"2025-05-04T12:59:34.110Z","state":"PUBLISHED"},"dataType":"CVE_RECORD","dataVersion":"5.1"},"nvd":{"publishedDate":"2024-11-05 18:15:15","lastModifiedDate":"2026-04-06 14:01:16","problem_types":["NVD-CWE-noinfo"],"metrics":{"cvssMetricV31":[{"source":"nvd@nist.gov","type":"Primary","cvssData":{"version":"3.1","vectorString":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","baseScore":5.5,"baseSeverity":"MEDIUM","attackVector":"LOCAL","attackComplexity":"LOW","privilegesRequired":"LOW","userInteraction":"NONE","scope":"UNCHANGED","confidentialityImpact":"NONE","integrityImpact":"NONE","availabilityImpact":"HIGH"},"exploitabilityScore":1.8,"impactScore":3.6}]},"configurations":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.6.24","versionEndExcluding":"6.6.59","matchCriteriaId":"4C017B9E-32C1-4A6A-8332-9D815CADA68C"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.7.12","versionEndExcluding":"6.8","matchCriteriaId":"D6A2C3EC-DA7B-4144-8BAF-2DBB7E8CE4C7"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.8.3","versionEndExcluding":"6.11.6","matchCriteriaId":"169D202A-BA55-469F-9AA4-F2622323550C"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:6.12:rc1:*:*:*:*:*:*","matchCriteriaId":"7F361E1D-580F-4A2D-A509-7615F73167A1"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:6.12:rc2:*:*:*:*:*:*","matchCriteriaId":"925478D0-3E3D-4E6F-ACD5-09F28D5DF82C"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:6.12:rc3:*:*:*:*:*:*","matchCriteriaId":"3C95E234-D335-4B6C-96BF-E2CEBD8654ED"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:6.12:rc4:*:*:*:*:*:*","matchCriteriaId":"E0F717D8-3014-4F84-8086-0124B2111379"}]}]}]},"legacy_mitre":{"record":{"CveYear":"2024","CveId":"50120","Ordinal":"1","Title":"smb: client: Handle kstrdup failures for passwords","CVE":"CVE-2024-50120","Year":"2024"},"notes":[{"CveYear":"2024","CveId":"50120","Ordinal":"1","NoteData":"In the Linux kernel, the following vulnerability has been resolved:\n\nsmb: client: Handle kstrdup failures for passwords\n\nIn smb3_reconfigure(), after duplicating ctx->password and\nctx->password2 with kstrdup(), we need to check for allocation\nfailures.\n\nIf ses->password allocation fails, return -ENOMEM.\nIf ses->password2 allocation fails, free ses->password, set it\nto NULL, and return -ENOMEM.","Type":"Description","Title":"smb: client: Handle kstrdup failures for passwords"}]}}}