{"id":"CVE-2026-40528","aliases":["CVE-2026-40528"],"related":[],"kind":"vulnerability","state":"published","title":"OpenSC < 0.27.0 Buffer Overrun in do_key_value() via profile.c","summary":"OpenSC before 0.27.0, fixed in commit 0358817, contains a stack and heap buffer overrun vulnerability in the do_key_value() function in src/pkcs15init/profile.c that allows attackers to corrupt memory by supplying a crafted profile configuration file. During pkcs15-init invocation, a key value entry beginning with '=' followed by more than sizeof(keybuf) characters is copied into keybuf via memcpy without a length check, causing both stack and heap buffer overruns.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"OpenSC before 0.27.0, fixed in commit 0358817, contains a stack and heap buffer overrun vulnerability in the do_key_value() function in src/pkcs15init/profile.c that allows attackers to corrupt memory by supplying a crafted profile configuration file. During pkcs15-init invocation, a key value entry beginning with '=' followed by more than sizeof(keybuf) characters is copied into keybuf via memcpy without a length check, causing both stack and heap buffer overruns.","source":"cvelist"},{"lang":"es","text":"OpenSC antes de 0.27.0, corregido en el commit 0358817, contiene una vulnerabilidad de desbordamiento de búfer de pila y de montón en la función do_key_value() en src/pkcs15init/profile.c que permite a los atacantes corromper la memoria al proporcionar un archivo de configuración de perfil manipulado. Durante la invocación de pkcs15-init, una entrada de valor de clave que comienza con '=' seguida de más de sizeof(keybuf) caracteres se copia en keybuf a través de memcpy sin una verificación de longitud, causando desbordamientos de búfer tanto de pila como de montón.","source":"nvd"}],"published":"2026-05-29T13:38:11.831Z","modified":"2026-07-21T12:10:00.090Z","severity":{"scorer":"VulnCheck","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:P/AC:H/AT:N/PR:N/UI:P/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N","score":1,"rating":"LOW"},"severities":[{"scorer":"VulnCheck","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:P/AC:H/AT:N/PR:N/UI:P/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N","score":1,"rating":"LOW"},{"scorer":"VulnCheck","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:P/AC:H/PR:N/UI:R/S:U/C:L/I:L/A:L","score":3.8,"rating":"LOW"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"}],"cwes":["CWE-121","CWE-122"],"affected":[{"ranges":[{"type":"semver","introduced":"0","fixed":"0.27.0","status":"affected"},{"type":"git","introduced":"0","fixed":"0358817ec74aeca654f83e7709c7720b14c5db59","status":"affected"}],"vendor":"OpenSC","product":"OpenSC","repo":"https://github.com/OpenSC/OpenSC","source":"cvelist"},{"ranges":[{"status":"affected","fixed":"0.27.0"}],"vendor":"opensc_project","product":"opensc","cpe":"cpe:2.3:a:opensc_project:opensc:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://github.com/OpenSC/OpenSC/commit/0358817ec74aeca654f83e7709c7720b14c5db59","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://www.vulncheck.com/advisories/opensc-buffer-overrun-in-do-key-value-via-profile-c","tags":["third-party-advisory"],"sources":["cvelist","nvd"]}],"credits":["Nicholas Carlini of Anthropic"],"assigner":"VulnCheck","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2026-05-29T13:58:10.279Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-40528","url":"https://www.cve.org/CVERecord?id=CVE-2026-40528","licence":"CVE Terms of Use","modified":"2026-07-14T20:00:40.951Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-40528","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-40528","licence":"Public domain","modified":"2026-07-21T12:10:00.090Z"}],"updatedAt":"2026-11-25T22:59:23.311Z","epss":{"score":0.00188,"percentile":0.08772,"date":"2026-12-01T12:00:22.000Z"}}