Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Office Open XML (OOXML) Specification: Encryption

I am trying to understand how encrypted ("password protected") Office 2007 documents are bundled (specifically, Excel documents). I am experimenting with a known, password protected spread sheet.

When I unzip the XLSX file, I encounter three entries:

  • [6]DataSpaces (Directory)
  • EncryptionInfo (File)
  • EncryptedPackage (File)

How is the EncryptedPackage file encrypted (which cipher, which key derivation function, etc...)?

I have tried referencing the documentation, but I haven't had much success.

like image 474
Adam Paynter Avatar asked May 13 '09 14:05

Adam Paynter


People also ask

What is Microsoft OOXML?

Office Open XML (also informally known as OOXML) is a zipped, XML-based file format developed by Microsoft for representing spreadsheets, charts, presentations and word processing documents. Ecma International standardized the initial version as ECMA-376. ISO and IEC standardized later versions as ISO/IEC 29500.

Are DOCX files encrypted?

docx file) is protected with a password for reading, it is encrypted. The encrypted OOXML file is stored inside a Compound File Binary Format file, or what I like to call an OLE file. This is the “old” MS Office file format (like . doc), the default file format used before MS Office 2007.

How do I open an XML file with Open Office?

#1) Open Windows Explorer and browse to the location where the XML file is located. We have browsed to the location of our XML file MySampleXML as seen below. #2) Now right-click over the file and select Open With to choose Notepad or Microsoft Office Word from the list of options available to open the XML file.

What is OpenXML C#?

OpenXML is also known as OOXML and it fully XML-based format for office documents, including word processing documents, spreadsheets, presentations, as well as charts, diagrams, shapes, and other graphical material.


1 Answers

File encryption is not part of the OpenXML ECMA/ISO specifications. It's a vendor-specific standard on top of that. For the specification please check out

[MS-OFFCRYPTO]: Office Document Cryptography Structure Specification

Encrypted OpenXML documents are not stored as an OPC zip package but as an encrypted OPC package inside a compound OLE document.

like image 114
Dirk Vollmar Avatar answered Sep 29 '22 23:09

Dirk Vollmar