package/source/zipapi/ZipFile.cxx |    1 +
 1 file changed, 1 insertion(+)

New commits:
commit 92356a92bcc3c0f5d4cc02cd8e166b12698fa76f
Author:     Caolán McNamara <[email protected]>
AuthorDate: Sun Mar 1 13:04:15 2026 +0000
Commit:     Xisco Fauli <[email protected]>
CommitDate: Thu Mar 5 12:02:44 2026 +0100

    ofz#488752793 Integer-overflow
    
    possibly since:
    
    commit d7ad4553f4ec2a6117f5e6455d6325454c34464e
    Date:   Fri Jul 19 20:43:05 2024 +0200
    
        package: ZipFile: check Zip64 end of central directory for consistency
    
    Change-Id: I4bcaaf10be63aa5068b6c801ff1b8a2455dfc63c
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/200708
    Reviewed-by: Xisco Fauli <[email protected]>
    Tested-by: Jenkins

diff --git a/package/source/zipapi/ZipFile.cxx 
b/package/source/zipapi/ZipFile.cxx
index 5e903627d763..62c1efb7a7a3 100644
--- a/package/source/zipapi/ZipFile.cxx
+++ b/package/source/zipapi/ZipFile.cxx
@@ -1294,6 +1294,7 @@ std::tuple<sal_Int64, sal_Int64, sal_Int64> 
ZipFile::findCentralDirectory()
                 if (o3tl::checked_add<sal_Int64>(nEnd64DirOffset, 
nEnd64DirSize, end)
                     || nLoc64End64Offset < end
                     || nEnd64DirOffset < 0
+                    || nEnd64DirSize < 0
                     || nLoc64End64Offset - nEnd64DirSize != nEnd64DirOffset)
                 {
                     throw ZipException(u"Invalid Zip64 end (bad central 
directory size)"_ustr);

Reply via email to