bz2.BZ2Decompressor objects could be reused after a decompression error. If an application caught the resulting OSError and retried with the same decompressor, crafted input could cause the decompressor to resume from an invalid internal state and perform out-of-bounds writes to a stack buffer. This could crash the process when processing untrusted data.
{
"cwe_ids": []
}[
{
"id": "PSF-2026-27-43d1a68c",
"signature_version": "v1",
"target": {
"file": "Modules/_bz2module.c"
},
"signature_type": "Line",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/d3ca26983dfbccdf609f24ff5877dc3118e4702d",
"digest": {
"threshold": 0.9,
"line_hashes": [
"230549807586347801882752565727751527393",
"259826515629445840524055930255270819569",
"61884081560884315263548559216161355479",
"79711694314862108340541197613207575946",
"171752414468768194608689478864728584766",
"244896825634063513341487830919391053623",
"270116362062481798266002745410761144483",
"135851173470804331812991044096892707406",
"187850330169432792462433470324067099149",
"46264331593371765365053503316412057156",
"287546421518025134782360525923429325649",
"144711800226151315620070234557395546186",
"139742599704273432116709087783106689796",
"303706301689659795029483786708038468343",
"260603280173778536467919405606800329863",
"37282471943017895370075327536954715750",
"329688701832568305911903580974753306128",
"169032784915282225376038835778399062686",
"222725239250192608948367063362424983213",
"129741306537458160456606408761404801673"
]
}
},
{
"id": "PSF-2026-27-583d2510",
"signature_version": "v1",
"target": {
"file": "Modules/_bz2module.c",
"function": "_bz2_BZ2Decompressor_decompress_impl"
},
"signature_type": "Function",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/619a12b2e545391dc436b3af79dda22337382a6f",
"digest": {
"length": 305.0,
"function_hash": "237157038820676258852447556561399486795"
}
},
{
"id": "PSF-2026-27-5a90cf92",
"signature_version": "v1",
"target": {
"file": "Modules/_bz2module.c",
"function": "decompress_buf"
},
"signature_type": "Function",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/619a12b2e545391dc436b3af79dda22337382a6f",
"digest": {
"length": 967.0,
"function_hash": "12475210129250170784485077059971131042"
}
},
{
"id": "PSF-2026-27-64edab57",
"signature_version": "v1",
"target": {
"file": "Modules/_bz2module.c",
"function": "_bz2_BZ2Decompressor_decompress_impl"
},
"signature_type": "Function",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/5755d0f083949ff3c5bf3a37e673e24e306b036e",
"digest": {
"length": 327.0,
"function_hash": "324494633129969884664463818217685591182"
}
},
{
"id": "PSF-2026-27-74a63175",
"signature_version": "v1",
"target": {
"file": "Modules/_bz2module.c",
"function": "decompress_buf"
},
"signature_type": "Function",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/157a5df8cb5d82b33f918a7489e72ce95ceb12b6",
"digest": {
"length": 967.0,
"function_hash": "12475210129250170784485077059971131042"
}
},
{
"id": "PSF-2026-27-767a64d1",
"signature_version": "v1",
"target": {
"file": "Modules/_bz2module.c"
},
"signature_type": "Line",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/619a12b2e545391dc436b3af79dda22337382a6f",
"digest": {
"threshold": 0.9,
"line_hashes": [
"230549807586347801882752565727751527393",
"259826515629445840524055930255270819569",
"61884081560884315263548559216161355479",
"79711694314862108340541197613207575946",
"171752414468768194608689478864728584766",
"244896825634063513341487830919391053623",
"270116362062481798266002745410761144483",
"301458273768679745851477136163384738787",
"326679068747380593195372742629785605814",
"63860159810743592708049383519597402068",
"227962660283150036829664603411509087708",
"65322514126625934999787331933915003546",
"139742599704273432116709087783106689796",
"153074271145615424374466652844640026183",
"50516197816847867676426154913464944742",
"244810537808551927082172479326136103730",
"171848629098389974293193736390253590171",
"284304586435141485197444375467611256436",
"209901103058700644331660527939509813016"
]
}
},
{
"signature_version": "v1",
"id": "PSF-2026-27-83b70eb1",
"target": {
"file": "Modules/_bz2module.c",
"function": "_bz2_BZ2Decompressor_decompress_impl"
},
"signature_type": "Function",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/d3ca26983dfbccdf609f24ff5877dc3118e4702d",
"digest": {
"length": 327.0,
"function_hash": "324494633129969884664463818217685591182"
}
},
{
"id": "PSF-2026-27-88372235",
"signature_version": "v1",
"target": {
"file": "Modules/_bz2module.c",
"function": "decompress_buf"
},
"signature_type": "Function",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/d3ca26983dfbccdf609f24ff5877dc3118e4702d",
"digest": {
"length": 982.0,
"function_hash": "290164687798376905522712649084948442447"
}
},
{
"id": "PSF-2026-27-97b4386a",
"signature_version": "v1",
"target": {
"file": "Modules/_bz2module.c",
"function": "decompress_buf"
},
"signature_type": "Function",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/5755d0f083949ff3c5bf3a37e673e24e306b036e",
"digest": {
"length": 982.0,
"function_hash": "290164687798376905522712649084948442447"
}
},
{
"id": "PSF-2026-27-a77dd4db",
"signature_version": "v1",
"target": {
"file": "Modules/_bz2module.c",
"function": "_bz2_BZ2Decompressor_impl"
},
"signature_type": "Function",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/619a12b2e545391dc436b3af79dda22337382a6f",
"digest": {
"length": 725.0,
"function_hash": "43861071656797244308731160845717430801"
}
},
{
"id": "PSF-2026-27-a7eb6970",
"signature_version": "v1",
"target": {
"file": "Modules/_bz2module.c",
"function": "_bz2_BZ2Decompressor_decompress_impl"
},
"signature_type": "Function",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/157a5df8cb5d82b33f918a7489e72ce95ceb12b6",
"digest": {
"length": 305.0,
"function_hash": "237157038820676258852447556561399486795"
}
},
{
"id": "PSF-2026-27-bae64abe",
"signature_version": "v1",
"target": {
"file": "Modules/_bz2module.c",
"function": "_bz2_BZ2Decompressor_impl"
},
"signature_type": "Function",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/157a5df8cb5d82b33f918a7489e72ce95ceb12b6",
"digest": {
"length": 725.0,
"function_hash": "43861071656797244308731160845717430801"
}
},
{
"signature_version": "v1",
"id": "PSF-2026-27-cffcb8eb",
"target": {
"file": "Modules/_bz2module.c"
},
"signature_type": "Line",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/157a5df8cb5d82b33f918a7489e72ce95ceb12b6",
"digest": {
"threshold": 0.9,
"line_hashes": [
"230549807586347801882752565727751527393",
"259826515629445840524055930255270819569",
"61884081560884315263548559216161355479",
"79711694314862108340541197613207575946",
"171752414468768194608689478864728584766",
"244896825634063513341487830919391053623",
"270116362062481798266002745410761144483",
"301458273768679745851477136163384738787",
"326679068747380593195372742629785605814",
"63860159810743592708049383519597402068",
"227962660283150036829664603411509087708",
"65322514126625934999787331933915003546",
"139742599704273432116709087783106689796",
"153074271145615424374466652844640026183",
"50516197816847867676426154913464944742",
"244810537808551927082172479326136103730",
"171848629098389974293193736390253590171",
"284304586435141485197444375467611256436",
"209901103058700644331660527939509813016"
]
}
},
{
"id": "PSF-2026-27-dd9baae2",
"signature_version": "v1",
"target": {
"file": "Modules/_bz2module.c",
"function": "_bz2_BZ2Decompressor_impl"
},
"signature_type": "Function",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/5755d0f083949ff3c5bf3a37e673e24e306b036e",
"digest": {
"length": 574.0,
"function_hash": "211737575122334054247505236780163694353"
}
},
{
"id": "PSF-2026-27-e79b54c8",
"signature_version": "v1",
"target": {
"file": "Modules/_bz2module.c",
"function": "_bz2_BZ2Decompressor_impl"
},
"signature_type": "Function",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/d3ca26983dfbccdf609f24ff5877dc3118e4702d",
"digest": {
"length": 574.0,
"function_hash": "211737575122334054247505236780163694353"
}
},
{
"id": "PSF-2026-27-febb9baa",
"signature_version": "v1",
"target": {
"file": "Modules/_bz2module.c"
},
"signature_type": "Line",
"deprecated": false,
"source": "https://github.com/python/cpython/commit/5755d0f083949ff3c5bf3a37e673e24e306b036e",
"digest": {
"threshold": 0.9,
"line_hashes": [
"230549807586347801882752565727751527393",
"259826515629445840524055930255270819569",
"61884081560884315263548559216161355479",
"79711694314862108340541197613207575946",
"171752414468768194608689478864728584766",
"244896825634063513341487830919391053623",
"270116362062481798266002745410761144483",
"135851173470804331812991044096892707406",
"187850330169432792462433470324067099149",
"46264331593371765365053503316412057156",
"287546421518025134782360525923429325649",
"144711800226151315620070234557395546186",
"139742599704273432116709087783106689796",
"303706301689659795029483786708038468343",
"260603280173778536467919405606800329863",
"37282471943017895370075327536954715750",
"329688701832568305911903580974753306128",
"169032784915282225376038835778399062686",
"222725239250192608948367063362424983213",
"129741306537458160456606408761404801673"
]
}
}
]
"https://github.com/psf/advisory-database/blob/main/advisories/python/PSF-2026-27.json"
"2026-06-11T02:04:24Z"