@xyo-network/chain-sdk 5.0.4 → 5.1.0

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.
Files changed (305) hide show
  1. package/dist/browser/index.d.ts +1 -0
  2. package/dist/browser/index.d.ts.map +1 -1
  3. package/dist/browser/index.mjs +1 -0
  4. package/dist/browser/index.mjs.map +2 -2
  5. package/dist/browser/modules/analyze/ChainHeadSelector.d.ts +40 -0
  6. package/dist/browser/modules/analyze/ChainHeadSelector.d.ts.map +1 -1
  7. package/dist/browser/modules/analyze/admission.d.ts +65 -0
  8. package/dist/browser/modules/analyze/admission.d.ts.map +1 -0
  9. package/dist/browser/modules/analyze/index.d.ts +1 -0
  10. package/dist/browser/modules/analyze/index.d.ts.map +1 -1
  11. package/dist/browser/modules/protocol/block/BuildBlockOptions.d.ts +8 -0
  12. package/dist/browser/modules/protocol/block/BuildBlockOptions.d.ts.map +1 -1
  13. package/dist/browser/modules/protocol/block/buildBlock.d.ts.map +1 -1
  14. package/dist/browser/modules/protocol/block/buildNextBlock.d.ts +2 -1
  15. package/dist/browser/modules/protocol/block/buildNextBlock.d.ts.map +1 -1
  16. package/dist/browser/modules/services/implementation/processPendingBlocks.d.ts +9 -1
  17. package/dist/browser/modules/services/implementation/processPendingBlocks.d.ts.map +1 -1
  18. package/dist/browser/modules/services/simple/block/runner/SimpleBlockRunner.d.ts +34 -1
  19. package/dist/browser/modules/services/simple/block/runner/SimpleBlockRunner.d.ts.map +1 -1
  20. package/dist/browser/modules/services/simple/block/runner/index.d.ts +1 -0
  21. package/dist/browser/modules/services/simple/block/runner/index.d.ts.map +1 -1
  22. package/dist/browser/modules/services/simple/block/runner/selectSupersededCandidate.d.ts +22 -0
  23. package/dist/browser/modules/services/simple/block/runner/selectSupersededCandidate.d.ts.map +1 -0
  24. package/dist/browser/modules/slashing/detect/DetectedOffense.d.ts +27 -0
  25. package/dist/browser/modules/slashing/detect/DetectedOffense.d.ts.map +1 -0
  26. package/dist/browser/modules/slashing/detect/candidatePairs.d.ts +44 -0
  27. package/dist/browser/modules/slashing/detect/candidatePairs.d.ts.map +1 -0
  28. package/dist/browser/modules/slashing/detect/index.d.ts +5 -0
  29. package/dist/browser/modules/slashing/detect/index.d.ts.map +1 -0
  30. package/dist/browser/modules/slashing/detect/offenseGate.d.ts +18 -0
  31. package/dist/browser/modules/slashing/detect/offenseGate.d.ts.map +1 -0
  32. package/dist/browser/modules/slashing/detect/suppression.d.ts +23 -0
  33. package/dist/browser/modules/slashing/detect/suppression.d.ts.map +1 -0
  34. package/dist/browser/modules/slashing/eligibility/evaluateProducerEligibility.d.ts +71 -0
  35. package/dist/browser/modules/slashing/eligibility/evaluateProducerEligibility.d.ts.map +1 -0
  36. package/dist/browser/modules/slashing/eligibility/index.d.ts +2 -0
  37. package/dist/browser/modules/slashing/eligibility/index.d.ts.map +1 -0
  38. package/dist/browser/modules/slashing/index/SlashIndexStore.d.ts +22 -0
  39. package/dist/browser/modules/slashing/index/SlashIndexStore.d.ts.map +1 -0
  40. package/dist/browser/modules/slashing/index/foldSlashIndex.d.ts +56 -0
  41. package/dist/browser/modules/slashing/index/foldSlashIndex.d.ts.map +1 -0
  42. package/dist/browser/modules/slashing/index/index.d.ts +3 -0
  43. package/dist/browser/modules/slashing/index/index.d.ts.map +1 -0
  44. package/dist/browser/modules/slashing/index.d.ts +6 -0
  45. package/dist/browser/modules/slashing/index.d.ts.map +1 -0
  46. package/dist/browser/modules/slashing/model/OffenseProcedure.d.ts +28 -0
  47. package/dist/browser/modules/slashing/model/OffenseProcedure.d.ts.map +1 -0
  48. package/dist/browser/modules/slashing/model/OffenseVerificationContext.d.ts +88 -0
  49. package/dist/browser/modules/slashing/model/OffenseVerificationContext.d.ts.map +1 -0
  50. package/dist/browser/modules/slashing/model/SlashHistoryReader.d.ts +34 -0
  51. package/dist/browser/modules/slashing/model/SlashHistoryReader.d.ts.map +1 -0
  52. package/dist/browser/modules/slashing/model/VerificationOutcome.d.ts +39 -0
  53. package/dist/browser/modules/slashing/model/VerificationOutcome.d.ts.map +1 -0
  54. package/dist/browser/modules/slashing/model/index.d.ts +6 -0
  55. package/dist/browser/modules/slashing/model/index.d.ts.map +1 -0
  56. package/dist/browser/modules/slashing/model/offenseKey.d.ts +42 -0
  57. package/dist/browser/modules/slashing/model/offenseKey.d.ts.map +1 -0
  58. package/dist/browser/modules/slashing/verify/index.d.ts +10 -0
  59. package/dist/browser/modules/slashing/verify/index.d.ts.map +1 -0
  60. package/dist/browser/modules/slashing/verify/preamble.d.ts +63 -0
  61. package/dist/browser/modules/slashing/verify/preamble.d.ts.map +1 -0
  62. package/dist/browser/modules/slashing/verify/verifyEquivocation.d.ts +19 -0
  63. package/dist/browser/modules/slashing/verify/verifyEquivocation.d.ts.map +1 -0
  64. package/dist/browser/modules/slashing/verify/verifyFalseAnchor.d.ts +15 -0
  65. package/dist/browser/modules/slashing/verify/verifyFalseAnchor.d.ts.map +1 -0
  66. package/dist/browser/modules/slashing/verify/verifyFalseAttestation.d.ts +22 -0
  67. package/dist/browser/modules/slashing/verify/verifyFalseAttestation.d.ts.map +1 -0
  68. package/dist/browser/modules/slashing/verify/verifyIneligibleProduction.d.ts +18 -0
  69. package/dist/browser/modules/slashing/verify/verifyIneligibleProduction.d.ts.map +1 -0
  70. package/dist/browser/modules/slashing/verify/verifyInvalidBlock.d.ts +18 -0
  71. package/dist/browser/modules/slashing/verify/verifyInvalidBlock.d.ts.map +1 -0
  72. package/dist/browser/modules/slashing/verify/verifyInvalidSlashRequest.d.ts +11 -0
  73. package/dist/browser/modules/slashing/verify/verifyInvalidSlashRequest.d.ts.map +1 -0
  74. package/dist/browser/modules/slashing/verify/verifyOffense.d.ts +29 -0
  75. package/dist/browser/modules/slashing/verify/verifyOffense.d.ts.map +1 -0
  76. package/dist/browser/modules/slashing/verify/verifyRewardOvermint.d.ts +23 -0
  77. package/dist/browser/modules/slashing/verify/verifyRewardOvermint.d.ts.map +1 -0
  78. package/dist/browser/modules/validation/elevatedPayload/lib/findElevatingTransaction.d.ts +14 -0
  79. package/dist/browser/modules/validation/elevatedPayload/lib/findElevatingTransaction.d.ts.map +1 -0
  80. package/dist/browser/modules/validation/elevatedPayload/lib/index.d.ts +2 -0
  81. package/dist/browser/modules/validation/elevatedPayload/lib/index.d.ts.map +1 -1
  82. package/dist/browser/modules/validation/elevatedPayload/lib/validateSlashPayloadInBlock.d.ts +33 -0
  83. package/dist/browser/modules/validation/elevatedPayload/lib/validateSlashPayloadInBlock.d.ts.map +1 -0
  84. package/dist/browser/modules/validation/elevatedPayload/payloads/index.d.ts +5 -0
  85. package/dist/browser/modules/validation/elevatedPayload/payloads/index.d.ts.map +1 -1
  86. package/dist/browser/modules/validation/elevatedPayload/payloads/validateSlashAdjudicationInBlock.d.ts +14 -0
  87. package/dist/browser/modules/validation/elevatedPayload/payloads/validateSlashAdjudicationInBlock.d.ts.map +1 -0
  88. package/dist/browser/modules/validation/elevatedPayload/payloads/validateSlashChallengeInBlock.d.ts +10 -0
  89. package/dist/browser/modules/validation/elevatedPayload/payloads/validateSlashChallengeInBlock.d.ts.map +1 -0
  90. package/dist/browser/modules/validation/elevatedPayload/payloads/validateSlashCommitInBlock.d.ts +10 -0
  91. package/dist/browser/modules/validation/elevatedPayload/payloads/validateSlashCommitInBlock.d.ts.map +1 -0
  92. package/dist/browser/modules/validation/elevatedPayload/payloads/validateSlashEvidenceInBlock.d.ts +10 -0
  93. package/dist/browser/modules/validation/elevatedPayload/payloads/validateSlashEvidenceInBlock.d.ts.map +1 -0
  94. package/dist/browser/modules/validation/elevatedPayload/payloads/validateSlashRequestInBlock.d.ts +14 -0
  95. package/dist/browser/modules/validation/elevatedPayload/payloads/validateSlashRequestInBlock.d.ts.map +1 -0
  96. package/dist/browser/modules/validation/elevatedPayload/validatePayloadInBlock.d.ts.map +1 -1
  97. package/dist/browser/slashing.d.ts +2 -0
  98. package/dist/browser/slashing.d.ts.map +1 -0
  99. package/dist/neutral/analyze.mjs +85 -3
  100. package/dist/neutral/analyze.mjs.map +3 -3
  101. package/dist/neutral/index.d.ts +1 -0
  102. package/dist/neutral/index.d.ts.map +1 -1
  103. package/dist/neutral/index.mjs +1 -0
  104. package/dist/neutral/index.mjs.map +2 -2
  105. package/dist/neutral/modules/analyze/ChainHeadSelector.d.ts +40 -0
  106. package/dist/neutral/modules/analyze/ChainHeadSelector.d.ts.map +1 -1
  107. package/dist/neutral/modules/analyze/admission.d.ts +65 -0
  108. package/dist/neutral/modules/analyze/admission.d.ts.map +1 -0
  109. package/dist/neutral/modules/analyze/index.d.ts +1 -0
  110. package/dist/neutral/modules/analyze/index.d.ts.map +1 -1
  111. package/dist/neutral/modules/protocol/block/BuildBlockOptions.d.ts +8 -0
  112. package/dist/neutral/modules/protocol/block/BuildBlockOptions.d.ts.map +1 -1
  113. package/dist/neutral/modules/protocol/block/buildBlock.d.ts.map +1 -1
  114. package/dist/neutral/modules/protocol/block/buildNextBlock.d.ts +2 -1
  115. package/dist/neutral/modules/protocol/block/buildNextBlock.d.ts.map +1 -1
  116. package/dist/neutral/modules/services/implementation/processPendingBlocks.d.ts +9 -1
  117. package/dist/neutral/modules/services/implementation/processPendingBlocks.d.ts.map +1 -1
  118. package/dist/neutral/modules/services/simple/block/runner/SimpleBlockRunner.d.ts +34 -1
  119. package/dist/neutral/modules/services/simple/block/runner/SimpleBlockRunner.d.ts.map +1 -1
  120. package/dist/neutral/modules/services/simple/block/runner/index.d.ts +1 -0
  121. package/dist/neutral/modules/services/simple/block/runner/index.d.ts.map +1 -1
  122. package/dist/neutral/modules/services/simple/block/runner/selectSupersededCandidate.d.ts +22 -0
  123. package/dist/neutral/modules/services/simple/block/runner/selectSupersededCandidate.d.ts.map +1 -0
  124. package/dist/neutral/modules/slashing/detect/DetectedOffense.d.ts +27 -0
  125. package/dist/neutral/modules/slashing/detect/DetectedOffense.d.ts.map +1 -0
  126. package/dist/neutral/modules/slashing/detect/candidatePairs.d.ts +44 -0
  127. package/dist/neutral/modules/slashing/detect/candidatePairs.d.ts.map +1 -0
  128. package/dist/neutral/modules/slashing/detect/index.d.ts +5 -0
  129. package/dist/neutral/modules/slashing/detect/index.d.ts.map +1 -0
  130. package/dist/neutral/modules/slashing/detect/offenseGate.d.ts +18 -0
  131. package/dist/neutral/modules/slashing/detect/offenseGate.d.ts.map +1 -0
  132. package/dist/neutral/modules/slashing/detect/suppression.d.ts +23 -0
  133. package/dist/neutral/modules/slashing/detect/suppression.d.ts.map +1 -0
  134. package/dist/neutral/modules/slashing/eligibility/evaluateProducerEligibility.d.ts +71 -0
  135. package/dist/neutral/modules/slashing/eligibility/evaluateProducerEligibility.d.ts.map +1 -0
  136. package/dist/neutral/modules/slashing/eligibility/index.d.ts +2 -0
  137. package/dist/neutral/modules/slashing/eligibility/index.d.ts.map +1 -0
  138. package/dist/neutral/modules/slashing/index/SlashIndexStore.d.ts +22 -0
  139. package/dist/neutral/modules/slashing/index/SlashIndexStore.d.ts.map +1 -0
  140. package/dist/neutral/modules/slashing/index/foldSlashIndex.d.ts +56 -0
  141. package/dist/neutral/modules/slashing/index/foldSlashIndex.d.ts.map +1 -0
  142. package/dist/neutral/modules/slashing/index/index.d.ts +3 -0
  143. package/dist/neutral/modules/slashing/index/index.d.ts.map +1 -0
  144. package/dist/neutral/modules/slashing/index.d.ts +6 -0
  145. package/dist/neutral/modules/slashing/index.d.ts.map +1 -0
  146. package/dist/neutral/modules/slashing/model/OffenseProcedure.d.ts +28 -0
  147. package/dist/neutral/modules/slashing/model/OffenseProcedure.d.ts.map +1 -0
  148. package/dist/neutral/modules/slashing/model/OffenseVerificationContext.d.ts +88 -0
  149. package/dist/neutral/modules/slashing/model/OffenseVerificationContext.d.ts.map +1 -0
  150. package/dist/neutral/modules/slashing/model/SlashHistoryReader.d.ts +34 -0
  151. package/dist/neutral/modules/slashing/model/SlashHistoryReader.d.ts.map +1 -0
  152. package/dist/neutral/modules/slashing/model/VerificationOutcome.d.ts +39 -0
  153. package/dist/neutral/modules/slashing/model/VerificationOutcome.d.ts.map +1 -0
  154. package/dist/neutral/modules/slashing/model/index.d.ts +6 -0
  155. package/dist/neutral/modules/slashing/model/index.d.ts.map +1 -0
  156. package/dist/neutral/modules/slashing/model/offenseKey.d.ts +42 -0
  157. package/dist/neutral/modules/slashing/model/offenseKey.d.ts.map +1 -0
  158. package/dist/neutral/modules/slashing/verify/index.d.ts +10 -0
  159. package/dist/neutral/modules/slashing/verify/index.d.ts.map +1 -0
  160. package/dist/neutral/modules/slashing/verify/preamble.d.ts +63 -0
  161. package/dist/neutral/modules/slashing/verify/preamble.d.ts.map +1 -0
  162. package/dist/neutral/modules/slashing/verify/verifyEquivocation.d.ts +19 -0
  163. package/dist/neutral/modules/slashing/verify/verifyEquivocation.d.ts.map +1 -0
  164. package/dist/neutral/modules/slashing/verify/verifyFalseAnchor.d.ts +15 -0
  165. package/dist/neutral/modules/slashing/verify/verifyFalseAnchor.d.ts.map +1 -0
  166. package/dist/neutral/modules/slashing/verify/verifyFalseAttestation.d.ts +22 -0
  167. package/dist/neutral/modules/slashing/verify/verifyFalseAttestation.d.ts.map +1 -0
  168. package/dist/neutral/modules/slashing/verify/verifyIneligibleProduction.d.ts +18 -0
  169. package/dist/neutral/modules/slashing/verify/verifyIneligibleProduction.d.ts.map +1 -0
  170. package/dist/neutral/modules/slashing/verify/verifyInvalidBlock.d.ts +18 -0
  171. package/dist/neutral/modules/slashing/verify/verifyInvalidBlock.d.ts.map +1 -0
  172. package/dist/neutral/modules/slashing/verify/verifyInvalidSlashRequest.d.ts +11 -0
  173. package/dist/neutral/modules/slashing/verify/verifyInvalidSlashRequest.d.ts.map +1 -0
  174. package/dist/neutral/modules/slashing/verify/verifyOffense.d.ts +29 -0
  175. package/dist/neutral/modules/slashing/verify/verifyOffense.d.ts.map +1 -0
  176. package/dist/neutral/modules/slashing/verify/verifyRewardOvermint.d.ts +23 -0
  177. package/dist/neutral/modules/slashing/verify/verifyRewardOvermint.d.ts.map +1 -0
  178. package/dist/neutral/modules/validation/elevatedPayload/lib/findElevatingTransaction.d.ts +14 -0
  179. package/dist/neutral/modules/validation/elevatedPayload/lib/findElevatingTransaction.d.ts.map +1 -0
  180. package/dist/neutral/modules/validation/elevatedPayload/lib/index.d.ts +2 -0
  181. package/dist/neutral/modules/validation/elevatedPayload/lib/index.d.ts.map +1 -1
  182. package/dist/neutral/modules/validation/elevatedPayload/lib/validateSlashPayloadInBlock.d.ts +33 -0
  183. package/dist/neutral/modules/validation/elevatedPayload/lib/validateSlashPayloadInBlock.d.ts.map +1 -0
  184. package/dist/neutral/modules/validation/elevatedPayload/payloads/index.d.ts +5 -0
  185. package/dist/neutral/modules/validation/elevatedPayload/payloads/index.d.ts.map +1 -1
  186. package/dist/neutral/modules/validation/elevatedPayload/payloads/validateSlashAdjudicationInBlock.d.ts +14 -0
  187. package/dist/neutral/modules/validation/elevatedPayload/payloads/validateSlashAdjudicationInBlock.d.ts.map +1 -0
  188. package/dist/neutral/modules/validation/elevatedPayload/payloads/validateSlashChallengeInBlock.d.ts +10 -0
  189. package/dist/neutral/modules/validation/elevatedPayload/payloads/validateSlashChallengeInBlock.d.ts.map +1 -0
  190. package/dist/neutral/modules/validation/elevatedPayload/payloads/validateSlashCommitInBlock.d.ts +10 -0
  191. package/dist/neutral/modules/validation/elevatedPayload/payloads/validateSlashCommitInBlock.d.ts.map +1 -0
  192. package/dist/neutral/modules/validation/elevatedPayload/payloads/validateSlashEvidenceInBlock.d.ts +10 -0
  193. package/dist/neutral/modules/validation/elevatedPayload/payloads/validateSlashEvidenceInBlock.d.ts.map +1 -0
  194. package/dist/neutral/modules/validation/elevatedPayload/payloads/validateSlashRequestInBlock.d.ts +14 -0
  195. package/dist/neutral/modules/validation/elevatedPayload/payloads/validateSlashRequestInBlock.d.ts.map +1 -0
  196. package/dist/neutral/modules/validation/elevatedPayload/validatePayloadInBlock.d.ts.map +1 -1
  197. package/dist/neutral/protocol.mjs +8 -3
  198. package/dist/neutral/protocol.mjs.map +2 -2
  199. package/dist/neutral/services.mjs +77 -7
  200. package/dist/neutral/services.mjs.map +4 -4
  201. package/dist/neutral/slashing.d.ts +2 -0
  202. package/dist/neutral/slashing.d.ts.map +1 -0
  203. package/dist/neutral/slashing.mjs +824 -0
  204. package/dist/neutral/slashing.mjs.map +7 -0
  205. package/dist/neutral/validation.mjs +274 -43
  206. package/dist/neutral/validation.mjs.map +4 -4
  207. package/dist/node/index.d.ts +1 -0
  208. package/dist/node/index.d.ts.map +1 -1
  209. package/dist/node/index.mjs +1 -0
  210. package/dist/node/index.mjs.map +2 -2
  211. package/dist/node/modules/analyze/ChainHeadSelector.d.ts +40 -0
  212. package/dist/node/modules/analyze/ChainHeadSelector.d.ts.map +1 -1
  213. package/dist/node/modules/analyze/admission.d.ts +65 -0
  214. package/dist/node/modules/analyze/admission.d.ts.map +1 -0
  215. package/dist/node/modules/analyze/index.d.ts +1 -0
  216. package/dist/node/modules/analyze/index.d.ts.map +1 -1
  217. package/dist/node/modules/protocol/block/BuildBlockOptions.d.ts +8 -0
  218. package/dist/node/modules/protocol/block/BuildBlockOptions.d.ts.map +1 -1
  219. package/dist/node/modules/protocol/block/buildBlock.d.ts.map +1 -1
  220. package/dist/node/modules/protocol/block/buildNextBlock.d.ts +2 -1
  221. package/dist/node/modules/protocol/block/buildNextBlock.d.ts.map +1 -1
  222. package/dist/node/modules/services/implementation/processPendingBlocks.d.ts +9 -1
  223. package/dist/node/modules/services/implementation/processPendingBlocks.d.ts.map +1 -1
  224. package/dist/node/modules/services/simple/block/runner/SimpleBlockRunner.d.ts +34 -1
  225. package/dist/node/modules/services/simple/block/runner/SimpleBlockRunner.d.ts.map +1 -1
  226. package/dist/node/modules/services/simple/block/runner/index.d.ts +1 -0
  227. package/dist/node/modules/services/simple/block/runner/index.d.ts.map +1 -1
  228. package/dist/node/modules/services/simple/block/runner/selectSupersededCandidate.d.ts +22 -0
  229. package/dist/node/modules/services/simple/block/runner/selectSupersededCandidate.d.ts.map +1 -0
  230. package/dist/node/modules/slashing/detect/DetectedOffense.d.ts +27 -0
  231. package/dist/node/modules/slashing/detect/DetectedOffense.d.ts.map +1 -0
  232. package/dist/node/modules/slashing/detect/candidatePairs.d.ts +44 -0
  233. package/dist/node/modules/slashing/detect/candidatePairs.d.ts.map +1 -0
  234. package/dist/node/modules/slashing/detect/index.d.ts +5 -0
  235. package/dist/node/modules/slashing/detect/index.d.ts.map +1 -0
  236. package/dist/node/modules/slashing/detect/offenseGate.d.ts +18 -0
  237. package/dist/node/modules/slashing/detect/offenseGate.d.ts.map +1 -0
  238. package/dist/node/modules/slashing/detect/suppression.d.ts +23 -0
  239. package/dist/node/modules/slashing/detect/suppression.d.ts.map +1 -0
  240. package/dist/node/modules/slashing/eligibility/evaluateProducerEligibility.d.ts +71 -0
  241. package/dist/node/modules/slashing/eligibility/evaluateProducerEligibility.d.ts.map +1 -0
  242. package/dist/node/modules/slashing/eligibility/index.d.ts +2 -0
  243. package/dist/node/modules/slashing/eligibility/index.d.ts.map +1 -0
  244. package/dist/node/modules/slashing/index/SlashIndexStore.d.ts +22 -0
  245. package/dist/node/modules/slashing/index/SlashIndexStore.d.ts.map +1 -0
  246. package/dist/node/modules/slashing/index/foldSlashIndex.d.ts +56 -0
  247. package/dist/node/modules/slashing/index/foldSlashIndex.d.ts.map +1 -0
  248. package/dist/node/modules/slashing/index/index.d.ts +3 -0
  249. package/dist/node/modules/slashing/index/index.d.ts.map +1 -0
  250. package/dist/node/modules/slashing/index.d.ts +6 -0
  251. package/dist/node/modules/slashing/index.d.ts.map +1 -0
  252. package/dist/node/modules/slashing/model/OffenseProcedure.d.ts +28 -0
  253. package/dist/node/modules/slashing/model/OffenseProcedure.d.ts.map +1 -0
  254. package/dist/node/modules/slashing/model/OffenseVerificationContext.d.ts +88 -0
  255. package/dist/node/modules/slashing/model/OffenseVerificationContext.d.ts.map +1 -0
  256. package/dist/node/modules/slashing/model/SlashHistoryReader.d.ts +34 -0
  257. package/dist/node/modules/slashing/model/SlashHistoryReader.d.ts.map +1 -0
  258. package/dist/node/modules/slashing/model/VerificationOutcome.d.ts +39 -0
  259. package/dist/node/modules/slashing/model/VerificationOutcome.d.ts.map +1 -0
  260. package/dist/node/modules/slashing/model/index.d.ts +6 -0
  261. package/dist/node/modules/slashing/model/index.d.ts.map +1 -0
  262. package/dist/node/modules/slashing/model/offenseKey.d.ts +42 -0
  263. package/dist/node/modules/slashing/model/offenseKey.d.ts.map +1 -0
  264. package/dist/node/modules/slashing/verify/index.d.ts +10 -0
  265. package/dist/node/modules/slashing/verify/index.d.ts.map +1 -0
  266. package/dist/node/modules/slashing/verify/preamble.d.ts +63 -0
  267. package/dist/node/modules/slashing/verify/preamble.d.ts.map +1 -0
  268. package/dist/node/modules/slashing/verify/verifyEquivocation.d.ts +19 -0
  269. package/dist/node/modules/slashing/verify/verifyEquivocation.d.ts.map +1 -0
  270. package/dist/node/modules/slashing/verify/verifyFalseAnchor.d.ts +15 -0
  271. package/dist/node/modules/slashing/verify/verifyFalseAnchor.d.ts.map +1 -0
  272. package/dist/node/modules/slashing/verify/verifyFalseAttestation.d.ts +22 -0
  273. package/dist/node/modules/slashing/verify/verifyFalseAttestation.d.ts.map +1 -0
  274. package/dist/node/modules/slashing/verify/verifyIneligibleProduction.d.ts +18 -0
  275. package/dist/node/modules/slashing/verify/verifyIneligibleProduction.d.ts.map +1 -0
  276. package/dist/node/modules/slashing/verify/verifyInvalidBlock.d.ts +18 -0
  277. package/dist/node/modules/slashing/verify/verifyInvalidBlock.d.ts.map +1 -0
  278. package/dist/node/modules/slashing/verify/verifyInvalidSlashRequest.d.ts +11 -0
  279. package/dist/node/modules/slashing/verify/verifyInvalidSlashRequest.d.ts.map +1 -0
  280. package/dist/node/modules/slashing/verify/verifyOffense.d.ts +29 -0
  281. package/dist/node/modules/slashing/verify/verifyOffense.d.ts.map +1 -0
  282. package/dist/node/modules/slashing/verify/verifyRewardOvermint.d.ts +23 -0
  283. package/dist/node/modules/slashing/verify/verifyRewardOvermint.d.ts.map +1 -0
  284. package/dist/node/modules/validation/elevatedPayload/lib/findElevatingTransaction.d.ts +14 -0
  285. package/dist/node/modules/validation/elevatedPayload/lib/findElevatingTransaction.d.ts.map +1 -0
  286. package/dist/node/modules/validation/elevatedPayload/lib/index.d.ts +2 -0
  287. package/dist/node/modules/validation/elevatedPayload/lib/index.d.ts.map +1 -1
  288. package/dist/node/modules/validation/elevatedPayload/lib/validateSlashPayloadInBlock.d.ts +33 -0
  289. package/dist/node/modules/validation/elevatedPayload/lib/validateSlashPayloadInBlock.d.ts.map +1 -0
  290. package/dist/node/modules/validation/elevatedPayload/payloads/index.d.ts +5 -0
  291. package/dist/node/modules/validation/elevatedPayload/payloads/index.d.ts.map +1 -1
  292. package/dist/node/modules/validation/elevatedPayload/payloads/validateSlashAdjudicationInBlock.d.ts +14 -0
  293. package/dist/node/modules/validation/elevatedPayload/payloads/validateSlashAdjudicationInBlock.d.ts.map +1 -0
  294. package/dist/node/modules/validation/elevatedPayload/payloads/validateSlashChallengeInBlock.d.ts +10 -0
  295. package/dist/node/modules/validation/elevatedPayload/payloads/validateSlashChallengeInBlock.d.ts.map +1 -0
  296. package/dist/node/modules/validation/elevatedPayload/payloads/validateSlashCommitInBlock.d.ts +10 -0
  297. package/dist/node/modules/validation/elevatedPayload/payloads/validateSlashCommitInBlock.d.ts.map +1 -0
  298. package/dist/node/modules/validation/elevatedPayload/payloads/validateSlashEvidenceInBlock.d.ts +10 -0
  299. package/dist/node/modules/validation/elevatedPayload/payloads/validateSlashEvidenceInBlock.d.ts.map +1 -0
  300. package/dist/node/modules/validation/elevatedPayload/payloads/validateSlashRequestInBlock.d.ts +14 -0
  301. package/dist/node/modules/validation/elevatedPayload/payloads/validateSlashRequestInBlock.d.ts.map +1 -0
  302. package/dist/node/modules/validation/elevatedPayload/validatePayloadInBlock.d.ts.map +1 -1
  303. package/dist/node/slashing.d.ts +2 -0
  304. package/dist/node/slashing.d.ts.map +1 -0
  305. package/package.json +11 -5
