archive-codec 1.5.0 → 1.6.1

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 CHANGED
@@ -10,9 +10,11 @@ Created for [documents.js#564](https://github.com/ExaDev/documents.js/issues/564
10
10
 
11
11
  [documents.js#815](https://github.com/ExaDev/documents.js/issues/815), [#816](https://github.com/ExaDev/documents.js/issues/816), and [#817](https://github.com/ExaDev/documents.js/issues/817) then needed the other direction. `xls-codec`, `doc-codec`, `ppt-codec`, and `wpd-codec` each read a legacy Office binary format out of an [MS-CFB] container, and none of them can write one back, because there was no container to put their streams into: a `.xls` writer producing a `Workbook` stream, or a `.doc` writer producing `WordDocument` and `1Table`, needs a conformant compound file to hold them. That container is structural knowledge exactly as the reader's is, so `writeCompoundFile` is the mirror of `readCompoundFile` here rather than four hand-rolled emitters in four codecs.
12
12
 
13
+ [documents.js#974](https://github.com/ExaDev/documents.js/issues/974) added the other half of the OLE Package stream: `writeOlePackage`, the mirror of `readOlePackage`, for `rtf-codec`'s own OLE embedding -- an RTF `\object`'s `\objdata` is the hex bytes of a real [MS-CFB] compound file wrapping a `Package` stream, so writing one needed both halves this package already had separately (`writeCompoundFile` for the container, `readOlePackage` for the stream inside it) plus the write side of the stream itself.
14
+
13
15
  [documents.js#815](https://github.com/ExaDev/documents.js/issues/815), [#816](https://github.com/ExaDev/documents.js/issues/816), and [#817](https://github.com/ExaDev/documents.js/issues/817) also each named the same remaining gap: `doc-codec`, `xls-codec`, and `ppt-codec` all hard-coded document metadata (title, author, dates) to an empty object, because that metadata lives in a genuinely different structure from the one each format's own reader already parses -- a [MS-OLEPS] Property Set Stream, conventionally stored as a "\x05SummaryInformation" stream beside `WordDocument`/`Workbook`/`PowerPoint Document` in the identical [MS-CFB] container all three already read through this package. `oleps/read` and `oleps/write` are the generic property-set codec (the stream header, the PropertySet packet's dictionary, and VT_I2/VT_I4/VT_LPSTR/VT_LPWSTR/VT_FILETIME typed values), and `oleps/summary-information` is the SummaryInformation-specific mapping on top of it -- the same two-layer split `cfb/read.ts` and `cfb/ole-package.ts` already establish for the OLE Package stream, container structure below, one named stream's own field layout above.
14
16
 
15
- Scope: **ZIP containers** (read and write over [`fflate`](https://github.com/101arrowz/fflate), recursive walking of ZIP-in-ZIP entries), **classic OLE compound files** (bounded [MS-CFB] reading and conformant [MS-CFB] writing, plus the OLE Package stream unwrapping), and **[MS-OLEPS] Property Set Streams** (generic read/write of a single-property-set stream, plus SummaryInformation's own title/subject/author/keywords/comments/created/last-saved/last-printed fields). **tar and gzip, DocumentSummaryInformation's extended and user-defined property sets, and writing VT_LPSTR (ANSI-codepage) string properties are explicitly out of scope.**
17
+ Scope: **ZIP containers** (read and write over [`fflate`](https://github.com/101arrowz/fflate), recursive walking of ZIP-in-ZIP entries), **classic OLE compound files** (bounded [MS-CFB] reading and conformant [MS-CFB] writing, plus OLE Package stream reading and writing), and **[MS-OLEPS] Property Set Streams** (generic read/write of a single-property-set stream, plus SummaryInformation's own title/subject/author/keywords/comments/created/last-saved/last-printed fields). **tar and gzip, DocumentSummaryInformation's extended and user-defined property sets, and writing VT_LPSTR (ANSI-codepage) string properties are explicitly out of scope.**
16
18
 
17
19
  ## Getting started
18
20
 
@@ -50,7 +52,7 @@ The smoke suite (`test/smoke.test.mjs`) is the guard on that advertisement: it l
50
52
  | `cfb/detect` | `isCompoundFile` (the `D0 CF 11 E0 …` magic-byte check) |
51
53
  | `cfb/read` | `readCompoundFile` (bounded [MS-CFB] stream extraction), `CompoundFileStream`, `CompoundFileFormatError`, `MAX_CFB_TOTAL_STREAM_BYTES`, `ReadCompoundFileOptions` |
52
54
  | `cfb/write` | `writeCompoundFile` ([MS-CFB] container generation), `CompoundFileWriteError`, `WriteCompoundFileOptions` — takes the `CompoundFileStream` array `cfb/read` returns |
53
- | `cfb/ole-package` | `readOlePackage` (OLE Package stream unwrapping), `OlePackage`, `OlePackageFormatError` |
55
+ | `cfb/ole-package` | `readOlePackage` (OLE Package stream unwrapping), `writeOlePackage` (the mirror), `OlePackage`, `OlePackageFormatError`, `OlePackageWriteError` |
54
56
  | `oleps/read` | `readPropertySetStream` (generic [MS-OLEPS] property-set decoding), `PropertySetFormatError` |
55
57
  | `oleps/write` | `writePropertySetStream` (generic [MS-OLEPS] property-set encoding), `PropertySetWriteError` — takes the `PropertySet` shape `oleps/read` returns |
56
58
  | `oleps/summary-information` | `readSummaryInformation`, `writeSummaryInformationStream`, `SummaryInformationProperties`, `FMTID_SUMMARY_INFORMATION` |
@@ -76,7 +78,12 @@ Both guards throw rather than truncate: an input outside the contract must fail
76
78
  ### Compound files
77
79
 
78
80
  ```ts
79
- import { readCompoundFile, readOlePackage } from "archive-codec";
81
+ import {
82
+ readCompoundFile,
83
+ readOlePackage,
84
+ writeCompoundFile,
85
+ writeOlePackage,
86
+ } from "archive-codec";
80
87
 
81
88
  // Every stream of a classic OLE compound file, with its storage path.
82
89
  // Throws CompoundFileFormatError on any structural nonconformance.
@@ -93,6 +100,19 @@ const packageStream = readCompoundFile(oleBinBytes).find(
93
100
  if (packageStream !== undefined) {
94
101
  readOlePackage(packageStream.bytes).fileBytes; // often a ZIP for a modern embed
95
102
  }
103
+
104
+ // The mirror image: builds a 'Package' stream's bytes from the same shape
105
+ // readOlePackage returns, to wrap alongside writeCompoundFile -- this is how
106
+ // rtf-codec builds the real [MS-CFB] container an RTF \object's \objdata carries.
107
+ const packageBytes = writeOlePackage({
108
+ label: "embedded.docx",
109
+ sourcePath: "",
110
+ tempPath: "",
111
+ fileBytes: embeddedFileBytes,
112
+ });
113
+ const embedBytes = writeCompoundFile([
114
+ { path: "Package", bytes: packageBytes },
115
+ ]);
96
116
  ```
97
117
 
98
118
  Reading is bounded the same way walking is: chain cycles and out-of-range sectors fail against bounds derived from the file's own sector count, and one cumulative extracted-bytes budget (`MAX_CFB_TOTAL_STREAM_BYTES`, 512 MiB — the same figure the family grants one decompressed stream) bounds the multiplication a hostile FAT gains by aliasing one sector into many streams. Every structural failure throws rather than truncating — a malformed compound file fails whole, never a partial stream listing that looks complete. Version 3 (512-byte sectors) and version 4 (4096-byte) files both read; the mini-FAT path every stream shorter than the header's cutoff takes is first-class, because a small real-world embed genuinely lands there.
@@ -37,6 +37,46 @@ function readOlePackage(bytes) {
37
37
  fileBytes: bytes.slice(offset, offset + fileByteCount)
38
38
  };
39
39
  }
40
+ var OlePackageWriteError = class extends Error {
41
+ constructor(message) {
42
+ super(message);
43
+ this.name = "OlePackageWriteError";
44
+ }
45
+ };
46
+ function asciiZeroTerminated(value, fieldName) {
47
+ const bytes = new Uint8Array(value.length + 1);
48
+ for (let index = 0; index < value.length; index++) {
49
+ const code = value.charCodeAt(index);
50
+ if (code === 0) throw new OlePackageWriteError(`Package stream's ${fieldName} contains an embedded NUL byte, which this field's own null-terminated encoding cannot carry: it would silently truncate the field and mis-frame every field written after it`);
51
+ if (code > 127) throw new OlePackageWriteError(`Package stream's ${fieldName} contains a character (U+${code.toString(16).padStart(4, "0")}) outside ASCII; encoding it to an arbitrary windows-1252 byte would need a full codepage table this package does not carry`);
52
+ bytes[index] = code;
53
+ }
54
+ return bytes;
55
+ }
56
+ function writeOlePackage(pkg) {
57
+ const labelBytes = asciiZeroTerminated(pkg.label, "label");
58
+ const sourcePathBytes = asciiZeroTerminated(pkg.sourcePath, "source path");
59
+ const tempPathBytes = asciiZeroTerminated(pkg.tempPath, "temp path");
60
+ const totalLength = 2 + labelBytes.length + sourcePathBytes.length + 8 + tempPathBytes.length + 4 + pkg.fileBytes.length;
61
+ const out = new Uint8Array(totalLength);
62
+ const view = new DataView(out.buffer);
63
+ let offset = 0;
64
+ view.setUint16(offset, 2, true);
65
+ offset += 2;
66
+ out.set(labelBytes, offset);
67
+ offset += labelBytes.length;
68
+ out.set(sourcePathBytes, offset);
69
+ offset += sourcePathBytes.length;
70
+ offset += 8;
71
+ out.set(tempPathBytes, offset);
72
+ offset += tempPathBytes.length;
73
+ view.setUint32(offset, pkg.fileBytes.length, true);
74
+ offset += 4;
75
+ out.set(pkg.fileBytes, offset);
76
+ return out;
77
+ }
40
78
  //#endregion
41
79
  exports.OlePackageFormatError = OlePackageFormatError;
80
+ exports.OlePackageWriteError = OlePackageWriteError;
42
81
  exports.readOlePackage = readOlePackage;
82
+ exports.writeOlePackage = writeOlePackage;
@@ -9,5 +9,9 @@ interface OlePackage {
9
9
  readonly fileBytes: Uint8Array<ArrayBuffer>;
10
10
  }
11
11
  declare function readOlePackage(bytes: Uint8Array<ArrayBuffer>): OlePackage;
12
+ declare class OlePackageWriteError extends Error {
13
+ constructor(message: string);
14
+ }
15
+ declare function writeOlePackage(pkg: OlePackage): Uint8Array<ArrayBuffer>;
12
16
  //#endregion
13
- export { OlePackage, OlePackageFormatError, readOlePackage };
17
+ export { OlePackage, OlePackageFormatError, OlePackageWriteError, readOlePackage, writeOlePackage };
@@ -9,5 +9,9 @@ interface OlePackage {
9
9
  readonly fileBytes: Uint8Array<ArrayBuffer>;
10
10
  }
11
11
  declare function readOlePackage(bytes: Uint8Array<ArrayBuffer>): OlePackage;
12
+ declare class OlePackageWriteError extends Error {
13
+ constructor(message: string);
14
+ }
15
+ declare function writeOlePackage(pkg: OlePackage): Uint8Array<ArrayBuffer>;
12
16
  //#endregion
13
- export { OlePackage, OlePackageFormatError, readOlePackage };
17
+ export { OlePackage, OlePackageFormatError, OlePackageWriteError, readOlePackage, writeOlePackage };
@@ -36,5 +36,43 @@ function readOlePackage(bytes) {
36
36
  fileBytes: bytes.slice(offset, offset + fileByteCount)
37
37
  };
38
38
  }
39
+ var OlePackageWriteError = class extends Error {
40
+ constructor(message) {
41
+ super(message);
42
+ this.name = "OlePackageWriteError";
43
+ }
44
+ };
45
+ function asciiZeroTerminated(value, fieldName) {
46
+ const bytes = new Uint8Array(value.length + 1);
47
+ for (let index = 0; index < value.length; index++) {
48
+ const code = value.charCodeAt(index);
49
+ if (code === 0) throw new OlePackageWriteError(`Package stream's ${fieldName} contains an embedded NUL byte, which this field's own null-terminated encoding cannot carry: it would silently truncate the field and mis-frame every field written after it`);
50
+ if (code > 127) throw new OlePackageWriteError(`Package stream's ${fieldName} contains a character (U+${code.toString(16).padStart(4, "0")}) outside ASCII; encoding it to an arbitrary windows-1252 byte would need a full codepage table this package does not carry`);
51
+ bytes[index] = code;
52
+ }
53
+ return bytes;
54
+ }
55
+ function writeOlePackage(pkg) {
56
+ const labelBytes = asciiZeroTerminated(pkg.label, "label");
57
+ const sourcePathBytes = asciiZeroTerminated(pkg.sourcePath, "source path");
58
+ const tempPathBytes = asciiZeroTerminated(pkg.tempPath, "temp path");
59
+ const totalLength = 2 + labelBytes.length + sourcePathBytes.length + 8 + tempPathBytes.length + 4 + pkg.fileBytes.length;
60
+ const out = new Uint8Array(totalLength);
61
+ const view = new DataView(out.buffer);
62
+ let offset = 0;
63
+ view.setUint16(offset, 2, true);
64
+ offset += 2;
65
+ out.set(labelBytes, offset);
66
+ offset += labelBytes.length;
67
+ out.set(sourcePathBytes, offset);
68
+ offset += sourcePathBytes.length;
69
+ offset += 8;
70
+ out.set(tempPathBytes, offset);
71
+ offset += tempPathBytes.length;
72
+ view.setUint32(offset, pkg.fileBytes.length, true);
73
+ offset += 4;
74
+ out.set(pkg.fileBytes, offset);
75
+ return out;
76
+ }
39
77
  //#endregion
40
- export { OlePackageFormatError, readOlePackage };
78
+ export { OlePackageFormatError, OlePackageWriteError, readOlePackage, writeOlePackage };
package/dist/index.cjs CHANGED
@@ -18,6 +18,7 @@ exports.MAX_CFB_TOTAL_STREAM_BYTES = require_cfb_read.MAX_CFB_TOTAL_STREAM_BYTES
18
18
  exports.MAX_WALK_DEPTH = require_zip_walk.MAX_WALK_DEPTH;
19
19
  exports.MAX_WALK_TOTAL_BYTES = require_zip_walk.MAX_WALK_TOTAL_BYTES;
20
20
  exports.OlePackageFormatError = require_cfb_ole_package.OlePackageFormatError;
21
+ exports.OlePackageWriteError = require_cfb_ole_package.OlePackageWriteError;
21
22
  exports.PropertySetFormatError = require_oleps_read.PropertySetFormatError;
22
23
  exports.PropertySetWriteError = require_oleps_write.PropertySetWriteError;
23
24
  exports.detectArchiveFormat = require_zip_detect.detectArchiveFormat;
@@ -33,6 +34,7 @@ exports.summaryInformationToLayoutMetadata = require_oleps_layout_metadata.summa
33
34
  exports.unzipPackage = require_zip_container.unzipPackage;
34
35
  exports.walkArchive = require_zip_walk.walkArchive;
35
36
  exports.writeCompoundFile = require_cfb_write.writeCompoundFile;
37
+ exports.writeOlePackage = require_cfb_ole_package.writeOlePackage;
36
38
  exports.writePropertySetStream = require_oleps_write.writePropertySetStream;
37
39
  exports.writeSummaryInformationStream = require_oleps_summary_information.writeSummaryInformationStream;
38
40
  exports.zipPackage = require_zip_container.zipPackage;
package/dist/index.d.cts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { isCompoundFile } from "./cfb/detect.cjs";
2
- import { OlePackage, OlePackageFormatError, readOlePackage } from "./cfb/ole-package.cjs";
2
+ import { OlePackage, OlePackageFormatError, OlePackageWriteError, readOlePackage, writeOlePackage } from "./cfb/ole-package.cjs";
3
3
  import { CompoundFileFormatError, CompoundFileStream, MAX_CFB_TOTAL_STREAM_BYTES, ReadCompoundFileOptions, readCompoundFile } from "./cfb/read.cjs";
4
4
  import { CompoundFileWriteError, WriteCompoundFileOptions, writeCompoundFile } from "./cfb/write.cjs";
5
5
  import { FMTID_SUMMARY_INFORMATION, SummaryInformationProperties, readSummaryInformation, writeSummaryInformationStream } from "./oleps/summary-information.cjs";
@@ -10,4 +10,4 @@ import { PropertySetWriteError, writePropertySetStream } from "./oleps/write.cjs
10
10
  import { ZipEntry, unzipPackage, zipPackage } from "./zip/container.cjs";
11
11
  import { ArchiveFormat, detectArchiveFormat, isZipArchive } from "./zip/detect.cjs";
12
12
  import { ArchiveWalkEntry, ArchiveWalkLimit, ArchiveWalkLimitError, MAX_WALK_DEPTH, MAX_WALK_TOTAL_BYTES, WalkArchiveOptions, walkArchive } from "./zip/walk.cjs";
13
- export { ArchiveFormat, ArchiveWalkEntry, ArchiveWalkLimit, ArchiveWalkLimitError, CompoundFileFormatError, CompoundFileStream, CompoundFileWriteError, FMTID_SUMMARY_INFORMATION, MAX_CFB_TOTAL_STREAM_BYTES, MAX_WALK_DEPTH, MAX_WALK_TOTAL_BYTES, OlePackage, OlePackageFormatError, type PropertySet, PropertySetFormatError, PropertySetWriteError, type PropertyValue, ReadCompoundFileOptions, SummaryInformationProperties, WalkArchiveOptions, WriteCompoundFileOptions, ZipEntry, detectArchiveFormat, hasSummaryInformationFields, isCompoundFile, isZipArchive, layoutMetadataToSummaryInformation, readCompoundFile, readOlePackage, readPropertySetStream, readSummaryInformation, summaryInformationToLayoutMetadata, unzipPackage, walkArchive, writeCompoundFile, writePropertySetStream, writeSummaryInformationStream, zipPackage };
13
+ export { ArchiveFormat, ArchiveWalkEntry, ArchiveWalkLimit, ArchiveWalkLimitError, CompoundFileFormatError, CompoundFileStream, CompoundFileWriteError, FMTID_SUMMARY_INFORMATION, MAX_CFB_TOTAL_STREAM_BYTES, MAX_WALK_DEPTH, MAX_WALK_TOTAL_BYTES, OlePackage, OlePackageFormatError, OlePackageWriteError, type PropertySet, PropertySetFormatError, PropertySetWriteError, type PropertyValue, ReadCompoundFileOptions, SummaryInformationProperties, WalkArchiveOptions, WriteCompoundFileOptions, ZipEntry, detectArchiveFormat, hasSummaryInformationFields, isCompoundFile, isZipArchive, layoutMetadataToSummaryInformation, readCompoundFile, readOlePackage, readPropertySetStream, readSummaryInformation, summaryInformationToLayoutMetadata, unzipPackage, walkArchive, writeCompoundFile, writeOlePackage, writePropertySetStream, writeSummaryInformationStream, zipPackage };
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { isCompoundFile } from "./cfb/detect.js";
2
- import { OlePackage, OlePackageFormatError, readOlePackage } from "./cfb/ole-package.js";
2
+ import { OlePackage, OlePackageFormatError, OlePackageWriteError, readOlePackage, writeOlePackage } from "./cfb/ole-package.js";
3
3
  import { CompoundFileFormatError, CompoundFileStream, MAX_CFB_TOTAL_STREAM_BYTES, ReadCompoundFileOptions, readCompoundFile } from "./cfb/read.js";
4
4
  import { CompoundFileWriteError, WriteCompoundFileOptions, writeCompoundFile } from "./cfb/write.js";
5
5
  import { FMTID_SUMMARY_INFORMATION, SummaryInformationProperties, readSummaryInformation, writeSummaryInformationStream } from "./oleps/summary-information.js";
@@ -10,4 +10,4 @@ import { PropertySetWriteError, writePropertySetStream } from "./oleps/write.js"
10
10
  import { ZipEntry, unzipPackage, zipPackage } from "./zip/container.js";
11
11
  import { ArchiveFormat, detectArchiveFormat, isZipArchive } from "./zip/detect.js";
12
12
  import { ArchiveWalkEntry, ArchiveWalkLimit, ArchiveWalkLimitError, MAX_WALK_DEPTH, MAX_WALK_TOTAL_BYTES, WalkArchiveOptions, walkArchive } from "./zip/walk.js";
13
- export { ArchiveFormat, ArchiveWalkEntry, ArchiveWalkLimit, ArchiveWalkLimitError, CompoundFileFormatError, CompoundFileStream, CompoundFileWriteError, FMTID_SUMMARY_INFORMATION, MAX_CFB_TOTAL_STREAM_BYTES, MAX_WALK_DEPTH, MAX_WALK_TOTAL_BYTES, OlePackage, OlePackageFormatError, type PropertySet, PropertySetFormatError, PropertySetWriteError, type PropertyValue, ReadCompoundFileOptions, SummaryInformationProperties, WalkArchiveOptions, WriteCompoundFileOptions, ZipEntry, detectArchiveFormat, hasSummaryInformationFields, isCompoundFile, isZipArchive, layoutMetadataToSummaryInformation, readCompoundFile, readOlePackage, readPropertySetStream, readSummaryInformation, summaryInformationToLayoutMetadata, unzipPackage, walkArchive, writeCompoundFile, writePropertySetStream, writeSummaryInformationStream, zipPackage };
13
+ export { ArchiveFormat, ArchiveWalkEntry, ArchiveWalkLimit, ArchiveWalkLimitError, CompoundFileFormatError, CompoundFileStream, CompoundFileWriteError, FMTID_SUMMARY_INFORMATION, MAX_CFB_TOTAL_STREAM_BYTES, MAX_WALK_DEPTH, MAX_WALK_TOTAL_BYTES, OlePackage, OlePackageFormatError, OlePackageWriteError, type PropertySet, PropertySetFormatError, PropertySetWriteError, type PropertyValue, ReadCompoundFileOptions, SummaryInformationProperties, WalkArchiveOptions, WriteCompoundFileOptions, ZipEntry, detectArchiveFormat, hasSummaryInformationFields, isCompoundFile, isZipArchive, layoutMetadataToSummaryInformation, readCompoundFile, readOlePackage, readPropertySetStream, readSummaryInformation, summaryInformationToLayoutMetadata, unzipPackage, walkArchive, writeCompoundFile, writeOlePackage, writePropertySetStream, writeSummaryInformationStream, zipPackage };
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { isCompoundFile } from "./cfb/detect.js";
2
- import { OlePackageFormatError, readOlePackage } from "./cfb/ole-package.js";
2
+ import { OlePackageFormatError, OlePackageWriteError, readOlePackage, writeOlePackage } from "./cfb/ole-package.js";
3
3
  import { CompoundFileFormatError, MAX_CFB_TOTAL_STREAM_BYTES, readCompoundFile } from "./cfb/read.js";
4
4
  import { CompoundFileWriteError, writeCompoundFile } from "./cfb/write.js";
5
5
  import { hasSummaryInformationFields, layoutMetadataToSummaryInformation, summaryInformationToLayoutMetadata } from "./oleps/layout-metadata.js";
@@ -9,4 +9,4 @@ import { FMTID_SUMMARY_INFORMATION, readSummaryInformation, writeSummaryInformat
9
9
  import { unzipPackage, zipPackage } from "./zip/container.js";
10
10
  import { detectArchiveFormat, isZipArchive } from "./zip/detect.js";
11
11
  import { ArchiveWalkLimitError, MAX_WALK_DEPTH, MAX_WALK_TOTAL_BYTES, walkArchive } from "./zip/walk.js";
12
- export { ArchiveWalkLimitError, CompoundFileFormatError, CompoundFileWriteError, FMTID_SUMMARY_INFORMATION, MAX_CFB_TOTAL_STREAM_BYTES, MAX_WALK_DEPTH, MAX_WALK_TOTAL_BYTES, OlePackageFormatError, PropertySetFormatError, PropertySetWriteError, detectArchiveFormat, hasSummaryInformationFields, isCompoundFile, isZipArchive, layoutMetadataToSummaryInformation, readCompoundFile, readOlePackage, readPropertySetStream, readSummaryInformation, summaryInformationToLayoutMetadata, unzipPackage, walkArchive, writeCompoundFile, writePropertySetStream, writeSummaryInformationStream, zipPackage };
12
+ export { ArchiveWalkLimitError, CompoundFileFormatError, CompoundFileWriteError, FMTID_SUMMARY_INFORMATION, MAX_CFB_TOTAL_STREAM_BYTES, MAX_WALK_DEPTH, MAX_WALK_TOTAL_BYTES, OlePackageFormatError, OlePackageWriteError, PropertySetFormatError, PropertySetWriteError, detectArchiveFormat, hasSummaryInformationFields, isCompoundFile, isZipArchive, layoutMetadataToSummaryInformation, readCompoundFile, readOlePackage, readPropertySetStream, readSummaryInformation, summaryInformationToLayoutMetadata, unzipPackage, walkArchive, writeCompoundFile, writeOlePackage, writePropertySetStream, writeSummaryInformationStream, zipPackage };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "archive-codec",
3
- "version": "1.5.0",
3
+ "version": "1.6.1",
4
4
  "description": "ZIP-in-ZIP recursive walking with depth and cumulative decompressed-size guards, bounded classic OLE compound-file ([MS-CFB]) reading and writing, and [MS-OLEPS] Property Set Stream reading and writing - zero document-format knowledge, the archive and container utility package for the documents.js family.",
5
5
  "type": "module",
6
6
  "repository": {
@@ -70,7 +70,7 @@
70
70
  },
71
71
  "packageManager": "pnpm@11.6.0",
72
72
  "dependencies": {
73
- "document-schema.js": "^6.1.0",
73
+ "document-schema.js": "^6.2.0",
74
74
  "fflate": "^0.8.2"
75
75
  },
76
76
  "devDependencies": {