Quantcast
Channel: .NET Framework Class Libraries forum
Viewing all articles
Browse latest Browse all 8156

ZipArchive Corrupts Signed OOXML Files

$
0
0

Hi,

If i pass a path to a signed ooxml (office 2007 and up) file, after running the code below - office shows that the file is corrupt.

using (FileStream stream = File.Open(filePath, FileMode.Open, FileAccess.ReadWrite, FileShare.Read))
{
using (ZipArchive zip = new ZipArchive(stream, ZipArchiveMode.Update))
{
}
}

Looking at the file, i have found that it changes the 'Version Made By' in the Central Directory File Header.

Is there any way to control it?


Viewing all articles
Browse latest Browse all 8156

Trending Articles