@@ -0,0 +1,63 @@
1
+ import type { Hash, JsonObject } from '@ariestools/sdk';
2
+ import type { SlashRequest } from '@xyo-network/xl1-sdk';
3
+ import type { VerifiedArtifact } from '../model/OffenseProcedure.js';
4
+ import type { OffenseVerificationContext } from '../model/OffenseVerificationContext.js';
5
+ import type { OffenseVerdict } from '../model/VerificationOutcome.js';
6
+ /** What re-checking a report's cited artifacts concluded. */
7
+ export type ArtifactCheck = {
8
+ byHash: Map<Hash, VerifiedArtifact>;
9
+ ok: true;
10
+ } | {
11
+ missing?: boolean;
12
+ ok: false;
13
+ reason: string;
14
+ };
15
+ /**
16
+ * Re-derives every cited artifact's identity and checks its signatures.
17
+ *
18
+ * Identity is recomputed, never taken from the report. A reporter naming a hash it did not supply
19
+ * is asserting something no one can check, and accepting that claim is how a fabricated report
20
+ * would pass — the artifact has to hash to the thing it was cited as.
21
+ *
22
+ * Signature failures are provably invalid rather than indeterminate: nothing about a bad signature
23
+ * depends on what this verifier can see, so every honest verifier reaches the same conclusion. An
24
+ * artifact this verifier simply cannot see is the opposite case — `missing` marks it, and callers
25
+ * map it to indeterminate, because what a verifier failed to retain says nothing about a reporter.
26
+ * @param artifacts The artifacts supplied with the report, keyed by claimed hash
27
+ * @param referenced The hashes the report cited
28
+ * @returns The artifacts by recomputed hash, or why the citation failed
29
+ */
30
+ export declare function verifyArtifacts(artifacts: ReadonlyMap<Hash, JsonObject>, referenced: readonly Hash[]): Promise<ArtifactCheck>;
31
+ /**
32
+ * Whether a signed reference points at this artifact.
33
+ *
34
+ * Signed documents reference each other by hash, but which form — data or meta-inclusive —
35
+ * depends on who wrote the reference. Both are recomputed from the artifact itself, so a match
36
+ * never rests on a hash the supplier merely claimed.
37
+ */
38
+ export declare function referencesArtifact(reference: Hash | null | undefined, artifact: VerifiedArtifact): Promise<boolean>;
39
+ /** How the freshness gate resolved, and the anchors it measured between. */
40
+ export interface FreshnessResult {
41
+ /** EVM anchor at the offense. */
42
+ eOff?: number;
43
+ /** EVM anchor at submission. */
44
+ eSub?: number;
45
+ /** Why it concluded what it did. */
46
+ reason: string;
47
+ /** Set when the report cannot proceed. */
48
+ verdict?: OffenseVerdict;
49
+ }
50
+ /**
51
+ * Whether a report was filed while its offense was still fresh.
52
+ *
53
+ * Both ends are measured on the EVM clock rather than the chain's own, because the chain's clock
54
+ * is exactly what a misbehaving producer controls. Anchors are what a reporter cannot forge.
55
+ *
56
+ * An unresolvable anchor is indeterminate, not stale: a verifier that has pruned the history is
57
+ * making a statement about itself, not about the reporter.
58
+ * @param ctx What the verifier may consult
59
+ * @param request The report being checked
60
+ * @returns The measured anchors, and a verdict when the report cannot proceed
61
+ */
62
+ export declare function freshnessGate(ctx: OffenseVerificationContext, request: SlashRequest): Promise<FreshnessResult>;
63
+ //# sourceMappingURL=preamble.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"preamble.d.ts","sourceRoot":"","sources":["../../../../../src/modules/slashing/verify/preamble.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AAGvD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAA;AAGxD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAA;AACpE,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,wCAAwC,CAAA;AACxF,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAA;AAGrE,6DAA6D;AAC7D,MAAM,MAAM,aAAa,GACnB;IAAE,MAAM,EAAE,GAAG,CAAC,IAAI,EAAE,gBAAgB,CAAC,CAAC;IAAC,EAAE,EAAE,IAAI,CAAA;CAAE,GACjD;IAAE,OAAO,CAAC,EAAE,OAAO,CAAC;IAAC,EAAE,EAAE,KAAK,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,CAAA;AAEtD;;;;;;;;;;;;;;GAcG;AACH,wBAAsB,eAAe,CACnC,SAAS,EAAE,WAAW,CAAC,IAAI,EAAE,UAAU,CAAC,EACxC,UAAU,EAAE,SAAS,IAAI,EAAE,GAC1B,OAAO,CAAC,aAAa,CAAC,CA0BxB;AAED;;;;;;GAMG;AACH,wBAAsB,kBAAkB,CAAC,SAAS,EAAE,IAAI,GAAG,IAAI,GAAG,SAAS,EAAE,QAAQ,EAAE,gBAAgB,GAAG,OAAO,CAAC,OAAO,CAAC,CAKzH;AAED,4EAA4E;AAC5E,MAAM,WAAW,eAAe;IAC9B,iCAAiC;IACjC,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,gCAAgC;IAChC,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,oCAAoC;IACpC,MAAM,EAAE,MAAM,CAAA;IACd,0CAA0C;IAC1C,OAAO,CAAC,EAAE,cAAc,CAAA;CACzB;AAED;;;;;;;;;;;GAWG;AACH,wBAAsB,aAAa,CACjC,GAAG,EAAE,0BAA0B,EAC/B,OAAO,EAAE,YAAY,GACpB,OAAO,CAAC,eAAe,CAAC,CAgC1B"}
@@ -0,0 +1,19 @@
1
+ import type { OffenseProcedure } from '../model/OffenseProcedure.js';
2
+ /**
3
+ * O1 — equivocation: signing two competing candidates for the same slot.
4
+ *
5
+ * Producing two blocks is not by itself misconduct. A producer whose candidate goes stale is
6
+ * expected to re-propose, and the honest way to do that is to say which candidate the new one
7
+ * replaces. What this procedure looks for is two candidates that compete without any such
8
+ * statement.
9
+ *
10
+ * It is deliberately self-contained: everything it needs is in the two artifacts, so it never
11
+ * returns indeterminate. Two verifiers holding the same pair always agree, which matters because
12
+ * this is the offense most likely to be reported by someone with a partial view of the chain.
13
+ *
14
+ * The accused's own defense — producing the missing link later — is not evaluated here. That
15
+ * arrives during the challenge window and is an adjudication-level `refuted`, not a reason for
16
+ * this procedure to withhold a verdict.
17
+ */
18
+ export declare const verifyEquivocation: OffenseProcedure;
19
+ //# sourceMappingURL=verifyEquivocation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"verifyEquivocation.d.ts","sourceRoot":"","sources":["../../../../../src/modules/slashing/verify/verifyEquivocation.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,gBAAgB,EAAoB,MAAM,8BAA8B,CAAA;AActF;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,kBAAkB,EAAE,gBAmDhC,CAAA"}
@@ -0,0 +1,15 @@
1
+ import type { OffenseProcedure } from '../model/OffenseProcedure.js';
2
+ /**
3
+ * O4 — false anchor: pointing a block at an EVM block that is not where it says it is.
4
+ *
5
+ * Two shapes, and they differ in what they cost to prove. An anchor that moves backwards is
6
+ * settled by the two blocks alone: the chain's anchor is required to be monotonic, so a child
7
+ * claiming an earlier height than its parent contradicts itself, and no external view is needed.
8
+ *
9
+ * The other shape — an anchor naming a hash the EVM never had at that height — needs the EVM
10
+ * itself, and it needs to have settled. Judging before the maturity depth has passed would let a
11
+ * reorg convict an honest producer for a block that was canonical when it anchored. Until then the
12
+ * answer is that it is too early to say, which is not the same as saying nothing happened.
13
+ */
14
+ export declare const verifyFalseAnchor: OffenseProcedure;
15
+ //# sourceMappingURL=verifyFalseAnchor.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"verifyFalseAnchor.d.ts","sourceRoot":"","sources":["../../../../../src/modules/slashing/verify/verifyFalseAnchor.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,gBAAgB,EAAoB,MAAM,8BAA8B,CAAA;AAmDtF;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,iBAAiB,EAAE,gBAmD/B,CAAA"}
@@ -0,0 +1,22 @@
1
+ import type { OffenseProcedure } from '../model/OffenseProcedure.js';
2
+ /**
3
+ * O7 — false attestation: signing an attestation for a step that says something else.
4
+ *
5
+ * Two branches, and the second one is weaker than the first on purpose.
6
+ *
7
+ * When the attested block is supplied, the question is closed: the block states its own step
8
+ * hashes, so an attestation naming a different one at the attested level contradicts a signed
9
+ * document and nothing external is needed. Self-contained claims are judged before any retention
10
+ * arithmetic — a contradiction between two supplied documents does not age out.
11
+ *
12
+ * When no block is supplied, the claim is that the attested block never existed. That is a claim
13
+ * about absence, and absence is exactly what a verifier with an incomplete view would also see.
14
+ * A verdict here is therefore marked provisional: it is enough to open the question, not to close
15
+ * it, and whoever adjudicates has to let the accused produce the block before acting.
16
+ *
17
+ * Past the retention window the absence claim is indeterminate rather than provisional. Once the
18
+ * chain no longer requires anyone to hold the block, absence stops being evidence of anything at
19
+ * all — treating it as proof would turn the retention policy into a conviction engine.
20
+ */
21
+ export declare const verifyFalseAttestation: OffenseProcedure;
22
+ //# sourceMappingURL=verifyFalseAttestation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"verifyFalseAttestation.d.ts","sourceRoot":"","sources":["../../../../../src/modules/slashing/verify/verifyFalseAttestation.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,gBAAgB,EAAoB,MAAM,8BAA8B,CAAA;AAqCtF;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,sBAAsB,EAAE,gBA4DpC,CAAA"}
@@ -0,0 +1,18 @@
1
+ import type { OffenseProcedure } from '../model/OffenseProcedure.js';
2
+ /**
3
+ * O5 — ineligible production: producing a block without the standing to produce it.
4
+ *
5
+ * The measurement point is recomputed from the two blocks' own signed anchors rather than taken
6
+ * from the report or from a live EVM head. That is what makes admission and after-the-fact
7
+ * verification ask the same question: a block that was admissible when it was produced must not
8
+ * become an offense later because stake moved in the meantime.
9
+ *
10
+ * Both halves of the predicate matter. Stake alone says an address *could* participate; the intent
11
+ * declaration is how it says it *is*. Seasoning is what stops standing being rented for a block.
12
+ *
13
+ * Everything here depends on external state — stake as it stood at an EVM height — so an
14
+ * unreadable snapshot is indeterminate. A verifier without that history has no opinion, and
15
+ * pretending otherwise would convict on the basis of not having looked.
16
+ */
17
+ export declare const verifyIneligibleProduction: OffenseProcedure;
18
+ //# sourceMappingURL=verifyIneligibleProduction.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"verifyIneligibleProduction.d.ts","sourceRoot":"","sources":["../../../../../src/modules/slashing/verify/verifyIneligibleProduction.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,gBAAgB,EAAoB,MAAM,8BAA8B,CAAA;AAwCtF;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,0BAA0B,EAAE,gBA+CxC,CAAA"}
@@ -0,0 +1,18 @@
1
+ import type { OffenseProcedure } from '../model/OffenseProcedure.js';
2
+ /**
3
+ * O2 — invalid block: finalizing a block that breaks the rules in force at its height.
4
+ *
5
+ * Only rules that reproduce identically on every node are replayed. Admission gates are excluded
6
+ * by construction: whether a candidate was admitted depends on what a particular node had in its
7
+ * pool at a particular moment, so re-running one later would convict a producer for someone
8
+ * else's timing.
9
+ *
10
+ * Nothing the reporter supplied is trusted as state. The parent and the balances come from this
11
+ * verifier's own canonical history, because a report that carried its own version of history
12
+ * could prove anything it liked.
13
+ *
14
+ * An unresolvable parent is indeterminate rather than a finding. A verifier that has pruned past
15
+ * the offense knows nothing about the block — that is a fact about the verifier.
16
+ */
17
+ export declare const verifyInvalidBlock: OffenseProcedure;
18
+ //# sourceMappingURL=verifyInvalidBlock.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"verifyInvalidBlock.d.ts","sourceRoot":"","sources":["../../../../../src/modules/slashing/verify/verifyInvalidBlock.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,gBAAgB,EAAoB,MAAM,8BAA8B,CAAA;AAgDtF;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,kBAAkB,EAAE,gBA0ChC,CAAA"}
@@ -0,0 +1,11 @@
1
+ import type { OffenseCode } from '@xyo-network/xl1-sdk';
2
+ import type { OffenseProcedure } from '../model/OffenseProcedure.js';
3
+ /**
4
+ * Builds the invalid-slash-request procedure over a registry it resolves at call time.
5
+ *
6
+ * The registry is passed as a thunk rather than imported, because this procedure lives inside the
7
+ * same registry it needs. Deferring the lookup keeps that self-reference within one module instead
8
+ * of turning it into an import cycle between two.
9
+ */
10
+ export declare function createVerifyInvalidSlashRequest(resolve: () => Partial<Record<OffenseCode, OffenseProcedure>>): OffenseProcedure;
11
+ //# sourceMappingURL=verifyInvalidSlashRequest.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"verifyInvalidSlashRequest.d.ts","sourceRoot":"","sources":["../../../../../src/modules/slashing/verify/verifyInvalidSlashRequest.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAgB,MAAM,sBAAsB,CAAA;AAIrE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAA;AAYpE;;;;;;GAMG;AACH,wBAAgB,+BAA+B,CAC7C,OAAO,EAAE,MAAM,OAAO,CAAC,MAAM,CAAC,WAAW,EAAE,gBAAgB,CAAC,CAAC,GAC5D,gBAAgB,CAkFlB"}
@@ -0,0 +1,29 @@
1
+ import type { OffenseCode, SlashRequest } from '@xyo-network/xl1-sdk';
2
+ import type { OffenseProcedure } from '../model/OffenseProcedure.js';
3
+ import type { OffenseVerificationContext } from '../model/OffenseVerificationContext.js';
4
+ import type { OffenseVerdict } from '../model/VerificationOutcome.js';
5
+ /**
6
+ * The procedure for each offense class.
7
+ *
8
+ * Exported as a map so a class can be verified in isolation by conformance tests, and so the
9
+ * invalid-slash-request procedure can recurse back through it to re-run the report it is
10
+ * complaining about.
11
+ */
12
+ export declare const offenseProcedures: Partial<Record<OffenseCode, OffenseProcedure>>;
13
+ /**
14
+ * Verifies one report, end to end.
15
+ *
16
+ * The shared preamble runs first for every class: cited artifacts are re-hashed and their
17
+ * signatures checked, then the offense is measured against the freshness window. Both are
18
+ * conditions no class can waive, so running them once here keeps a procedure from quietly
19
+ * skipping one.
20
+ *
21
+ * A class with no registered procedure is indeterminate rather than invalid. The register can
22
+ * activate a class this build does not implement, and refusing to conclude is the honest answer —
23
+ * concluding "not an offense" would let the gap read as an acquittal.
24
+ * @param ctx What the verifier may consult
25
+ * @param request The report being verified
26
+ * @returns The verdict, with its transcript
27
+ */
28
+ export declare function verifyOffense(ctx: OffenseVerificationContext, request: SlashRequest): Promise<OffenseVerdict>;
29
+ //# sourceMappingURL=verifyOffense.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"verifyOffense.d.ts","sourceRoot":"","sources":["../../../../../src/modules/slashing/verify/verifyOffense.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAA;AAErE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAA;AACpE,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,wCAAwC,CAAA;AACxF,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAA;AAWrE;;;;;;GAMG;AACH,eAAO,MAAM,iBAAiB,EAAE,OAAO,CAAC,MAAM,CAAC,WAAW,EAAE,gBAAgB,CAAC,CAQ5E,CAAA;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAsB,aAAa,CACjC,GAAG,EAAE,0BAA0B,EAC/B,OAAO,EAAE,YAAY,GACpB,OAAO,CAAC,cAAc,CAAC,CAwBzB"}
@@ -0,0 +1,23 @@
1
+ import type { OffenseProcedure } from '../model/OffenseProcedure.js';
2
+ /**
3
+ * O3 — reward overmint: paying yourself more than the rules allowed.
4
+ *
5
+ * The allowance is recomputed from the register rather than read from the block, since a block
6
+ * that could state its own allowance could authorise anything. Where the allowance comes from
7
+ * depends on how the chain is configured — a fixed schedule, or the staking contract — and when
8
+ * it comes from the contract it is read at the parent's anchor rather than at a live head, so
9
+ * every verifier asks the contract the same question.
10
+ *
11
+ * Minting is counted only from the zero address. A producer moving its own balance around is
12
+ * spending money that already existed, which is nobody's business but its own.
13
+ *
14
+ * Under-minting is not an offense here. A producer that pays itself less than it could has taken
15
+ * nothing from anyone, and treating generosity as misconduct would be absurd.
16
+ *
17
+ * Only the zero-address mint clause is implemented. The specification's fee-rule and step-transfer
18
+ * clauses wait on the deterministic fee replay and the step-boundary reader; until they land,
19
+ * reports alleging those shapes resolve on the mint clause alone — never as a conviction the
20
+ * missing clauses would have had to establish.
21
+ */
22
+ export declare const verifyRewardOvermint: OffenseProcedure;
23
+ //# sourceMappingURL=verifyRewardOvermint.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"verifyRewardOvermint.d.ts","sourceRoot":"","sources":["../../../../../src/modules/slashing/verify/verifyRewardOvermint.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAA;AA6BpE;;;;;;;;;;;;;;;;;;;GAmBG;AACH,eAAO,MAAM,oBAAoB,EAAE,gBAuClC,CAAA"}
@@ -0,0 +1,14 @@
1
+ import type { Payload, WithHashMeta } from '@xyo-network/sdk';
2
+ import type { HydratedBlockWithHashMeta, TransactionBoundWitnessWithHashMeta } from '@xyo-network/xl1-sdk';
3
+ /**
4
+ * The transaction in this block that elevated the payload, when one did.
5
+ *
6
+ * A payload can also ride directly in the block, elevated by the block signer rather than by a
7
+ * transaction. Callers that need a signer to bind against must be able to tell the two apart,
8
+ * because those two paths attribute the payload to entirely different addresses.
9
+ * @param payload The payload being validated
10
+ * @param block The hydrated block carrying it
11
+ * @returns The elevating transaction, or undefined when the payload rode directly
12
+ */
13
+ export declare function findElevatingTransaction(payload: WithHashMeta<Payload>, [, payloads]: HydratedBlockWithHashMeta): TransactionBoundWitnessWithHashMeta | undefined;
14
+ //# sourceMappingURL=findElevatingTransaction.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"findElevatingTransaction.d.ts","sourceRoot":"","sources":["../../../../../../src/modules/validation/elevatedPayload/lib/findElevatingTransaction.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAA;AAC7D,OAAO,KAAK,EAAE,yBAAyB,EAAE,mCAAmC,EAAE,MAAM,sBAAsB,CAAA;AAG1G;;;;;;;;;GASG;AACH,wBAAgB,wBAAwB,CACtC,OAAO,EAAE,YAAY,CAAC,OAAO,CAAC,EAC9B,CAAC,EAAE,QAAQ,CAAC,EAAE,yBAAyB,GACtC,mCAAmC,GAAG,SAAS,CAIjD"}
@@ -1,7 +1,9 @@
1
+ export * from './findElevatingTransaction.js';
1
2
  export * from './isElevatedFromBlock.js';
