@parmanasystems/core 1.71.14 → 1.71.19

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/dist/index.js CHANGED
@@ -10499,7 +10499,8 @@ import {
10499
10499
  evaluatePolicy,
10500
10500
  loadPolicy,
10501
10501
  canonicalizeForSigning,
10502
- validateSignalsStrict
10502
+ validateSignalsStrict,
10503
+ violate
10503
10504
  } from "@parmanasystems/execution";
10504
10505
  import crypto from "crypto";
10505
10506
  import {
@@ -10535,6 +10536,17 @@ async function executeFromSignals(input, signer, verifier, replayStore) {
10535
10536
  signals: input.signals
10536
10537
  })
10537
10538
  ).digest("hex");
10539
+ const hasRun = await replayStore.hasExecuted(
10540
+ execution_fingerprint
10541
+ );
10542
+ if (hasRun) {
10543
+ violate(
10544
+ "INV-013",
10545
+ "replay",
10546
+ `[INV-013@replay] Replay detected: execution_fingerprint ${execution_fingerprint} has already been consumed`,
10547
+ execution_fingerprint
10548
+ );
10549
+ }
10538
10550
  await replayStore.markExecuted(
10539
10551
  execution_fingerprint
10540
10552
  );
@@ -10640,7 +10652,7 @@ import {
10640
10652
  import {
10641
10653
  INVARIANT_REGISTRY,
10642
10654
  InvariantViolation,
10643
- violate,
10655
+ violate as violate2,
10644
10656
  hashInput
10645
10657
  } from "@parmanasystems/execution";
10646
10658
 
@@ -10877,6 +10889,6 @@ export {
10877
10889
  verifyRuntime,
10878
10890
  verifyRuntimeCompatibility,
10879
10891
  verifyRuntimeManifest,
10880
- violate
10892
+ violate2 as violate
10881
10893
  };
10882
10894
  //# sourceMappingURL=index.js.map