Attempting to load a shared protected workbook fails with ValueError: Value does not match pattern [0-9a-fA-F]+$
*Created originally on Bitbucket by [jraber (Jeff Raber)](https://bitbucket.org/%7B1ef39c86-50ce-441f-94e2-cc96683761e1%7D/)*
When attempting to load a workbook that is shared and protected with a password required to get read-write access, the below error occurs.
>>> openpyxl.load_workbook('./test.xlsm')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/python3.7/site-packages/openpyxl/reader/excel.py", line 188, in load_workbook
parser.parse()
File "/usr/lib/python3.7/site-packages/openpyxl/packaging/workbook.py", line 53, in parse
package = WorkbookPackage.from_tree(node)
File "/usr/lib/python3.7/site-packages/openpyxl/descriptors/serialisable.py", line 84, in from_tree
obj = desc.expected_type.from_tree(el)
File "/usr/lib/python3.7/site-packages/openpyxl/descriptors/serialisable.py", line 100, in from_tree
return cls(**attrib)
File "/usr/lib/python3.7/site-packages/openpyxl/workbook/protection.py", line 162, in __init__
self.hashValue = hashValue
File "/usr/lib/python3.7/site-packages/openpyxl/descriptors/base.py", line 255, in __set__
raise ValueError('Value does not match pattern {0}'.format(self.pattern))
ValueError: Value does not match pattern [0-9a-fA-F]+$
Inspecting the /xl/workbook.xml file (inside the XLSM/zip) shows that the hashValue and saltValue are not Hexadecimal as indicated in /openpyxl/workbook/protection.py.
Changing the types of FileSharing.hashValue and FileSharing.saltValue to String resolves this issue for me.
*Attachments:* [openpyxl.workbook.protection.diff](/uploads/7e45ba2d84ba1736767956f3019c5bd1/openpyxl.workbook.protection.diff)[openpyxl.workbook.protection-test.export](/uploads/49cf9b8e951ae3be6c00dc5941d5761b/openpyxl.workbook.protection-test.export)[openpyxl.workbook.protection-fix.export](/uploads/61c145b2572abcdcea8b2babce2b1b93/openpyxl.workbook.protection-fix.export)[Issue_1157_Example.xlsx](/uploads/229767c931f4bd5df629cbc7c6be8bf8/Issue_1157_Example.xlsx)
issue