ata-validator 1.7.2 → 1.7.4

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 CHANGED
@@ -2,6 +2,22 @@
2
2
 
3
3
  All notable changes to ata-validator are documented here. The format follows [Keep a Changelog](https://keepachangelog.com/), and this project adheres to semantic versioning.
4
4
 
5
+ ## 1.7.4 - 2026-08-26
6
+
7
+ ### Fixed
8
+
9
+ - `validate()` read past the end of the document the caller handed it. simdjson wants padding after a document so its SIMD loads can run off the end, and the library was claiming that padding on buffers it does not own, on the grounds that a buffer not ending near a page boundary has readable bytes after it. That does not fault, which is why it went unnoticed, but the bytes belong to somebody else: under AddressSanitizer it reports as a heap-buffer-overflow inside simdjson, so anyone fuzzing or sanitizing an application built on ata saw a memory error with no way to tell it was deliberate. Through the Node binding the read landed in V8's heap. The document is now copied into a padded buffer, reused per thread, before it is parsed. The buffer APIs already did this and were never affected. Found by the fuzz targets in `fuzz/`, which were in the repository but had never been run; all three now survive millions of executions clean.
10
+
11
+ ### Changed
12
+
13
+ - Rejecting a document through the buffer APIs no longer costs more than accepting one. The On-Demand plan answers first, and a `false` from it used to be ambiguous: it could mean the document failed a constraint, or that the plan could not decide. The caller had to assume the second, so it re-created the padded view, parsed the whole document again into a DOM, tried the generated plan, and then walked the tree. A rejected document was therefore parsed twice and walked up to three times. The plan now reports whether it stopped because the document failed a constraint or because it could not be read, and only the second falls through. simdjson's `INCORRECT_TYPE` is a constraint failure rather than a read failure, which is the distinction that makes this work: a property holding a string where the schema wants an integer surfaces as a read error from `get<int64>`, not as a type mismatch. On a 62 KB array of a thousand objects with one bad element: 316 µs to 11 µs when the bad element is first, 315 µs to 40 µs when it is last, and rejecting is now never dearer than accepting. `tests/test_buffer_path_parity.js` holds the buffer path to the same answers as `validate()` across all 3359 suite cases, and still reports zero disagreements.
14
+
15
+ ## 1.7.3 - 2026-08-26
16
+
17
+ ### Added
18
+
19
+ - A prebuilt native engine for Intel macOS again, `@ata-validator/native-darwin-x64`. The target was dropped in 0.13.4 because GitHub's x64 macOS runners had stopped being reliably available; `macos-15-intel` brought them back, so the matrix is now seven targets: darwin arm64 and x64, linux x64 and arm64 on both glibc and musl, and win32 x64. Intel Macs went to the pure-JS engine in the meantime, which validates identically but leaves the buffer APIs unavailable, so this only changes speed and reach, not answers.
20
+
5
21
  ## 1.7.2 - 2026-08-24
6
22
 
7
23
  ### Fixed
package/README.md CHANGED
@@ -561,11 +561,28 @@ npm test
561
561
  npm run test:suite
562
562
  ```
563
563
 
564
+ ## Project
565
+
566
+ - [CONTRIBUTING.md](CONTRIBUTING.md) explains how to build the project and what a
567
+ pull request needs before it can be merged.
568
+ - [GOVERNANCE.md](GOVERNANCE.md) says who decides what, which changes the project
569
+ will not accept and why, how releases are cut, and how someone becomes a
570
+ maintainer. It states the bus factor plainly rather than leaving you to find
571
+ it out.
572
+ - [SECURITY.md](SECURITY.md) is where vulnerabilities go. Not the issue tracker.
573
+ - [CODE_OF_CONDUCT.md](CODE_OF_CONDUCT.md) applies everywhere the project is
574
+ discussed.
575
+
564
576
  ## License
565
577
 
566
578
  MIT
567
579
 
568
- ## Authors
580
+ ## Contributors
581
+
582
+ [@mertcanaltin](https://github.com/mertcanaltin) &middot;
583
+ [@SukeshP1995](https://github.com/SukeshP1995) &middot;
584
+ [@lemire](https://github.com/lemire) &middot;
585
+ [@armagandalkiran](https://github.com/armagandalkiran) &middot;
586
+ [@pnodet](https://github.com/pnodet)
569
587
 
570
- [Mert Can Altin](https://github.com/mertcanaltin)
571
- [Daniel Lemire](https://github.com/lemire)
588
+ Missing from this list after landing a patch? Send a pull request.
@@ -14,7 +14,10 @@
14
14
  const VERSION = require('./version');
15
15
 
16
16
  function nativePackageName(platform, arch, isMusl) {
17
- if (platform === 'darwin') return arch === 'arm64' ? '@ata-validator/native-darwin-arm64' : null;
17
+ if (platform === 'darwin') {
18
+ if (arch !== 'x64' && arch !== 'arm64') return null;
19
+ return `@ata-validator/native-darwin-${arch}`;
20
+ }
18
21
  if (platform === 'win32') return arch === 'x64' ? '@ata-validator/native-win32-x64' : null;
19
22
  if (platform === 'linux') {
20
23
  if (arch !== 'x64' && arch !== 'arm64') return null;
package/lib/version.js CHANGED
@@ -7,4 +7,4 @@
7
7
  //
8
8
  // Kept in lockstep with package.json by `tests/test_version_sync.js`.
9
9
 
10
- module.exports = '1.7.2';
10
+ module.exports = '1.7.4';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ata-validator",
3
- "version": "1.7.2",
3
+ "version": "1.7.4",
4
4
  "description": "JSON Schema validation with first-class TypeScript and zero runtime cost. AOT compile to per-schema ESM modules with zero validator dependency. Generic Validator<T> for TypeBox/Zod/Valibot composition. Optional runtime API. Standard Schema V1 compatible.",
5
5
  "main": "index.js",
6
6
  "module": "index.mjs",
@@ -112,12 +112,13 @@
112
112
  "LICENSE"
113
113
  ],
114
114
  "optionalDependencies": {
115
- "@ata-validator/native-darwin-arm64": "1.7.2",
116
- "@ata-validator/native-linux-x64-gnu": "1.7.2",
117
- "@ata-validator/native-linux-arm64-gnu": "1.7.2",
118
- "@ata-validator/native-linux-x64-musl": "1.7.2",
119
- "@ata-validator/native-linux-arm64-musl": "1.7.2",
120
- "@ata-validator/native-win32-x64": "1.7.2"
115
+ "@ata-validator/native-darwin-arm64": "1.7.4",
116
+ "@ata-validator/native-darwin-x64": "1.7.4",
117
+ "@ata-validator/native-linux-x64-gnu": "1.7.4",
118
+ "@ata-validator/native-linux-arm64-gnu": "1.7.4",
119
+ "@ata-validator/native-linux-x64-musl": "1.7.4",
120
+ "@ata-validator/native-linux-arm64-musl": "1.7.4",
121
+ "@ata-validator/native-win32-x64": "1.7.4"
121
122
  },
122
123
  "peerDependencies": {
123
124
  "yaml": "^2.0.0"