@pacspace-io/check 0.5.5 → 0.5.6
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/CHANGELOG.md +11 -1
- package/README.md +2 -2
- package/dist/check.d.ts +6 -1
- package/dist/cli.js +321 -77
- package/dist/index.js +325 -75
- package/dist/inputs.txt +1 -0
- package/dist/report.d.ts +20 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,10 +1,20 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.5.6 - 2026-11-18
|
|
4
|
+
|
|
5
|
+
### Security
|
|
6
|
+
|
|
7
|
+
- `--rpc` holds its endpoint to its own address: a redirect is not followed. An answer larger than 1 MiB is not read; a log range that large is asked again in smaller ranges. A 429 is retried three times at most, and never waited on longer than the timeout. Reading a contract's whole log now ends after sixty times the timeout in all (ten minutes by default), and pages must move forward. With any of these the report says the proof layer was not read, and why, with the exit code for a proof layer that could not be reached. An `--rpc` address given as `http://` that redirects to `https://` must now be given as `https://`.
|
|
8
|
+
|
|
9
|
+
### Changed
|
|
10
|
+
|
|
11
|
+
- `passed`, in `--json` and in the result `checkHistory()` returns, is true only when the report's `exitCode` is 0. Before, it could be true beside exit code 3 (the proof layer was not read) and beside exit code 1 (the file you hold was not matched, or a statement or its fingerprint does not match).
|
|
12
|
+
|
|
3
13
|
## 0.5.5 - 2026-11-17
|
|
4
14
|
|
|
5
15
|
### Security
|
|
6
16
|
|
|
7
|
-
- Reads from a mirror (the default source or `--source <url>`) hold the source to its own address: a redirect is not followed, and a next page is read only from the same source and the same contract's log. A page with more logs than were asked for is not read. A page larger than 1 MiB is asked for again in smaller pages, and a single answer larger than 1 MiB is not read. With a source that does any of these the report says the proof layer was not read, and why, and the exit code is the one for a proof layer that could not be reached. A source given as `http://` that redirects to `https://`
|
|
17
|
+
- Reads from a mirror (the default source or `--source <url>`) hold the source to its own address: a redirect is not followed, and a next page is read only from the same source and the same contract's log. A page with more logs than were asked for is not read. A page larger than 1 MiB is asked for again in smaller pages, and a single answer larger than 1 MiB is not read. With a source that does any of these the report says the proof layer was not read, and why, and the exit code is the one for a proof layer that could not be reached. A source given as `http://` that redirects to `https://` is refused, and the report says why; give it as `https://`. With 0.5.4 such a source on the public mirrors already ended with exit code 3, without a reason. The list of where each entry was committed reads its pages under the same limits.
|
|
8
18
|
|
|
9
19
|
## 0.5.4 - 2026-11-16
|
|
10
20
|
|
package/README.md
CHANGED
|
@@ -131,13 +131,13 @@ if (report.exitCode !== 0) process.exitCode = report.exitCode;
|
|
|
131
131
|
`report` is a `pacspace-check-report/v1` document: the record's count and
|
|
132
132
|
the entries that matched, were missing, or did not match; whether the file
|
|
133
133
|
is intact; what the proof layer said; the daily statement's outcome; the
|
|
134
|
-
fingerprint comparison; and the sentences printed above.
|
|
134
|
+
fingerprint comparison; and the sentences printed above. `passed` is true only when the report's `exitCode` is 0.
|
|
135
135
|
|
|
136
136
|
## What it needs
|
|
137
137
|
|
|
138
138
|
Node.js 20.19 or later, and the network, for the proof layer. open reads the record from the link's host, and release reads the key pages from the host it checks. Checking a file sends nothing to PacSpace. Where a record was committed is named inside the history
|
|
139
139
|
file; `--source` and `--rpc` point the checker at a mirror or endpoint of
|
|
140
|
-
your own. A redirect from a source is not followed. Pass the address it leads to; a source given as `http://` usually needs `https://`. When a report says the proof layer was not read because of its source, name another source, or read without a mirror with `--rpc <url>`.
|
|
140
|
+
your own. A redirect from a source is not followed. Pass the address it leads to; a source given as `http://` usually needs `https://`. When a report says the proof layer was not read because of its source, name another source, or read without a mirror with `--rpc <url>`. The same holds for `--rpc`: a redirect is not followed, and an answer larger than 1 MiB is not read. Reading a contract's whole log, as `--full` does, is given sixty times the timeout in all, ten minutes by default; a report that says its source did not finish in the time allowed can be run again with a larger `--timeout`. Over `--rpc` such a read goes through the chain from its first block, which on a public network takes far longer than that.
|
|
141
141
|
|
|
142
142
|
## License
|
|
143
143
|
|
package/dist/check.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type HeldFile } from '@pacspace/shared';
|
|
2
|
-
import { type CheckReport, type DailyStatementOutcome } from './report';
|
|
2
|
+
import { type CheckReport, type ReportWithFacts, type DailyStatementOutcome } from './report';
|
|
3
3
|
export declare const CHECKER_NAME = "@pacspace-io/check";
|
|
4
4
|
export declare const CHECKER_VERSION: string;
|
|
5
5
|
/** The eight forms a history file names. */
|
|
@@ -120,3 +120,8 @@ export declare function needsLedgerRoots(file: HistoryFile): boolean;
|
|
|
120
120
|
* Nothing is sent to PacSpace.
|
|
121
121
|
*/
|
|
122
122
|
export declare function checkHistory(file: HistoryFile, options?: CheckOptions): Promise<CheckReport>;
|
|
123
|
+
/**
|
|
124
|
+
* `checkHistory`, with the narrower fact beside the report (`ReportWithFacts`). Internal: the package's entry
|
|
125
|
+
* point does not export it. `release` and `evidence` read `entriesMatch` where they once read `passed`.
|
|
126
|
+
*/
|
|
127
|
+
export declare function checkHistoryWithFacts(file: HistoryFile, options?: CheckOptions): Promise<ReportWithFacts>;
|