PSPDFSignatureValidator

Objective-C


@interface PSPDFSignatureValidator : NSObject

Swift

class PDFSignatureValidator : NSObject

This class validates digital signatures in a PDF document. Validation consists of two steps: Checking that the signature integrity is correct (that is, the document was not modified after it was signed), and ensuring that the chain of certificates contained in the signature is trusted.

  • Unavailable

    Not the designated initializer

    Undocumented

    Declaration

    Objective-C

    PSPDF_EMPTY_INIT_UNAVAILABLE
  • Unavailable

    Not the designated initializer

    Undocumented

    Declaration

    Objective-C

    PSPDF_EMPTY_INIT_UNAVAILABLE
  • Initializes a PSPDFSignatureValidator with a signature form element. If formElement is nil, nil will be returned.

    Declaration

    Objective-C

    - (nonnull instancetype)initWithSignatureFormElement:
        (nonnull PSPDFSignatureFormElement *)formElement;
  • The signature form element.

    Declaration

    Objective-C

    @property (nonatomic, readonly) PSPDFSignatureFormElement *_Nonnull signatureFormElement;

    Swift

    var signatureFormElement: PSPDFSignatureFormElement { get }
  • Starts the digital signature verification process. If trustedCertificates is nil, the default from the shared signature manager is used.

    For convenience, the Adobe CA is implicitly included as part of the trustedCertificates list, so you don’t have to add it yourself.

    Declaration

    Objective-C

    - (nullable PSPDFSignatureStatus *)
        verifySignatureWithTrustedCertificates:
            (nullable NSArray<PSPDFX509 *> *)trustedCertificates
                                         error:(NSError *_Nullable *_Nullable)error;

    Swift

    func verifySignature(withTrustedCertificates trustedCertificates: [PSPDFX509]?) throws -> PSPDFSignatureStatus

    Return Value

    nil if signature not found.