org.apache.poi.poifs.crypt.dsig

## Class SignaturePart

- java.lang.Object
- - org.apache.poi.poifs.crypt.dsig.SignaturePart

-     public class SignaturePart
      extends java.lang.Object

- - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.util.List<java.security.cert.X509Certificate>` | `getCertChain()`
    `PackagePart` | `getPackagePart()`
    `org.w3.x2000.x09.xmldsig.SignatureDocument` | `getSignatureDocument()` Helper method for examining the xml signature
    `java.security.cert.X509Certificate` | `getSigner()`
    `boolean` | `validate()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Method Detail

    - #### getPackagePart

          public PackagePart getPackagePart()

      Returns:
        the package part containing the signature

    - #### getSigner

          public java.security.cert.X509Certificate getSigner()

      Returns:
        the signer certificate

    - #### getCertChain

          public java.util.List<java.security.cert.X509Certificate> getCertChain()

      Returns:
        the certificate chain of the signer

    - #### getSignatureDocument

          public org.w3.x2000.x09.xmldsig.SignatureDocument getSignatureDocument()
                                                                          throws java.io.IOException,
                                                                                 org.apache.xmlbeans.XmlException

      Helper method for examining the xml signature
      Returns:
        the xml signature document
      Throws:
        `java.io.IOException` - if the xml signature doesn't exist or can't be read
        `org.apache.xmlbeans.XmlException` - if the xml signature is malformed

    - #### validate

          public boolean validate()

      Returns:
        true, when the xml signature is valid, false otherwise
      Throws:
        `EncryptedDocumentException` - if the signature can't be extracted or if its malformed

Copyright 2020 The Apache Software Foundation or its licensors, as applicable.