ComPDFKit Web SDK
    Preparing search index...

    Interface VerificationResult

    Verification result of one signature (see SignatureVerificationData)

    interface VerificationResult {
        byteRange: [number, number, number, number] | null;
        certificateChain: VerificationCertificate[];
        changes: SignatureChangeData[];
        contactInfo: string;
        coversWholeDocument: boolean;
        digestAlgorithm: string | null;
        digestStatus:
            | "digest_verified"
            | "weak_digest_algorithm_but_digest_verifiable"
            | "digest_invalid"
            | "unsupported_encoding"
            | "no_digest_status";
        docMDPPermissions: 0
        | 1
        | 2
        | 3;
        documentStatus:
            | "no_error"
            | "unsigned"
            | "bad_byteranges"
            | "corrupt_cryptographic_contents";
        fieldName: string;
        location: string;
        pageIndex: number;
        permissionsStatus: | "unmodified"
        | "has_allowed_changes"
        | "invalidated_by_disallowed_changes"
        | "no_permissions_status";
        reason: string;
        revocation: {
            certificates: {
                revokedAt?: Date;
                source?: "ocsp"
                | "crl";
                status: "good" | "revoked" | "unknown";
                subject: string;
            }[];
            status: "good"
            | "revoked"
            | "unknown"
            | "not_checked";
        };
        signer: VerificationCertificate
        | null;
        signerName: string;
        signingTime: Date | null;
        signingTimeSource:
            | "timestamp"
            | "signed_attribute"
            | "signature_dictionary"
            | null;
        subFilter: string;
        timestamp: { time: Date; valid: boolean }
        | null;
        trustProblems: (
            | "revoked"
            | "no_trusted_root"
            | "incomplete_chain"
            | "expired"
            | "not_yet_valid"
        )[];
        trustStatus: "trust_verified"
        | "untrusted"
        | "no_trust_status";
        verificationStatus: boolean;
    }

    Hierarchy

    • Omit<
          SignatureVerificationData,
          "signingTime"
          | "timestamp"
          | "signer"
          | "certificateChain"
          | "revocation",
      >
      • VerificationResult
    Index
    byteRange: [number, number, number, number] | null

    The signature's ByteRange (offset and length of the two signed parts); null when missing.

    certificateChain: VerificationCertificate[]

    Certificate chain of the signer.

    changes: SignatureChangeData[]

    Objects changed after signing.

    contactInfo: string

    Signer contact information; empty when not given.

    coversWholeDocument: boolean

    The signature covers up to the end of the file (no revisions appended afterwards).

    digestAlgorithm: string | null

    Digest algorithm name; null when unknown.

    digestStatus:
        | "digest_verified"
        | "weak_digest_algorithm_but_digest_verifiable"
        | "digest_invalid"
        | "unsupported_encoding"
        | "no_digest_status"

    Result of checking the signed content against the signature value.

    docMDPPermissions: 0 | 1 | 2 | 3

    DocMDP P (1 no changes, 2 form filling and signing, 3 also annotations); 0 for ordinary (approval) signatures.

    documentStatus:
        | "no_error"
        | "unsigned"
        | "bad_byteranges"
        | "corrupt_cryptographic_contents"

    Result of checking the ByteRange and the signature container structure.

    fieldName: string

    Full name of the signature field.

    location: string

    Signing location; empty when not given.

    pageIndex: number

    Page index (0-based); -1 when not found.

    permissionsStatus:
        | "unmodified"
        | "has_allowed_changes"
        | "invalidated_by_disallowed_changes"
        | "no_permissions_status"

    Whether changes made after signing are allowed.

    reason: string

    Reason for signing; empty when not given.

    revocation: {
        certificates: {
            revokedAt?: Date;
            source?: "ocsp" | "crl";
            status: "good" | "revoked" | "unknown";
            subject: string;
        }[];
        status: "good"
        | "revoked"
        | "unknown"
        | "not_checked";
    }

    Offline revocation check result: overall status and the status of each certificate in the chain except the root.

    Type Declaration

    • certificates: {
          revokedAt?: Date;
          source?: "ocsp" | "crl";
          status: "good" | "revoked" | "unknown";
          subject: string;
      }[]

      Result for each certificate in the chain except the root.

    • status: "good" | "revoked" | "unknown" | "not_checked"

      Overall result: revoked if any certificate is revoked, good if all are valid, unknown if some cannot be checked, not_checked without data.

    Signer certificate; null when it cannot be read.

    signerName: string

    Name of the signer.

    signingTime: Date | null

    Signing time; null when there is none.

    signingTimeSource:
        | "timestamp"
        | "signed_attribute"
        | "signature_dictionary"
        | null

    Where signingTime came from: a timestamp token, a signed attribute or the signature dictionary; null when there is no signing time.

    subFilter: string

    Signature encoding (/SubFilter), such as a detached PKCS#7 signature.

    timestamp: { time: Date; valid: boolean } | null

    Timestamp token time and whether it is valid; null without a timestamp.

    Type Declaration

    • { time: Date; valid: boolean }
      • time: Date

        Time in the timestamp token.

      • valid: boolean

        Whether the timestamp token is valid.

    • null
    trustProblems: (
        | "revoked"
        | "no_trusted_root"
        | "incomplete_chain"
        | "expired"
        | "not_yet_valid"
    )[]

    Reasons the chain is not trusted; empty when trusted.

    trustStatus: "trust_verified" | "untrusted" | "no_trust_status"

    Whether the certificate chain reaches a trusted certificate and is within its validity period.

    verificationStatus: boolean

    Overall result: true when the signature is valid.