2
3
  export * from './validateElevatedFromBlock.js';
3
4
  export * from './validateElevatedFromTransaction.js';
4
5
  export * from './validateIncludedInBlock.js';
6
+ export * from './validateSlashPayloadInBlock.js';
5
7
  export * from './validateTransactionInBlock.js';
6
8
  export * from './validateTypedPayloadInBlock.js';
7
9
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/modules/validation/elevatedPayload/lib/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAA;AACxC,cAAc,gCAAgC,CAAA;AAC9C,cAAc,sCAAsC,CAAA;AACpD,cAAc,8BAA8B,CAAA;AAC5C,cAAc,iCAAiC,CAAA;AAC/C,cAAc,kCAAkC,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/modules/validation/elevatedPayload/lib/index.ts"],"names":[],"mappings":"AAAA,cAAc,+BAA+B,CAAA;AAC7C,cAAc,0BAA0B,CAAA;AACxC,cAAc,gCAAgC,CAAA;AAC9C,cAAc,sCAAsC,CAAA;AACpD,cAAc,8BAA8B,CAAA;AAC5C,cAAc,kCAAkC,CAAA;AAChD,cAAc,iCAAiC,CAAA;AAC/C,cAAc,kCAAkC,CAAA"}
@@ -0,0 +1,33 @@
1
+ import type { IdentityFunction } from '@ariestools/sdk';
2
+ import type { Payload, XyoAddress } from '@xyo-network/sdk';
3
+ import type { HydratedBlockWithHashMeta, InBlockPayloadValidationFunctionContext, InBlockRuleParams, TransactionBoundWitnessWithHashMeta } from '@xyo-network/xl1-sdk';
4
+ /** What the shared slash-payload checks concluded, plus the rules the caller still needs. */
5
+ export interface SlashPayloadGateResult {
6
+ /** Reasons the payload is not admissible; empty when the shared checks passed. */
7
+ errors: Error[];
8
+ /** The rules in force at the carrying height, when they resolved. */
9
+ params?: InBlockRuleParams;
10
+ /** The transaction that elevated the payload, once binding has confirmed it. */
11
+ transaction?: TransactionBoundWitnessWithHashMeta;
12
+ }
13
+ /**
14
+ * The checks every slash payload shares: the activation gate, then signer binding.
15
+ *
16
+ * Every slash payload is transaction-elevation-only. A payload riding directly in the block would
17
+ * bind to the block signer instead of a transaction sender, and nothing in the design says what
18
+ * that would mean — so that path is refused rather than guessed at. Binding `from` to the
19
+ * elevating transaction's sender gets self-signing discipline transitively, since the transaction
20
+ * validator has already tied `tx.from` to a verified bound-witness signer.
21
+ *
22
+ * The resolved rules come back so a caller can ask its own questions of them without resolving
23
+ * the register a second time, and so the gate stays the only place that decides admissibility.
24
+ * @param context The validation context, which may carry no register at all
25
+ * @param payload The payload being validated
26
+ * @param block The hydrated block carrying it
27
+ * @param identityFunction Guard establishing the payload is the type expected
28
+ * @param fromOf Reads the address the payload claims to be from
29
+ * @param subject What is being gated, named for the error message
30
+ * @returns The shared verdict and the rules in force
31
+ */
32
+ export declare function validateSlashPayloadInBlock<T extends Payload>(context: InBlockPayloadValidationFunctionContext, payload: Payload, block: HydratedBlockWithHashMeta, identityFunction: IdentityFunction<T>, fromOf: (payload: T) => XyoAddress, subject: string): Promise<SlashPayloadGateResult>;
33
+ //# sourceMappingURL=validateSlashPayloadInBlock.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"validateSlashPayloadInBlock.d.ts","sourceRoot":"","sources":["../../../../../../src/modules/validation/elevatedPayload/lib/validateSlashPayloadInBlock.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAA;AACvD,OAAO,KAAK,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAE3D,OAAO,KAAK,EACV,yBAAyB,EAAE,uCAAuC,EAAE,iBAAiB,EACrF,mCAAmC,EACpC,MAAM,sBAAsB,CAAA;AAK7B,6FAA6F;AAC7F,MAAM,WAAW,sBAAsB;IACrC,kFAAkF;IAClF,MAAM,EAAE,KAAK,EAAE,CAAA;IACf,qEAAqE;IACrE,MAAM,CAAC,EAAE,iBAAiB,CAAA;IAC1B,gFAAgF;IAChF,WAAW,CAAC,EAAE,mCAAmC,CAAA;CAClD;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAsB,2BAA2B,CAAC,CAAC,SAAS,OAAO,EACjE,OAAO,EAAE,uCAAuC,EAChD,OAAO,EAAE,OAAO,EAChB,KAAK,EAAE,yBAAyB,EAChC,gBAAgB,EAAE,gBAAgB,CAAC,CAAC,CAAC,EACrC,MAAM,EAAE,CAAC,OAAO,EAAE,CAAC,KAAK,UAAU,EAClC,OAAO,EAAE,MAAM,GACd,OAAO,CAAC,sBAAsB,CAAC,CAqBjC"}
@@ -4,6 +4,11 @@ export * from './validateBridgeSourceObservationInBlock.js';
4
4
  export * from './validateChainStakeIntentInBlock.js';
