pdf-lite 1.0.3 → 1.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -0
- package/dist/core/generators.d.ts +2 -2
- package/dist/core/generators.js +3 -3
- package/dist/core/incremental-parser.d.ts +1 -1
- package/dist/core/incremental-parser.js +1 -1
- package/dist/core/index.d.ts +48 -0
- package/dist/core/index.js +48 -0
- package/dist/core/objects/pdf-array.d.ts +3 -3
- package/dist/core/objects/pdf-array.js +4 -4
- package/dist/core/objects/pdf-boolean.d.ts +2 -2
- package/dist/core/objects/pdf-boolean.js +2 -2
- package/dist/core/objects/pdf-comment.d.ts +3 -3
- package/dist/core/objects/pdf-comment.js +4 -4
- package/dist/core/objects/pdf-date.d.ts +1 -1
- package/dist/core/objects/pdf-date.js +1 -1
- package/dist/core/objects/pdf-dictionary.d.ts +3 -3
- package/dist/core/objects/pdf-dictionary.js +5 -5
- package/dist/core/objects/pdf-hexadecimal.d.ts +3 -3
- package/dist/core/objects/pdf-hexadecimal.js +6 -6
- package/dist/core/objects/pdf-indirect-object.d.ts +5 -5
- package/dist/core/objects/pdf-indirect-object.js +9 -9
- package/dist/core/objects/pdf-name.d.ts +2 -2
- package/dist/core/objects/pdf-name.js +2 -2
- package/dist/core/objects/pdf-null.d.ts +2 -2
- package/dist/core/objects/pdf-null.js +2 -2
- package/dist/core/objects/pdf-number.d.ts +3 -3
- package/dist/core/objects/pdf-number.js +3 -3
- package/dist/core/objects/pdf-object-reference.d.ts +2 -2
- package/dist/core/objects/pdf-object-reference.js +2 -2
- package/dist/core/objects/pdf-start-xref.d.ts +4 -4
- package/dist/core/objects/pdf-start-xref.js +4 -4
- package/dist/core/objects/pdf-stream.d.ts +8 -8
- package/dist/core/objects/pdf-stream.js +19 -19
- package/dist/core/objects/pdf-string.d.ts +3 -3
- package/dist/core/objects/pdf-string.js +4 -4
- package/dist/core/objects/pdf-trailer.d.ts +8 -8
- package/dist/core/objects/pdf-trailer.js +6 -6
- package/dist/core/objects/pdf-xref-table.d.ts +7 -7
- package/dist/core/objects/pdf-xref-table.js +8 -8
- package/dist/core/serializer.d.ts +3 -3
- package/dist/core/serializer.js +2 -2
- package/dist/core/streams/object-stream.d.ts +3 -3
- package/dist/core/streams/object-stream.js +2 -2
- package/dist/core/tokens/boolean-token.d.ts +1 -1
- package/dist/core/tokens/boolean-token.js +1 -1
- package/dist/core/tokens/byte-offset-token.d.ts +2 -2
- package/dist/core/tokens/byte-offset-token.js +2 -2
- package/dist/core/tokens/comment-token.d.ts +2 -2
- package/dist/core/tokens/comment-token.js +4 -4
- package/dist/core/tokens/end-array-token.d.ts +1 -1
- package/dist/core/tokens/end-array-token.js +2 -2
- package/dist/core/tokens/end-dictionary-token.d.ts +1 -1
- package/dist/core/tokens/end-dictionary-token.js +2 -2
- package/dist/core/tokens/end-object-token.d.ts +1 -1
- package/dist/core/tokens/end-object-token.js +2 -2
- package/dist/core/tokens/end-stream-token.d.ts +2 -2
- package/dist/core/tokens/end-stream-token.js +2 -2
- package/dist/core/tokens/hexadecimal-token.d.ts +2 -2
- package/dist/core/tokens/hexadecimal-token.js +2 -2
- package/dist/core/tokens/name-token.d.ts +1 -1
- package/dist/core/tokens/name-token.js +2 -2
- package/dist/core/tokens/null-token.d.ts +1 -1
- package/dist/core/tokens/null-token.js +2 -2
- package/dist/core/tokens/number-token.d.ts +3 -3
- package/dist/core/tokens/number-token.js +3 -3
- package/dist/core/tokens/object-reference-token.d.ts +1 -1
- package/dist/core/tokens/object-reference-token.js +2 -2
- package/dist/core/tokens/start-array-token.d.ts +1 -1
- package/dist/core/tokens/start-array-token.js +2 -2
- package/dist/core/tokens/start-dictionary-token.d.ts +1 -1
- package/dist/core/tokens/start-dictionary-token.js +2 -2
- package/dist/core/tokens/start-object-token.d.ts +1 -1
- package/dist/core/tokens/start-object-token.js +2 -2
- package/dist/core/tokens/start-stream-token.d.ts +3 -3
- package/dist/core/tokens/start-stream-token.js +3 -3
- package/dist/core/tokens/start-xref-token.d.ts +1 -1
- package/dist/core/tokens/start-xref-token.js +2 -2
- package/dist/core/tokens/stream-chunk-token.d.ts +2 -2
- package/dist/core/tokens/stream-chunk-token.js +1 -1
- package/dist/core/tokens/string-token.d.ts +2 -2
- package/dist/core/tokens/string-token.js +3 -3
- package/dist/core/tokens/token.d.ts +1 -1
- package/dist/core/tokens/token.js +1 -1
- package/dist/core/tokens/trailer-token.d.ts +1 -1
- package/dist/core/tokens/trailer-token.js +2 -2
- package/dist/core/tokens/whitespace-token.d.ts +2 -2
- package/dist/core/tokens/whitespace-token.js +1 -1
- package/dist/core/tokens/xref-table-entry-token.d.ts +3 -3
- package/dist/core/tokens/xref-table-entry-token.js +2 -2
- package/dist/core/tokens/xref-table-section-start-token.d.ts +2 -2
- package/dist/core/tokens/xref-table-section-start-token.js +3 -3
- package/dist/core/tokens/xref-table-start-token.d.ts +1 -1
- package/dist/core/tokens/xref-table-start-token.js +2 -2
- package/dist/crypto/index.d.ts +11 -0
- package/dist/crypto/index.js +11 -0
- package/dist/crypto/key-derivation/key-derivation-aes256.d.ts +1 -1
- package/dist/crypto/key-derivation/key-derivation-aes256.js +2 -2
- package/dist/crypto/key-derivation/key-derivation.d.ts +0 -14
- package/dist/crypto/key-derivation/key-derivation.js +1 -26
- package/dist/crypto/key-gen/key-gen-rc4-128.d.ts +1 -1
- package/dist/crypto/key-gen/key-gen-rc4-128.js +5 -6
- package/dist/crypto/key-gen/key-gen-rc4-40.js +1 -2
- package/dist/crypto/types.d.ts +1 -1
- package/dist/filters/asciihex.d.ts +1 -1
- package/dist/filters/asciihex.js +2 -2
- package/dist/filters/index.d.ts +7 -0
- package/dist/filters/index.js +7 -0
- package/dist/filters/lzw.d.ts +1 -1
- package/dist/filters/types.d.ts +1 -1
- package/dist/index.d.ts +5 -1
- package/dist/index.js +5 -1
- package/dist/pdf/index.d.ts +5 -4
- package/dist/pdf/index.js +5 -4
- package/dist/pdf/pdf-document.d.ts +14 -14
- package/dist/pdf/pdf-document.js +19 -19
- package/dist/pdf/pdf-reader.d.ts +3 -3
- package/dist/pdf/pdf-reader.js +2 -2
- package/dist/pdf/pdf-revision.d.ts +5 -5
- package/dist/pdf/pdf-revision.js +4 -4
- package/dist/pdf/pdf-xref-lookup.d.ts +7 -7
- package/dist/pdf/pdf-xref-lookup.js +9 -9
- package/dist/security/crypt-filters/aesv2.d.ts +2 -2
- package/dist/security/crypt-filters/aesv2.js +2 -2
- package/dist/security/crypt-filters/aesv3.d.ts +2 -2
- package/dist/security/crypt-filters/aesv3.js +2 -2
- package/dist/security/crypt-filters/base.d.ts +4 -4
- package/dist/security/crypt-filters/base.js +3 -3
- package/dist/security/crypt-filters/identity.d.ts +2 -2
- package/dist/security/crypt-filters/identity.js +1 -1
- package/dist/security/crypt-filters/v2.d.ts +1 -1
- package/dist/security/crypt-filters/v2.js +1 -1
- package/dist/security/handlers/base.d.ts +4 -4
- package/dist/security/handlers/base.js +12 -12
- package/dist/security/handlers/pubSec.d.ts +3 -3
- package/dist/security/handlers/pubSec.js +10 -10
- package/dist/security/handlers/utils.d.ts +4 -4
- package/dist/security/handlers/utils.js +12 -12
- package/dist/security/handlers/v1.d.ts +4 -4
- package/dist/security/handlers/v1.js +7 -7
- package/dist/security/handlers/v2.d.ts +3 -3
- package/dist/security/handlers/v2.js +5 -5
- package/dist/security/handlers/v4.d.ts +6 -6
- package/dist/security/handlers/v4.js +11 -11
- package/dist/security/handlers/v5.d.ts +5 -5
- package/dist/security/handlers/v5.js +9 -9
- package/dist/security/index.d.ts +13 -0
- package/dist/security/index.js +13 -0
- package/dist/security/types.d.ts +9 -9
- package/dist/signing/document-security-store.d.ts +11 -11
- package/dist/signing/document-security-store.js +4 -4
- package/dist/signing/index.d.ts +5 -4
- package/dist/signing/index.js +5 -4
- package/dist/signing/signatures/adbe-pkcs7-detached.d.ts +4 -4
- package/dist/signing/signatures/adbe-pkcs7-detached.js +11 -11
- package/dist/signing/signatures/adbe-pkcs7-sha1.d.ts +4 -4
- package/dist/signing/signatures/adbe-pkcs7-sha1.js +12 -12
- package/dist/signing/signatures/adbe-x509-rsa-sha1.d.ts +4 -4
- package/dist/signing/signatures/adbe-x509-rsa-sha1.js +8 -8
- package/dist/signing/signatures/base.d.ts +5 -5
- package/dist/signing/signatures/base.js +11 -11
- package/dist/signing/signatures/etsi-cades-detached.d.ts +4 -4
- package/dist/signing/signatures/etsi-cades-detached.js +17 -17
- package/dist/signing/signatures/etsi-rfc3161.d.ts +2 -2
- package/dist/signing/signatures/etsi-rfc3161.js +9 -9
- package/dist/signing/signatures/index.d.ts +6 -6
- package/dist/signing/signatures/index.js +6 -6
- package/dist/signing/signer.d.ts +3 -3
- package/dist/signing/signer.js +10 -10
- package/dist/signing/types.d.ts +7 -7
- package/dist/signing/utils.d.ts +2 -2
- package/dist/signing/utils.js +1 -1
- package/dist/utils/algos.js +1 -1
- package/dist/utils/bytesToHex.d.ts +1 -1
- package/dist/utils/bytesToHex.js +2 -2
- package/dist/utils/bytesToHexBytes.d.ts +1 -1
- package/dist/utils/bytesToString.d.ts +1 -1
- package/dist/utils/concatUint8Arrays.d.ts +1 -1
- package/dist/utils/escapeString.d.ts +1 -1
- package/dist/utils/escapeString.js +1 -1
- package/dist/utils/hexBytesToBytes.d.ts +1 -1
- package/dist/utils/hexBytesToString.d.ts +1 -1
- package/dist/utils/hexToBytes.d.ts +1 -1
- package/dist/utils/hexToBytes.js +2 -2
- package/dist/utils/index.d.ts +17 -0
- package/dist/utils/index.js +17 -0
- package/dist/utils/padBytes.d.ts +1 -1
- package/dist/utils/replaceInBuffer.d.ts +1 -1
- package/dist/utils/stringToBytes.d.ts +1 -1
- package/dist/utils/stringToHexBytes.d.ts +1 -1
- package/dist/utils/unescapeString.d.ts +1 -1
- package/package.json +3 -3
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { ByteArray } from '../../types';
|
|
2
|
-
import { PdfEncryptionDictionary } from '../types';
|
|
3
|
-
import { PdfV4SecurityHandler } from './v4';
|
|
4
|
-
import { PdfStandardSecurityHandlerOptions } from './base';
|
|
5
|
-
import { Cipher } from '../../crypto/types';
|
|
1
|
+
import { ByteArray } from '../../types.js';
|
|
2
|
+
import { PdfEncryptionDictionary } from '../types.js';
|
|
3
|
+
import { PdfV4SecurityHandler } from './v4.js';
|
|
4
|
+
import { PdfStandardSecurityHandlerOptions } from './base.js';
|
|
5
|
+
import { Cipher } from '../../crypto/types.js';
|
|
6
6
|
/**
|
|
7
7
|
* V5 security handler implementing AES-256-CBC encryption.
|
|
8
8
|
* This is the most secure encryption method (PDF 2.0).
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { aes256 } from '../../crypto/ciphers/aes256';
|
|
2
|
-
import { getFileKey } from '../../crypto/key-derivation/key-derivation-aes256';
|
|
3
|
-
import { generateOandOe, generateUandUe, } from '../../crypto/key-gen/key-gen-aes256';
|
|
4
|
-
import { aes256ecbEncrypt, getRandomBytes } from '../../utils/algos';
|
|
5
|
-
import { assert } from '../../utils/assert';
|
|
6
|
-
import { PdfV4SecurityHandler } from './v4';
|
|
7
|
-
import { AesV3CryptFilter } from '../crypt-filters/aesv3';
|
|
8
|
-
import { PdfHexadecimal } from '../../core/objects/pdf-hexadecimal';
|
|
9
|
-
import { PdfString } from '../../core/objects/pdf-string';
|
|
1
|
+
import { aes256 } from '../../crypto/ciphers/aes256.js';
|
|
2
|
+
import { getFileKey } from '../../crypto/key-derivation/key-derivation-aes256.js';
|
|
3
|
+
import { generateOandOe, generateUandUe, } from '../../crypto/key-gen/key-gen-aes256.js';
|
|
4
|
+
import { aes256ecbEncrypt, getRandomBytes } from '../../utils/algos.js';
|
|
5
|
+
import { assert } from '../../utils/assert.js';
|
|
6
|
+
import { PdfV4SecurityHandler } from './v4.js';
|
|
7
|
+
import { AesV3CryptFilter } from '../crypt-filters/aesv3.js';
|
|
8
|
+
import { PdfHexadecimal } from '../../core/objects/pdf-hexadecimal.js';
|
|
9
|
+
import { PdfString } from '../../core/objects/pdf-string.js';
|
|
10
10
|
/**
|
|
11
11
|
* V5 security handler implementing AES-256-CBC encryption.
|
|
12
12
|
* This is the most secure encryption method (PDF 2.0).
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export * from './crypt-filters/aesv2.js';
|
|
2
|
+
export * from './crypt-filters/aesv3.js';
|
|
3
|
+
export * from './crypt-filters/base.js';
|
|
4
|
+
export * from './crypt-filters/identity.js';
|
|
5
|
+
export * from './crypt-filters/v2.js';
|
|
6
|
+
export * from './handlers/base.js';
|
|
7
|
+
export * from './handlers/pubSec.js';
|
|
8
|
+
export * from './handlers/utils.js';
|
|
9
|
+
export * from './handlers/v1.js';
|
|
10
|
+
export * from './handlers/v2.js';
|
|
11
|
+
export * from './handlers/v4.js';
|
|
12
|
+
export * from './handlers/v5.js';
|
|
13
|
+
export * from './types.js';
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export * from './crypt-filters/aesv2.js';
|
|
2
|
+
export * from './crypt-filters/aesv3.js';
|
|
3
|
+
export * from './crypt-filters/base.js';
|
|
4
|
+
export * from './crypt-filters/identity.js';
|
|
5
|
+
export * from './crypt-filters/v2.js';
|
|
6
|
+
export * from './handlers/base.js';
|
|
7
|
+
export * from './handlers/pubSec.js';
|
|
8
|
+
export * from './handlers/utils.js';
|
|
9
|
+
export * from './handlers/v1.js';
|
|
10
|
+
export * from './handlers/v2.js';
|
|
11
|
+
export * from './handlers/v4.js';
|
|
12
|
+
export * from './handlers/v5.js';
|
|
13
|
+
export * from './types.js';
|
package/dist/security/types.d.ts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { PdfArray } from '../core/objects/pdf-array';
|
|
2
|
-
import { PdfBoolean } from '../core/objects/pdf-boolean';
|
|
3
|
-
import { PdfDictionary } from '../core/objects/pdf-dictionary';
|
|
4
|
-
import { PdfHexadecimal } from '../core/objects/pdf-hexadecimal';
|
|
5
|
-
import { PdfIndirectObject } from '../core/objects/pdf-indirect-object';
|
|
6
|
-
import { PdfName } from '../core/objects/pdf-name';
|
|
7
|
-
import { PdfNumber } from '../core/objects/pdf-number';
|
|
8
|
-
import { PdfString } from '../core/objects/pdf-string';
|
|
9
|
-
import { ByteArray } from '../types';
|
|
1
|
+
import { PdfArray } from '../core/objects/pdf-array.js';
|
|
2
|
+
import { PdfBoolean } from '../core/objects/pdf-boolean.js';
|
|
3
|
+
import { PdfDictionary } from '../core/objects/pdf-dictionary.js';
|
|
4
|
+
import { PdfHexadecimal } from '../core/objects/pdf-hexadecimal.js';
|
|
5
|
+
import { PdfIndirectObject } from '../core/objects/pdf-indirect-object.js';
|
|
6
|
+
import { PdfName } from '../core/objects/pdf-name.js';
|
|
7
|
+
import { PdfNumber } from '../core/objects/pdf-number.js';
|
|
8
|
+
import { PdfString } from '../core/objects/pdf-string.js';
|
|
9
|
+
import { ByteArray } from '../types.js';
|
|
10
10
|
/**
|
|
11
11
|
* Represents the PDF document ID array containing two hexadecimal identifiers.
|
|
12
12
|
* The first element is the permanent ID assigned when the document is created,
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { PdfArray } from '../core/objects/pdf-array';
|
|
2
|
-
import { PdfDate } from '../core/objects/pdf-date';
|
|
3
|
-
import { PdfDictionary } from '../core/objects/pdf-dictionary';
|
|
4
|
-
import { PdfIndirectObject } from '../core/objects/pdf-indirect-object';
|
|
5
|
-
import { PdfName } from '../core/objects/pdf-name';
|
|
6
|
-
import { PdfObjectReference } from '../core/objects/pdf-object-reference';
|
|
7
|
-
import { PdfStream } from '../core/objects/pdf-stream';
|
|
8
|
-
import { PdfString } from '../core/objects/pdf-string';
|
|
9
|
-
import { PdfDocument } from '../pdf/pdf-document';
|
|
10
|
-
import { ByteArray } from '../types';
|
|
11
|
-
import { RevocationInfo } from './types';
|
|
1
|
+
import { PdfArray } from '../core/objects/pdf-array.js';
|
|
2
|
+
import { PdfDate } from '../core/objects/pdf-date.js';
|
|
3
|
+
import { PdfDictionary } from '../core/objects/pdf-dictionary.js';
|
|
4
|
+
import { PdfIndirectObject } from '../core/objects/pdf-indirect-object.js';
|
|
5
|
+
import { PdfName } from '../core/objects/pdf-name.js';
|
|
6
|
+
import { PdfObjectReference } from '../core/objects/pdf-object-reference.js';
|
|
7
|
+
import { PdfStream } from '../core/objects/pdf-stream.js';
|
|
8
|
+
import { PdfString } from '../core/objects/pdf-string.js';
|
|
9
|
+
import { PdfDocument } from '../pdf/pdf-document.js';
|
|
10
|
+
import { ByteArray } from '../types.js';
|
|
11
|
+
import { RevocationInfo } from './types.js';
|
|
12
12
|
/**
|
|
13
13
|
* Indirect object containing a certificate stream.
|
|
14
14
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { PdfArray } from '../core/objects/pdf-array';
|
|
2
|
-
import { PdfDictionary } from '../core/objects/pdf-dictionary';
|
|
3
|
-
import { PdfIndirectObject } from '../core/objects/pdf-indirect-object';
|
|
4
|
-
import { PdfStream } from '../core/objects/pdf-stream';
|
|
1
|
+
import { PdfArray } from '../core/objects/pdf-array.js';
|
|
2
|
+
import { PdfDictionary } from '../core/objects/pdf-dictionary.js';
|
|
3
|
+
import { PdfIndirectObject } from '../core/objects/pdf-indirect-object.js';
|
|
4
|
+
import { PdfStream } from '../core/objects/pdf-stream.js';
|
|
5
5
|
/**
|
|
6
6
|
* Indirect object containing a certificate stream.
|
|
7
7
|
*/
|
package/dist/signing/index.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
export * from './
|
|
2
|
-
export * from './
|
|
3
|
-
export * from './
|
|
4
|
-
export * from './
|
|
1
|
+
export * from './document-security-store.js';
|
|
2
|
+
export * from './signatures/index.js';
|
|
3
|
+
export * from './signer.js';
|
|
4
|
+
export * from './types.js';
|
|
5
|
+
export * from './utils.js';
|
package/dist/signing/index.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
export * from './
|
|
2
|
-
export * from './
|
|
3
|
-
export * from './
|
|
4
|
-
export * from './
|
|
1
|
+
export * from './document-security-store.js';
|
|
2
|
+
export * from './signatures/index.js';
|
|
3
|
+
export * from './signer.js';
|
|
4
|
+
export * from './types.js';
|
|
5
|
+
export * from './utils.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { RevocationInfo, TimeStampAuthority } from '../types';
|
|
2
|
-
import { AsymmetricEncryptionAlgorithmParams } from 'pki-lite/core/index';
|
|
3
|
-
import { PdfSignatureObject, PdfSignatureSignOptions } from './base';
|
|
4
|
-
import { ByteArray } from '../../types';
|
|
1
|
+
import { RevocationInfo, TimeStampAuthority } from '../types.js';
|
|
2
|
+
import { AsymmetricEncryptionAlgorithmParams } from 'pki-lite/core/index.js';
|
|
3
|
+
import { PdfSignatureObject, PdfSignatureSignOptions } from './base.js';
|
|
4
|
+
import { ByteArray } from '../../types.js';
|
|
5
5
|
/**
|
|
6
6
|
* PKCS#7 detached signature object (adbe.pkcs7.detached).
|
|
7
7
|
* Creates CMS SignedData with the document hash as external data.
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { SignedData } from 'pki-lite/pkcs7/SignedData';
|
|
2
|
-
import { Certificate } from 'pki-lite/x509/Certificate';
|
|
3
|
-
import { SignerInfo } from 'pki-lite/pkcs7/SignerInfo';
|
|
4
|
-
import { Attribute } from 'pki-lite/x509/Attribute';
|
|
5
|
-
import { RevocationInfoArchival } from 'pki-lite/adobe/RevocationInfoArchival';
|
|
6
|
-
import { CertificateList } from 'pki-lite/x509/CertificateList';
|
|
7
|
-
import { OCSPResponse } from 'pki-lite/ocsp/OCSPResponse';
|
|
8
|
-
import { PrivateKeyInfo } from 'pki-lite/keys/PrivateKeyInfo';
|
|
9
|
-
import { OtherRevInfo } from 'pki-lite/adobe/OtherRevInfo';
|
|
10
|
-
import { fetchRevocationInfo } from '../utils';
|
|
11
|
-
import { PdfSignatureObject } from './base';
|
|
1
|
+
import { SignedData } from 'pki-lite/pkcs7/SignedData.js';
|
|
2
|
+
import { Certificate } from 'pki-lite/x509/Certificate.js';
|
|
3
|
+
import { SignerInfo } from 'pki-lite/pkcs7/SignerInfo.js';
|
|
4
|
+
import { Attribute } from 'pki-lite/x509/Attribute.js';
|
|
5
|
+
import { RevocationInfoArchival } from 'pki-lite/adobe/RevocationInfoArchival.js';
|
|
6
|
+
import { CertificateList } from 'pki-lite/x509/CertificateList.js';
|
|
7
|
+
import { OCSPResponse } from 'pki-lite/ocsp/OCSPResponse.js';
|
|
8
|
+
import { PrivateKeyInfo } from 'pki-lite/keys/PrivateKeyInfo.js';
|
|
9
|
+
import { OtherRevInfo } from 'pki-lite/adobe/OtherRevInfo.js';
|
|
10
|
+
import { fetchRevocationInfo } from '../utils.js';
|
|
11
|
+
import { PdfSignatureObject } from './base.js';
|
|
12
12
|
/**
|
|
13
13
|
* PKCS#7 detached signature object (adbe.pkcs7.detached).
|
|
14
14
|
* Creates CMS SignedData with the document hash as external data.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { RevocationInfo, TimeStampAuthority } from '../types';
|
|
2
|
-
import { AsymmetricEncryptionAlgorithmParams } from 'pki-lite/core/index';
|
|
3
|
-
import { PdfSignatureObject, PdfSignatureSignOptions } from './base';
|
|
4
|
-
import { ByteArray } from '../../types';
|
|
1
|
+
import { RevocationInfo, TimeStampAuthority } from '../types.js';
|
|
2
|
+
import { AsymmetricEncryptionAlgorithmParams } from 'pki-lite/core/index.js';
|
|
3
|
+
import { PdfSignatureObject, PdfSignatureSignOptions } from './base.js';
|
|
4
|
+
import { ByteArray } from '../../types.js';
|
|
5
5
|
/**
|
|
6
6
|
* PKCS#7 SHA-1 signature object (adbe.pkcs7.sha1).
|
|
7
7
|
* Creates CMS SignedData with SHA-1 hash embedded as signed content.
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { SignedData } from 'pki-lite/pkcs7/SignedData';
|
|
2
|
-
import { Certificate } from 'pki-lite/x509/Certificate';
|
|
3
|
-
import { SignerInfo } from 'pki-lite/pkcs7/SignerInfo';
|
|
4
|
-
import { Attribute } from 'pki-lite/x509/Attribute';
|
|
5
|
-
import { RevocationInfoArchival } from 'pki-lite/adobe/RevocationInfoArchival';
|
|
6
|
-
import { CertificateList } from 'pki-lite/x509/CertificateList';
|
|
7
|
-
import { OCSPResponse } from 'pki-lite/ocsp/OCSPResponse';
|
|
8
|
-
import { PrivateKeyInfo } from 'pki-lite/keys/PrivateKeyInfo';
|
|
9
|
-
import { OtherRevInfo } from 'pki-lite/adobe/OtherRevInfo';
|
|
10
|
-
import { fetchRevocationInfo } from '../utils';
|
|
11
|
-
import { PdfSignatureObject } from './base';
|
|
12
|
-
import { DigestAlgorithmIdentifier } from 'pki-lite/algorithms/AlgorithmIdentifier';
|
|
1
|
+
import { SignedData } from 'pki-lite/pkcs7/SignedData.js';
|
|
2
|
+
import { Certificate } from 'pki-lite/x509/Certificate.js';
|
|
3
|
+
import { SignerInfo } from 'pki-lite/pkcs7/SignerInfo.js';
|
|
4
|
+
import { Attribute } from 'pki-lite/x509/Attribute.js';
|
|
5
|
+
import { RevocationInfoArchival } from 'pki-lite/adobe/RevocationInfoArchival.js';
|
|
6
|
+
import { CertificateList } from 'pki-lite/x509/CertificateList.js';
|
|
7
|
+
import { OCSPResponse } from 'pki-lite/ocsp/OCSPResponse.js';
|
|
8
|
+
import { PrivateKeyInfo } from 'pki-lite/keys/PrivateKeyInfo.js';
|
|
9
|
+
import { OtherRevInfo } from 'pki-lite/adobe/OtherRevInfo.js';
|
|
10
|
+
import { fetchRevocationInfo } from '../utils.js';
|
|
11
|
+
import { PdfSignatureObject } from './base.js';
|
|
12
|
+
import { DigestAlgorithmIdentifier } from 'pki-lite/algorithms/AlgorithmIdentifier.js';
|
|
13
13
|
/**
|
|
14
14
|
* PKCS#7 SHA-1 signature object (adbe.pkcs7.sha1).
|
|
15
15
|
* Creates CMS SignedData with SHA-1 hash embedded as signed content.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { AsymmetricEncryptionAlgorithmParams } from 'pki-lite/core/index';
|
|
2
|
-
import { PdfSignatureObject, PdfSignatureSignOptions } from './base';
|
|
3
|
-
import { ByteArray } from '../../types';
|
|
4
|
-
import { RevocationInfo } from '../types';
|
|
1
|
+
import { AsymmetricEncryptionAlgorithmParams } from 'pki-lite/core/index.js';
|
|
2
|
+
import { PdfSignatureObject, PdfSignatureSignOptions } from './base.js';
|
|
3
|
+
import { ByteArray } from '../../types.js';
|
|
4
|
+
import { RevocationInfo } from '../types.js';
|
|
5
5
|
/**
|
|
6
6
|
* X.509 RSA-SHA1 signature object (adbe.x509.rsa_sha1).
|
|
7
7
|
* Creates a raw RSA-SHA1 signature with certificates in the Cert entry.
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { PrivateKeyInfo } from 'pki-lite/keys/PrivateKeyInfo';
|
|
2
|
-
import { PdfSignatureObject } from './base';
|
|
3
|
-
import { OctetString } from 'pki-lite/asn1/OctetString';
|
|
4
|
-
import { AlgorithmIdentifier } from 'pki-lite/algorithms/AlgorithmIdentifier';
|
|
5
|
-
import { Certificate } from 'pki-lite/x509/Certificate';
|
|
6
|
-
import { fetchRevocationInfo } from '../utils';
|
|
7
|
-
import { PdfArray } from '../../core/objects/pdf-array';
|
|
8
|
-
import { PdfHexadecimal } from '../../core/objects/pdf-hexadecimal';
|
|
1
|
+
import { PrivateKeyInfo } from 'pki-lite/keys/PrivateKeyInfo.js';
|
|
2
|
+
import { PdfSignatureObject } from './base.js';
|
|
3
|
+
import { OctetString } from 'pki-lite/asn1/OctetString.js';
|
|
4
|
+
import { AlgorithmIdentifier } from 'pki-lite/algorithms/AlgorithmIdentifier.js';
|
|
5
|
+
import { Certificate } from 'pki-lite/x509/Certificate.js';
|
|
6
|
+
import { fetchRevocationInfo } from '../utils.js';
|
|
7
|
+
import { PdfArray } from '../../core/objects/pdf-array.js';
|
|
8
|
+
import { PdfHexadecimal } from '../../core/objects/pdf-hexadecimal.js';
|
|
9
9
|
/**
|
|
10
10
|
* X.509 RSA-SHA1 signature object (adbe.x509.rsa_sha1).
|
|
11
11
|
* Creates a raw RSA-SHA1 signature with certificates in the Cert entry.
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { PdfDictionary } from '../../core/objects/pdf-dictionary';
|
|
2
|
-
import { PdfSignatureDictionaryEntries, PdfSignatureSubType, PdfSignatureVerificationOptions, PdfSignatureVerificationResult, RevocationInfo } from '../types';
|
|
3
|
-
import { PdfHexadecimal } from '../../core/objects/pdf-hexadecimal';
|
|
4
|
-
import { PdfIndirectObject } from '../../core/objects/pdf-indirect-object';
|
|
5
|
-
import { ByteArray } from '../../types';
|
|
1
|
+
import { PdfDictionary } from '../../core/objects/pdf-dictionary.js';
|
|
2
|
+
import { PdfSignatureDictionaryEntries, PdfSignatureSubType, PdfSignatureVerificationOptions, PdfSignatureVerificationResult, RevocationInfo } from '../types.js';
|
|
3
|
+
import { PdfHexadecimal } from '../../core/objects/pdf-hexadecimal.js';
|
|
4
|
+
import { PdfIndirectObject } from '../../core/objects/pdf-indirect-object.js';
|
|
5
|
+
import { ByteArray } from '../../types.js';
|
|
6
6
|
/**
|
|
7
7
|
* PDF signature dictionary containing all signature-related entries.
|
|
8
8
|
* Manages the ByteRange and Contents fields with appropriate placeholder sizing.
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { stringToBytes } from '../../utils/stringToBytes';
|
|
2
|
-
import { padBytes } from '../../utils/padBytes';
|
|
3
|
-
import { PdfDictionary } from '../../core/objects/pdf-dictionary';
|
|
4
|
-
import { bytesToHexBytes } from '../../utils/bytesToHexBytes';
|
|
5
|
-
import { PdfArray } from '../../core/objects/pdf-array';
|
|
6
|
-
import { PdfNumber } from '../../core/objects/pdf-number';
|
|
7
|
-
import { PdfHexadecimal } from '../../core/objects/pdf-hexadecimal';
|
|
8
|
-
import { PdfIndirectObject } from '../../core/objects/pdf-indirect-object';
|
|
9
|
-
import { PdfName } from '../../core/objects/pdf-name';
|
|
10
|
-
import { PdfString } from '../../core/objects/pdf-string';
|
|
11
|
-
import { PdfDate } from '../../core/objects/pdf-date';
|
|
1
|
+
import { stringToBytes } from '../../utils/stringToBytes.js';
|
|
2
|
+
import { padBytes } from '../../utils/padBytes.js';
|
|
3
|
+
import { PdfDictionary } from '../../core/objects/pdf-dictionary.js';
|
|
4
|
+
import { bytesToHexBytes } from '../../utils/bytesToHexBytes.js';
|
|
5
|
+
import { PdfArray } from '../../core/objects/pdf-array.js';
|
|
6
|
+
import { PdfNumber } from '../../core/objects/pdf-number.js';
|
|
7
|
+
import { PdfHexadecimal } from '../../core/objects/pdf-hexadecimal.js';
|
|
8
|
+
import { PdfIndirectObject } from '../../core/objects/pdf-indirect-object.js';
|
|
9
|
+
import { PdfName } from '../../core/objects/pdf-name.js';
|
|
10
|
+
import { PdfString } from '../../core/objects/pdf-string.js';
|
|
11
|
+
import { PdfDate } from '../../core/objects/pdf-date.js';
|
|
12
12
|
const PLACEHOLDER_BYTES = stringToBytes('placeholder_signature_bytes');
|
|
13
13
|
const PADDING = 8192 * 4;
|
|
14
14
|
const OFFSET_PADDING = 12;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { SignaturePolicyDocument, RevocationInfo, TimeStampAuthority } from '../types';
|
|
2
|
-
import { AsymmetricEncryptionAlgorithmParams } from 'pki-lite/core/index';
|
|
3
|
-
import { PdfSignatureObject, PdfSignatureSignOptions } from './base';
|
|
4
|
-
import { ByteArray } from '../../types';
|
|
1
|
+
import { SignaturePolicyDocument, RevocationInfo, TimeStampAuthority } from '../types.js';
|
|
2
|
+
import { AsymmetricEncryptionAlgorithmParams } from 'pki-lite/core/index.js';
|
|
3
|
+
import { PdfSignatureObject, PdfSignatureSignOptions } from './base.js';
|
|
4
|
+
import { ByteArray } from '../../types.js';
|
|
5
5
|
/**
|
|
6
6
|
* ETSI CAdES detached signature object (ETSI.CAdES.detached).
|
|
7
7
|
* Creates CAdES-compliant signatures with enhanced attributes.
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import { SignedData } from 'pki-lite/pkcs7/SignedData';
|
|
2
|
-
import { Certificate } from 'pki-lite/x509/Certificate';
|
|
3
|
-
import { SignerInfo } from 'pki-lite/pkcs7/SignerInfo';
|
|
4
|
-
import { Attribute } from 'pki-lite/x509/Attribute';
|
|
5
|
-
import { RevocationInfoArchival } from 'pki-lite/adobe/RevocationInfoArchival';
|
|
6
|
-
import { CertificateList } from 'pki-lite/x509/CertificateList';
|
|
7
|
-
import { OCSPResponse } from 'pki-lite/ocsp/OCSPResponse';
|
|
8
|
-
import { PrivateKeyInfo } from 'pki-lite/keys/PrivateKeyInfo';
|
|
9
|
-
import { OtherRevInfo } from 'pki-lite/adobe/OtherRevInfo';
|
|
10
|
-
import { PdfName } from '../../core/objects/pdf-name';
|
|
11
|
-
import { fetchRevocationInfo } from '../utils';
|
|
12
|
-
import { PdfString } from '../../core/objects/pdf-string';
|
|
13
|
-
import { PdfDate } from '../../core/objects/pdf-date';
|
|
14
|
-
import { PdfSignatureDictionary, PdfSignatureObject, } from './base';
|
|
15
|
-
import { SigningCertificateV2 } from 'pki-lite/x509/attributes/SigningCertificateV2';
|
|
16
|
-
import { OtherHashAlgAndValue, SignaturePolicyId, } from 'pki-lite/x509/attributes/SignaturePolicyIdentifier';
|
|
17
|
-
import { DigestAlgorithmIdentifier } from 'pki-lite/algorithms/AlgorithmIdentifier';
|
|
1
|
+
import { SignedData } from 'pki-lite/pkcs7/SignedData.js';
|
|
2
|
+
import { Certificate } from 'pki-lite/x509/Certificate.js';
|
|
3
|
+
import { SignerInfo } from 'pki-lite/pkcs7/SignerInfo.js';
|
|
4
|
+
import { Attribute } from 'pki-lite/x509/Attribute.js';
|
|
5
|
+
import { RevocationInfoArchival } from 'pki-lite/adobe/RevocationInfoArchival.js';
|
|
6
|
+
import { CertificateList } from 'pki-lite/x509/CertificateList.js';
|
|
7
|
+
import { OCSPResponse } from 'pki-lite/ocsp/OCSPResponse.js';
|
|
8
|
+
import { PrivateKeyInfo } from 'pki-lite/keys/PrivateKeyInfo.js';
|
|
9
|
+
import { OtherRevInfo } from 'pki-lite/adobe/OtherRevInfo.js';
|
|
10
|
+
import { PdfName } from '../../core/objects/pdf-name.js';
|
|
11
|
+
import { fetchRevocationInfo } from '../utils.js';
|
|
12
|
+
import { PdfString } from '../../core/objects/pdf-string.js';
|
|
13
|
+
import { PdfDate } from '../../core/objects/pdf-date.js';
|
|
14
|
+
import { PdfSignatureDictionary, PdfSignatureObject, } from './base.js';
|
|
15
|
+
import { SigningCertificateV2 } from 'pki-lite/x509/attributes/SigningCertificateV2.js';
|
|
16
|
+
import { OtherHashAlgAndValue, SignaturePolicyId, } from 'pki-lite/x509/attributes/SignaturePolicyIdentifier.js';
|
|
17
|
+
import { DigestAlgorithmIdentifier } from 'pki-lite/algorithms/AlgorithmIdentifier.js';
|
|
18
18
|
/**
|
|
19
19
|
* ETSI CAdES detached signature object (ETSI.CAdES.detached).
|
|
20
20
|
* Creates CAdES-compliant signatures with enhanced attributes.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { TimeStampAuthority } from '../types';
|
|
2
|
-
import { PdfSignatureObject, PdfSignatureSignOptions } from './base';
|
|
1
|
+
import { TimeStampAuthority } from '../types.js';
|
|
2
|
+
import { PdfSignatureObject, PdfSignatureSignOptions } from './base.js';
|
|
3
3
|
/**
|
|
4
4
|
* RFC 3161 timestamp signature object (ETSI.RFC3161).
|
|
5
5
|
* Creates document timestamps using a Time Stamp Authority (TSA).
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { PdfSignatureObject } from './base';
|
|
2
|
-
import { DigestAlgorithmIdentifier } from 'pki-lite/algorithms/AlgorithmIdentifier';
|
|
3
|
-
import { TimeStampReq } from 'pki-lite/timestamp/TimeStampReq';
|
|
4
|
-
import { TSTInfo } from 'pki-lite/timestamp/TSTInfo';
|
|
5
|
-
import { MessageImprint } from 'pki-lite/timestamp/MessageImprint';
|
|
6
|
-
import { SignedData } from 'pki-lite/pkcs7/SignedData';
|
|
7
|
-
import { fetchRevocationInfo } from '../utils';
|
|
8
|
-
import { Certificate } from 'pki-lite/x509/Certificate';
|
|
9
|
-
import { OIDs } from 'pki-lite/core/OIDs';
|
|
1
|
+
import { PdfSignatureObject } from './base.js';
|
|
2
|
+
import { DigestAlgorithmIdentifier } from 'pki-lite/algorithms/AlgorithmIdentifier.js';
|
|
3
|
+
import { TimeStampReq } from 'pki-lite/timestamp/TimeStampReq.js';
|
|
4
|
+
import { TSTInfo } from 'pki-lite/timestamp/TSTInfo.js';
|
|
5
|
+
import { MessageImprint } from 'pki-lite/timestamp/MessageImprint.js';
|
|
6
|
+
import { SignedData } from 'pki-lite/pkcs7/SignedData.js';
|
|
7
|
+
import { fetchRevocationInfo } from '../utils.js';
|
|
8
|
+
import { Certificate } from 'pki-lite/x509/Certificate.js';
|
|
9
|
+
import { OIDs } from 'pki-lite/core/OIDs.js';
|
|
10
10
|
/**
|
|
11
11
|
* RFC 3161 timestamp signature object (ETSI.RFC3161).
|
|
12
12
|
* Creates document timestamps using a Time Stamp Authority (TSA).
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export * from './adbe-pkcs7-detached';
|
|
2
|
-
export * from './adbe-pkcs7-sha1';
|
|
3
|
-
export * from './adbe-x509-rsa-sha1';
|
|
4
|
-
export * from './etsi-cades-detached';
|
|
5
|
-
export * from './etsi-rfc3161';
|
|
6
|
-
export * from './base';
|
|
1
|
+
export * from './adbe-pkcs7-detached.js';
|
|
2
|
+
export * from './adbe-pkcs7-sha1.js';
|
|
3
|
+
export * from './adbe-x509-rsa-sha1.js';
|
|
4
|
+
export * from './etsi-cades-detached.js';
|
|
5
|
+
export * from './etsi-rfc3161.js';
|
|
6
|
+
export * from './base.js';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export * from './adbe-pkcs7-detached';
|
|
2
|
-
export * from './adbe-pkcs7-sha1';
|
|
3
|
-
export * from './adbe-x509-rsa-sha1';
|
|
4
|
-
export * from './etsi-cades-detached';
|
|
5
|
-
export * from './etsi-rfc3161';
|
|
6
|
-
export * from './base';
|
|
1
|
+
export * from './adbe-pkcs7-detached.js';
|
|
2
|
+
export * from './adbe-pkcs7-sha1.js';
|
|
3
|
+
export * from './adbe-x509-rsa-sha1.js';
|
|
4
|
+
export * from './etsi-cades-detached.js';
|
|
5
|
+
export * from './etsi-rfc3161.js';
|
|
6
|
+
export * from './base.js';
|
package/dist/signing/signer.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { PdfDocument } from '../pdf/pdf-document';
|
|
2
|
-
import { PdfSignatureObject } from './signatures';
|
|
3
|
-
import { PdfSignatureVerificationResult, CertificateValidationOptions, PdfSignatureSubType } from './types';
|
|
1
|
+
import { PdfDocument } from '../pdf/pdf-document.js';
|
|
2
|
+
import { PdfSignatureObject } from './signatures/index.js';
|
|
3
|
+
import { PdfSignatureVerificationResult, CertificateValidationOptions, PdfSignatureSubType } from './types.js';
|
|
4
4
|
/**
|
|
5
5
|
* Result of verifying all signatures in a document.
|
|
6
6
|
*/
|
package/dist/signing/signer.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { PdfCommentToken } from '../core/tokens/comment-token';
|
|
2
|
-
import { PdfHexadecimalToken } from '../core/tokens/hexadecimal-token';
|
|
3
|
-
import { PdfNameToken } from '../core/tokens/name-token';
|
|
4
|
-
import { concatUint8Arrays } from '../utils/concatUint8Arrays';
|
|
5
|
-
import { PdfDocumentSecurityStoreObject } from './document-security-store';
|
|
6
|
-
import { PdfSignatureObject, PdfAdbePkcs7DetachedSignatureObject, PdfAdbePkcs7Sha1SignatureObject, PdfAdbePkcsX509RsaSha1SignatureObject, PdfEtsiCadesDetachedSignatureObject, PdfEtsiRfc3161SignatureObject, PdfSignatureDictionary, } from './signatures';
|
|
7
|
-
import { PdfNumber } from '../core/objects/pdf-number';
|
|
8
|
-
import { PdfIndirectObject } from '../core/objects/pdf-indirect-object';
|
|
9
|
-
import { PdfDictionary } from '../core/objects/pdf-dictionary';
|
|
10
|
-
import { PdfArray } from '../core/objects/pdf-array';
|
|
1
|
+
import { PdfCommentToken } from '../core/tokens/comment-token.js';
|
|
2
|
+
import { PdfHexadecimalToken } from '../core/tokens/hexadecimal-token.js';
|
|
3
|
+
import { PdfNameToken } from '../core/tokens/name-token.js';
|
|
4
|
+
import { concatUint8Arrays } from '../utils/concatUint8Arrays.js';
|
|
5
|
+
import { PdfDocumentSecurityStoreObject } from './document-security-store.js';
|
|
6
|
+
import { PdfSignatureObject, PdfAdbePkcs7DetachedSignatureObject, PdfAdbePkcs7Sha1SignatureObject, PdfAdbePkcsX509RsaSha1SignatureObject, PdfEtsiCadesDetachedSignatureObject, PdfEtsiRfc3161SignatureObject, PdfSignatureDictionary, } from './signatures/index.js';
|
|
7
|
+
import { PdfNumber } from '../core/objects/pdf-number.js';
|
|
8
|
+
import { PdfIndirectObject } from '../core/objects/pdf-indirect-object.js';
|
|
9
|
+
import { PdfDictionary } from '../core/objects/pdf-dictionary.js';
|
|
10
|
+
import { PdfArray } from '../core/objects/pdf-array.js';
|
|
11
11
|
/**
|
|
12
12
|
* Handles digital signing operations for PDF documents.
|
|
13
13
|
* Processes signature objects and optionally stores revocation information in the DSS.
|
package/dist/signing/types.d.ts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { HashAlgorithm } from 'pki-lite/core/crypto/index.js';
|
|
2
2
|
import type { CertificateValidationOptions, CertificateValidationResult, TrustAnchor } from 'pki-lite/core/CertificateValidator.js';
|
|
3
|
-
import { PdfDictionary } from '../core/objects/pdf-dictionary';
|
|
4
|
-
import { PdfName } from '../core/objects/pdf-name';
|
|
5
|
-
import { PdfHexadecimal } from '../core/objects/pdf-hexadecimal';
|
|
6
|
-
import { PdfArray } from '../core/objects/pdf-array';
|
|
7
|
-
import { PdfNumber } from '../core/objects/pdf-number';
|
|
8
|
-
import { PdfString } from '../core/objects/pdf-string';
|
|
9
|
-
import { ByteArray } from '../types';
|
|
3
|
+
import { PdfDictionary } from '../core/objects/pdf-dictionary.js';
|
|
4
|
+
import { PdfName } from '../core/objects/pdf-name.js';
|
|
5
|
+
import { PdfHexadecimal } from '../core/objects/pdf-hexadecimal.js';
|
|
6
|
+
import { PdfArray } from '../core/objects/pdf-array.js';
|
|
7
|
+
import { PdfNumber } from '../core/objects/pdf-number.js';
|
|
8
|
+
import { PdfString } from '../core/objects/pdf-string.js';
|
|
9
|
+
import { ByteArray } from '../types.js';
|
|
10
10
|
export type { CertificateValidationOptions, CertificateValidationResult, TrustAnchor, };
|
|
11
11
|
/**
|
|
12
12
|
* PDF signature subfilter types defining the signature format.
|
package/dist/signing/utils.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { RevocationInfo } from './types';
|
|
2
|
-
import { ByteArray } from '../types';
|
|
1
|
+
import { RevocationInfo } from './types.js';
|
|
2
|
+
import { ByteArray } from '../types.js';
|
|
3
3
|
/**
|
|
4
4
|
* Fetches revocation information (CRLs and OCSPs) for certificates.
|
|
5
5
|
* Uses the certificate's embedded URLs to retrieve revocation data.
|
package/dist/signing/utils.js
CHANGED
package/dist/utils/algos.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { deflate, Inflate } from 'pako';
|
|
2
2
|
import { bytesToHex } from './bytesToHex.js';
|
|
3
|
-
import { AlgorithmIdentifier } from 'pki-lite/algorithms/AlgorithmIdentifier';
|
|
3
|
+
import { AlgorithmIdentifier } from 'pki-lite/algorithms/AlgorithmIdentifier.js';
|
|
4
4
|
import 'pki-lite-crypto-extended';
|
|
5
5
|
/**
|
|
6
6
|
* Computes the SHA-1 hash of the input data.
|
package/dist/utils/bytesToHex.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { bytesToHexBytes } from './bytesToHexBytes';
|
|
2
|
-
import { bytesToString } from './bytesToString';
|
|
1
|
+
import { bytesToHexBytes } from './bytesToHexBytes.js';
|
|
2
|
+
import { bytesToString } from './bytesToString.js';
|
|
3
3
|
/**
|
|
4
4
|
* Converts a byte array to a hexadecimal string.
|
|
5
5
|
*
|
package/dist/utils/hexToBytes.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { hexBytesToBytes } from './hexBytesToBytes';
|
|
2
|
-
import { stringToBytes } from './stringToBytes';
|
|
1
|
+
import { hexBytesToBytes } from './hexBytesToBytes.js';
|
|
2
|
+
import { stringToBytes } from './stringToBytes.js';
|
|
3
3
|
/**
|
|
4
4
|
* Converts a hexadecimal string to a byte array.
|
|
5
5
|
*
|