[regression] Poco::Zip::ZipArchive does not detect actual incorrect local file headers
I'm working on an application that uses Poco to unzip an archive. In testing my code to ensure I catch exceptions thrown from Poco::Zip::ZipArchive, I'm deliberately hacking a zip file to change the local file header signature to be something else and using that to unzip. However, in ZipArchive::parse(), this is not detected and just skipped as part of the ZipUtil::sync() call that was introduced in 19b168516c.
As further proof that 19b168516ce6 caused this regression, if I remove https://github.com/pocoproject/poco/blob/3fc3e5f5b8462f7666952b43381383a79b8b5d92/Zip/src/ZipArchive.cpp#L110, then I do get the exception if I "corrupt" the header signature.
This issue is stale because it has been open for 365 days with no activity.
This issue was closed because it has been inactive for 60 days since being marked as stale.
This issue was closed because it has been inactive for 60 days since being marked as stale.