5
5
  export * from './validateHashInBlock.js';
6
6
  export * from './validateSchemaInBlock.js';
7
+ export * from './validateSlashAdjudicationInBlock.js';
8
+ export * from './validateSlashChallengeInBlock.js';
9
+ export * from './validateSlashCommitInBlock.js';
10
+ export * from './validateSlashEvidenceInBlock.js';
11
+ export * from './validateSlashRequestInBlock.js';
7
12
  export * from './validateTimeInBlock.js';
8
13
  export * from './validateTransferInBlock.js';
9
14
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/modules/validation/elevatedPayload/payloads/index.ts"],"names":[],"mappings":"AAAA,cAAc,kDAAkD,CAAA;AAChE,cAAc,kCAAkC,CAAA;AAChD,cAAc,6CAA6C,CAAA;AAC3D,cAAc,sCAAsC,CAAA;AACpD,cAAc,0BAA0B,CAAA;AACxC,cAAc,4BAA4B,CAAA;AAC1C,cAAc,0BAA0B,CAAA;AACxC,cAAc,8BAA8B,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/modules/validation/elevatedPayload/payloads/index.ts"],"names":[],"mappings":"AAAA,cAAc,kDAAkD,CAAA;AAChE,cAAc,kCAAkC,CAAA;AAChD,cAAc,6CAA6C,CAAA;AAC3D,cAAc,sCAAsC,CAAA;AACpD,cAAc,0BAA0B,CAAA;AACxC,cAAc,4BAA4B,CAAA;AAC1C,cAAc,uCAAuC,CAAA;AACrD,cAAc,oCAAoC,CAAA;AAClD,cAAc,iCAAiC,CAAA;AAC/C,cAAc,mCAAmC,CAAA;AACjD,cAAc,kCAAkC,CAAA;AAChD,cAAc,0BAA0B,CAAA;AACxC,cAAc,8BAA8B,CAAA"}
@@ -0,0 +1,14 @@
1
+ import type { InBlockPayloadValidationFunction } from '@xyo-network/xl1-sdk';
2
+ /**
3
+ * Validates a slash adjudication carried in a block.
4
+ *
5
+ * Only the arbiter named by the register may close a report, and that binding survives well past
6
+ * the point where reporting itself opens up — an adjudication from anyone else is not a minority
7
+ * opinion, it is a forged verdict.
8
+ *
9
+ * Whether a confirmed adjudication names its claimant is an arbiter duty checked when the
10
+ * adjudication is recomputed, not a question of block validity. A block carrying a sloppy but
11
+ * genuine verdict is still a valid block.
12
+ */
13
+ export declare const validateSlashAdjudicationInBlock: InBlockPayloadValidationFunction;
14
+ //# sourceMappingURL=validateSlashAdjudicationInBlock.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"validateSlashAdjudicationInBlock.d.ts","sourceRoot":"","sources":["../../../../../../src/modules/validation/elevatedPayload/payloads/validateSlashAdjudicationInBlock.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,sBAAsB,CAAA;AAK5E;;;;;;;;;;GAUG;AACH,eAAO,MAAM,gCAAgC,EAAE,gCAyB9C,CAAA"}
@@ -0,0 +1,10 @@
1
+ import type { InBlockPayloadValidationFunction } from '@xyo-network/xl1-sdk';
2
+ /**
3
+ * Validates a slash challenge carried in a block.
4
+ *
5
+ * Anyone may challenge and no bond is required, because a challenge can only exculpate. A
6
+ * frivolous one fails to change the verdict and costs its filer the fee; there is no version of it
7
+ * that harms the accused, so there is nothing here to deter.
8
+ */
9
+ export declare const validateSlashChallengeInBlock: InBlockPayloadValidationFunction;
10
+ //# sourceMappingURL=validateSlashChallengeInBlock.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"validateSlashChallengeInBlock.d.ts","sourceRoot":"","sources":["../../../../../../src/modules/validation/elevatedPayload/payloads/validateSlashChallengeInBlock.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,sBAAsB,CAAA;AAK5E;;;;;;GAMG;AACH,eAAO,MAAM,6BAA6B,EAAE,gCAqB3C,CAAA"}
@@ -0,0 +1,10 @@
1
+ import type { InBlockPayloadValidationFunction } from '@xyo-network/xl1-sdk';
2
+ /**
3
+ * Validates a slash commitment carried in a block.
4
+ *
5
+ * A commitment reserves a report before its evidence is public, which is what stops a reporter's
6
+ * work from being lifted from the mempool and re-filed under someone else's name. The commitment
7
+ * itself is opaque here by design — checking what it hides is the reveal's job.
8
+ */
9
+ export declare const validateSlashCommitInBlock: InBlockPayloadValidationFunction;
10
+ //# sourceMappingURL=validateSlashCommitInBlock.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"validateSlashCommitInBlock.d.ts","sourceRoot":"","sources":["../../../../../../src/modules/validation/elevatedPayload/payloads/validateSlashCommitInBlock.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EACV,gCAAgC,EAEjC,MAAM,sBAAsB,CAAA;AAsC7B;;;;;;GAMG;AACH,eAAO,MAAM,0BAA0B,EAAE,gCAwCxC,CAAA"}
@@ -0,0 +1,10 @@
1
+ import type { InBlockPayloadValidationFunction } from '@xyo-network/xl1-sdk';
2
+ /**
3
+ * Validates a slash evidence carried in a block.
4
+ *
5
+ * A container carries artifacts and asserts nothing about them, so past the activation gate and
6
+ * signer binding there is nothing left to check. No size ceiling is imposed: character storage is
7
+ * already priced by gas, so an oversized container costs its sender what it costs the chain.
8
+ */
9
+ export declare const validateSlashEvidenceInBlock: InBlockPayloadValidationFunction;
10
+ //# sourceMappingURL=validateSlashEvidenceInBlock.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"validateSlashEvidenceInBlock.d.ts","sourceRoot":"","sources":["../../../../../../src/modules/validation/elevatedPayload/payloads/validateSlashEvidenceInBlock.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,sBAAsB,CAAA;AAK5E;;;;;;GAMG;AACH,eAAO,MAAM,4BAA4B,EAAE,gCAqB1C,CAAA"}
@@ -0,0 +1,14 @@
1
+ import type { InBlockPayloadValidationFunction } from '@xyo-network/xl1-sdk';
2
+ /**
3
+ * Validates a slash request carried in a block.
4
+ *
5
+ * A request is a recordable transaction, not a verdict, so this checks that it is well-formed and
6
+ * that its evidence exists — never whether the accusation is true. An unverifiable request is
7
+ * still a valid request; deciding it is the arbiter's job.
8
+ *
9
+ * The reportable gate is asked of the height the offense happened at, not the height the report
10
+ * lands at. Comparing against the carrying height would make a rule retroactive and turn conduct
11
+ * that was legal when it occurred into an offense.
12
+ */
13
+ export declare const validateSlashRequestInBlock: InBlockPayloadValidationFunction;
14
+ //# sourceMappingURL=validateSlashRequestInBlock.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"validateSlashRequestInBlock.d.ts","sourceRoot":"","sources":["../../../../../../src/modules/validation/elevatedPayload/payloads/validateSlashRequestInBlock.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EACV,gCAAgC,EAEjC,MAAM,sBAAsB,CAAA;AA8D7B;;;;;;;;;;GAUG;AACH,eAAO,MAAM,2BAA2B,EAAE,gCAqCzC,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"validatePayloadInBlock.d.ts","sourceRoot":"","sources":["../../../../../src/modules/validation/elevatedPayload/validatePayloadInBlock.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,sBAAsB,CAAA;AAwB5E,eAAO,MAAM,sBAAsB,EAAE,gCAwBpC,CAAA"}
1
+ {"version":3,"file":"validatePayloadInBlock.d.ts","sourceRoot":"","sources":["../../../../../src/modules/validation/elevatedPayload/validatePayloadInBlock.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,sBAAsB,CAAA;AAiC5E,eAAO,MAAM,sBAAsB,EAAE,gCAwBpC,CAAA"}
@@ -71,6 +71,9 @@ var isBuildNextBlockOptions = (value) => {
71
71
  function calculateCompletedStepReward(step, balance) {
72
72
  return AttoXL1(StepRewardFractions[step][0] * balance / StepRewardFractions[step][1]);
73
73
  }
74
+ function supersedesField(options) {
75
+ return isBuildNextBlockOptions(options) && options.supersedes !== void 0 ? { supersedes: options.supersedes } : {};
76
+ }
74
77
  async function buildBlock(options) {
75
78
  const previousBlockNumber = isBuildGenesisBlockOptions(options) ? -1 : options.previousBlockNumber;
76
79
  const blockNumber = asXL1BlockNumber(previousBlockNumber + 1, true);
@@ -127,7 +130,8 @@ async function buildBlock(options) {
127
130
  chain: chainId,
128
131
  previous,
129
132
  step_hashes,
130
- protocol
133
+ protocol,
134
+ ...supersedesField(options)
131
135
  }).meta({ $epoch: Date.now(), $signatures: [] }).signers(signers).payloads(await PayloadBuilder.addStorageMeta(payloads)).build();
132
136
  assertEx(isBlockBoundWitness(bw), () => "Build of BlockBoundWitness failed");
133
137
  return [await PayloadBuilder.addStorageMeta(bw), txPayloads];
@@ -152,7 +156,7 @@ import {
152
156
  AttoXL1 as AttoXL12,
153
157
  XYO_STEP_REWARD_ADDRESS as XYO_STEP_REWARD_ADDRESS2
154
158
  } from "@xyo-network/xl1-sdk";
155
- async function buildNextBlock(previousBlock, txs, blockPayloads, signers, chainStepRewardAddress = XYO_STEP_REWARD_ADDRESS2, stepRewardPoolBalance = AttoXL12(0n), protocol, chainId) {
159
+ async function buildNextBlock(previousBlock, txs, blockPayloads, signers, chainStepRewardAddress = XYO_STEP_REWARD_ADDRESS2, stepRewardPoolBalance = AttoXL12(0n), protocol, chainId, supersedes) {
156
160
  return await buildBlock({
157
161
  chainId: chainId ?? previousBlock.chain,
158
162
  previousBlockNumber: previousBlock.block,
@@ -163,7 +167,8 @@ async function buildNextBlock(previousBlock, txs, blockPayloads, signers, chainS
163
167
  signers,
164
168
  protocol,
165
169
  chainStepRewardAddress,
166
- stepRewardPoolBalance
170
+ stepRewardPoolBalance,
171
+ supersedes
167
172
  });
168
173
  }
169
174