2 ms·
The container used for OOXML documents is the Open Packaging Conventions format, which is well-specified. It has a .NET library: https://learn.microsoft.com/en
by jiggawatts 3y ago
The container used for OOXML documents is the Open Packaging Conventions format, which is well-specified.
It has a .NET library: https://learn.microsoft.com/en-us/dotnet/api/system.io.packaging https://learn.microsoft.com/en-us/dotnet/api/system.io.packa...
An ECMA standard: https://www.ecma-international.org/publications-and-standards/standards/ecma-376/ https://www.ecma-international.org/publications-and-standard...
Etc...
This is pretty convenient for writing utilities to parse MS Office documents correctly on platforms such as Windows Server Core or Linux, where the actual Office applications are not installed.
Care must be taken because the format isn't "just" XML in a Zip container. Large documents can be fragmented and interleaved..
What's sad is that the format is 90% of the way there to a really good generic document container format. It solves many common problems, such as streaming decode and incremental saving. It also "solves" signing, but as we can all see, 90% secure is 100% insecure.
A modern version would be akin to the Docker container format: JSON metadata inside a gzip file referencing binary blobs with relative paths and SHA signatures.