Table of Contents

Class PackageSignatureVerifier

Namespace
DocWright.Signatures
Assembly
DocWright.Signatures.dll

Verifies the digital signatures in an OPC package (a .docx and every other Open Packaging Conventions file), reporting the outcome for each signed part individually.

public static class PackageSignatureVerifier
Inheritance
PackageSignatureVerifier
Inherited Members

Remarks

What verification answers. "Do these bytes match what was signed, with this certificate?" — and nothing else. It does not build a certificate chain, check revocation, consult a trust store or decide whether the signer should be believed. Those are the host's decisions and this package does not make them; the signer's certificate is handed back on SignerCertificate so the host can. See COMPAT.md.

Where signatures live. The OPC default is /package/services/digital-signature/; Microsoft Office writes the same structures to /_xmlsignatures/. Neither path is hard-coded — the origin part is found by following the package-level relationship whose type is .../digital-signature/origin, which is what both layouts have in common, and the signature parts are found by following .../digital-signature/signature from there.

Methods

Verify(Stream)

Verifies every digital signature in the package read from package.