Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
c0b7037d
Kaydet (Commit)
c0b7037d
authored
Eyl 27, 2016
tarafından
Serhiy Storchaka
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Issue #28275: Fixed possible use adter free in LZMADecompressor.decompress().
Original patch by John Leitch.
üst
f18a5daa
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
1 deletion
+15
-1
test_lzma.py
Lib/test/test_lzma.py
+9
-0
NEWS
Misc/NEWS
+3
-0
_lzmamodule.c
Modules/_lzmamodule.c
+3
-1
No files found.
Lib/test/test_lzma.py
Dosyayı görüntüle @
c0b7037d
...
@@ -246,6 +246,15 @@ class CompressorDecompressorTestCase(unittest.TestCase):
...
@@ -246,6 +246,15 @@ class CompressorDecompressorTestCase(unittest.TestCase):
lzd
=
LZMADecompressor
(
lzma
.
FORMAT_RAW
,
filters
=
FILTERS_RAW_1
)
lzd
=
LZMADecompressor
(
lzma
.
FORMAT_RAW
,
filters
=
FILTERS_RAW_1
)
self
.
assertRaises
(
LZMAError
,
lzd
.
decompress
,
COMPRESSED_XZ
)
self
.
assertRaises
(
LZMAError
,
lzd
.
decompress
,
COMPRESSED_XZ
)
def
test_decompressor_bug_28275
(
self
):
# Test coverage for Issue 28275
lzd
=
LZMADecompressor
()
for
i
in
range
(
2
):
try
:
lzd
.
decompress
(
COMPRESSED_RAW_1
)
except
LZMAError
:
pass
# Test that LZMACompressor->LZMADecompressor preserves the input data.
# Test that LZMACompressor->LZMADecompressor preserves the input data.
def
test_roundtrip_xz
(
self
):
def
test_roundtrip_xz
(
self
):
...
...
Misc/NEWS
Dosyayı görüntüle @
c0b7037d
...
@@ -80,6 +80,9 @@ Core and Builtins
...
@@ -80,6 +80,9 @@ Core and Builtins
Library
Library
-------
-------
- Issue #28275: Fixed possible use adter free in LZMADecompressor.decompress().
Original patch by John Leitch.
- Issue #27897: Fixed possible crash in sqlite3.Connection.create_collation()
- Issue #27897: Fixed possible crash in sqlite3.Connection.create_collation()
if pass invalid string-like object as a name. Patch by Xiang Zhang.
if pass invalid string-like object as a name. Patch by Xiang Zhang.
...
...
Modules/_lzmamodule.c
Dosyayı görüntüle @
c0b7037d
...
@@ -1005,8 +1005,10 @@ decompress(Decompressor *d, uint8_t *data, size_t len, Py_ssize_t max_length)
...
@@ -1005,8 +1005,10 @@ decompress(Decompressor *d, uint8_t *data, size_t len, Py_ssize_t max_length)
}
}
result
=
decompress_buf
(
d
,
max_length
);
result
=
decompress_buf
(
d
,
max_length
);
if
(
result
==
NULL
)
if
(
result
==
NULL
)
{
lzs
->
next_in
=
NULL
;
return
NULL
;
return
NULL
;
}
if
(
d
->
eof
)
{
if
(
d
->
eof
)
{
d
->
needs_input
=
0
;
d
->
needs_input
=
0
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment