Created attachment 33285 [details] Test class and sample files Hello, we have an Excel workbook (XLSX) which we would like to read and modify. In the end we would like to sign it. Unfortunately we get an NullPointerException while signing, when we have deleted the first sheet before: java.lang.NullPointerException at org.apache.poi.poifs.crypt.dsig.facets.OOXMLSignatureFacet.addManifestReferences(OOXMLSignatureFacet.java:164) at org.apache.poi.poifs.crypt.dsig.facets.OOXMLSignatureFacet.addManifestObject(OOXMLSignatureFacet.java:100) at org.apache.poi.poifs.crypt.dsig.facets.OOXMLSignatureFacet.preSign(OOXMLSignatureFacet.java:89) at org.apache.poi.poifs.crypt.dsig.SignatureInfo.preSign(SignatureInfo.java:472) at org.apache.poi.poifs.crypt.dsig.SignatureInfo.confirmSignature(SignatureInfo.java:315) Please note that this problem does not occur when we delete another sheet instead. Please find attached a test class and sample files. Thanks and best regards Constantin
Thank you for providing a good test and example file - this made things easy for me. Patched with r1715438 I've tried to recreate the error by creating a file from scratch and save/reloading it, but this didn't triggered the reference path error. I've only spent little time to compare the output of the scratch file to your template.xlsx - on a quick view they look quite similar ... I guess you are happy when the signing works :) Andi
Hi! Thank you very much! Signing is working right now! Best regards Constantin