neozipkit 0.1.1 → 0.3.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 (330) hide show
  1. package/LICENSE +22 -0
  2. package/README.md +371 -200
  3. package/contracts/ABI.txt +889 -0
  4. package/contracts/Bytecode.txt +1 -0
  5. package/contracts/COMPILATION_NOTES.md +59 -0
  6. package/contracts/QUICK_DEPLOY.md +286 -0
  7. package/contracts/README.md +256 -0
  8. package/contracts/VERIFICATION.md +308 -0
  9. package/contracts/deploy-interactive.js +448 -0
  10. package/contracts/deployment-arbitrum-sepolia.json +12 -0
  11. package/contracts/deployment-arbitrum.json +12 -0
  12. package/contracts/deployment-eth-sepolia.json +12 -0
  13. package/contracts/hardhat.config.js +114 -0
  14. package/contracts/package.json +20 -0
  15. package/contracts/scripts/compile-and-extract.js +119 -0
  16. package/contracts/scripts/verify-contract.js +223 -0
  17. package/contracts/src/{NZIP-NFT-Private.sol → NZIP-NFT-v2.0.sol} +66 -151
  18. package/contracts/src/NZIP-NFT.sol +9 -15
  19. package/dist/{browser → blockchain/browser}/TokenVerifierBrowser.d.ts +11 -20
  20. package/dist/blockchain/browser/TokenVerifierBrowser.d.ts.map +1 -0
  21. package/dist/{browser → blockchain/browser}/TokenVerifierBrowser.js +106 -92
  22. package/dist/blockchain/browser/TokenVerifierBrowser.js.map +1 -0
  23. package/dist/blockchain/browser/WalletManagerBrowser.d.ts +98 -0
  24. package/dist/blockchain/browser/WalletManagerBrowser.d.ts.map +1 -0
  25. package/dist/blockchain/browser/WalletManagerBrowser.js +434 -0
  26. package/dist/blockchain/browser/WalletManagerBrowser.js.map +1 -0
  27. package/dist/blockchain/browser/ZipkitMinterBrowser.d.ts +58 -0
  28. package/dist/blockchain/browser/ZipkitMinterBrowser.d.ts.map +1 -0
  29. package/dist/blockchain/browser/ZipkitMinterBrowser.js +317 -0
  30. package/dist/blockchain/browser/ZipkitMinterBrowser.js.map +1 -0
  31. package/dist/blockchain/browser/index.d.ts +11 -0
  32. package/dist/blockchain/browser/index.d.ts.map +1 -0
  33. package/dist/blockchain/browser/index.js +16 -0
  34. package/dist/blockchain/browser/index.js.map +1 -0
  35. package/dist/{server/blockchain/WalletAnalyzer.d.ts → blockchain/core/WalletManager.d.ts} +69 -26
  36. package/dist/blockchain/core/WalletManager.d.ts.map +1 -0
  37. package/dist/{server/blockchain/WalletAnalyzer.js → blockchain/core/WalletManager.js} +172 -160
  38. package/dist/blockchain/core/WalletManager.js.map +1 -0
  39. package/dist/blockchain/core/ZipkitMinter.d.ts +141 -0
  40. package/dist/blockchain/core/ZipkitMinter.d.ts.map +1 -0
  41. package/dist/blockchain/core/ZipkitMinter.js +548 -0
  42. package/dist/blockchain/core/ZipkitMinter.js.map +1 -0
  43. package/dist/blockchain/core/ZipkitOTS.d.ts +126 -0
  44. package/dist/blockchain/core/ZipkitOTS.d.ts.map +1 -0
  45. package/dist/blockchain/core/ZipkitOTS.js +506 -0
  46. package/dist/blockchain/core/ZipkitOTS.js.map +1 -0
  47. package/dist/blockchain/core/ZipkitVerifier.d.ts +177 -0
  48. package/dist/blockchain/core/ZipkitVerifier.d.ts.map +1 -0
  49. package/dist/blockchain/core/ZipkitVerifier.js +632 -0
  50. package/dist/blockchain/core/ZipkitVerifier.js.map +1 -0
  51. package/dist/blockchain/core/contracts.d.ts +83 -0
  52. package/dist/blockchain/core/contracts.d.ts.map +1 -0
  53. package/dist/blockchain/core/contracts.js +341 -0
  54. package/dist/blockchain/core/contracts.js.map +1 -0
  55. package/dist/blockchain/core/index.d.ts +12 -0
  56. package/dist/blockchain/core/index.d.ts.map +1 -0
  57. package/dist/blockchain/core/index.js +59 -0
  58. package/dist/blockchain/core/index.js.map +1 -0
  59. package/dist/blockchain/index.d.ts +11 -0
  60. package/dist/blockchain/index.d.ts.map +1 -0
  61. package/dist/blockchain/index.js +34 -0
  62. package/dist/blockchain/index.js.map +1 -0
  63. package/dist/blockchain/node/WalletManagerNode.d.ts +47 -0
  64. package/dist/blockchain/node/WalletManagerNode.d.ts.map +1 -0
  65. package/dist/blockchain/node/WalletManagerNode.js +203 -0
  66. package/dist/blockchain/node/WalletManagerNode.js.map +1 -0
  67. package/dist/blockchain/node/index.d.ts +12 -0
  68. package/dist/blockchain/node/index.d.ts.map +1 -0
  69. package/dist/blockchain/node/index.js +24 -0
  70. package/dist/blockchain/node/index.js.map +1 -0
  71. package/dist/browser/ZipkitBrowser.d.ts +27 -0
  72. package/dist/browser/ZipkitBrowser.d.ts.map +1 -0
  73. package/dist/browser/{ZipKitBrowser.js → ZipkitBrowser.js} +96 -43
  74. package/dist/browser/ZipkitBrowser.js.map +1 -0
  75. package/dist/browser/index.d.ts +12 -0
  76. package/dist/browser/index.d.ts.map +1 -0
  77. package/dist/browser/index.js +42 -0
  78. package/dist/browser/index.js.map +1 -0
  79. package/dist/browser-esm/index.d.ts +12 -0
  80. package/dist/browser-esm/index.js +59559 -0
  81. package/dist/browser-esm/index.js.map +7 -0
  82. package/dist/browser-umd/index.d.ts +12 -0
  83. package/dist/browser-umd/index.js +59576 -0
  84. package/dist/browser-umd/index.js.map +7 -0
  85. package/dist/browser-umd/index.min.js +63 -0
  86. package/dist/browser.d.ts +8 -17
  87. package/dist/browser.js +13 -29
  88. package/dist/core/ZipCompress.d.ts +99 -0
  89. package/dist/core/ZipCompress.d.ts.map +1 -0
  90. package/dist/core/ZipCompress.js +309 -0
  91. package/dist/core/ZipCompress.js.map +1 -0
  92. package/dist/core/ZipDecompress.d.ts +58 -0
  93. package/dist/core/ZipDecompress.d.ts.map +1 -0
  94. package/dist/core/ZipDecompress.js +172 -0
  95. package/dist/core/ZipDecompress.js.map +1 -0
  96. package/dist/{shared → core}/ZipEntry.d.ts +8 -1
  97. package/dist/core/ZipEntry.d.ts.map +1 -0
  98. package/dist/{shared → core}/ZipEntry.js +224 -81
  99. package/dist/core/ZipEntry.js.map +1 -0
  100. package/dist/core/Zipkit.d.ts +315 -0
  101. package/dist/core/Zipkit.d.ts.map +1 -0
  102. package/dist/core/Zipkit.js +647 -0
  103. package/dist/core/Zipkit.js.map +1 -0
  104. package/dist/core/components/HashCalculator.d.ts +138 -0
  105. package/dist/core/components/HashCalculator.d.ts.map +1 -0
  106. package/dist/core/components/HashCalculator.js +360 -0
  107. package/dist/core/components/HashCalculator.js.map +1 -0
  108. package/dist/core/components/Logger.d.ts +73 -0
  109. package/dist/core/components/Logger.d.ts.map +1 -0
  110. package/dist/core/components/Logger.js +156 -0
  111. package/dist/core/components/Logger.js.map +1 -0
  112. package/dist/core/components/ProgressTracker.d.ts +43 -0
  113. package/dist/core/components/ProgressTracker.d.ts.map +1 -0
  114. package/dist/core/components/ProgressTracker.js +112 -0
  115. package/dist/core/components/ProgressTracker.js.map +1 -0
  116. package/dist/{shared → core}/components/Support.d.ts +1 -0
  117. package/dist/core/components/Support.d.ts.map +1 -0
  118. package/dist/{shared → core}/components/Support.js +1 -0
  119. package/dist/core/components/Support.js.map +1 -0
  120. package/dist/{shared → core}/components/Util.d.ts +7 -2
  121. package/dist/core/components/Util.d.ts.map +1 -0
  122. package/dist/{shared → core}/components/Util.js +14 -34
  123. package/dist/core/components/Util.js.map +1 -0
  124. package/dist/{shared → core}/constants/Errors.d.ts +1 -2
  125. package/dist/core/constants/Errors.d.ts.map +1 -0
  126. package/dist/{shared → core}/constants/Errors.js +1 -3
  127. package/dist/core/constants/Errors.js.map +1 -0
  128. package/dist/{shared → core}/constants/Headers.d.ts +3 -0
  129. package/dist/core/constants/Headers.d.ts.map +1 -0
  130. package/dist/{shared → core}/constants/Headers.js +20 -17
  131. package/dist/core/constants/Headers.js.map +1 -0
  132. package/dist/core/encryption/Manager.d.ts +58 -0
  133. package/dist/core/encryption/Manager.d.ts.map +1 -0
  134. package/dist/core/encryption/Manager.js +121 -0
  135. package/dist/core/encryption/Manager.js.map +1 -0
  136. package/dist/core/encryption/ZipCrypto.d.ts +172 -0
  137. package/dist/core/encryption/ZipCrypto.d.ts.map +1 -0
  138. package/dist/core/encryption/ZipCrypto.js +554 -0
  139. package/dist/core/encryption/ZipCrypto.js.map +1 -0
  140. package/dist/core/encryption/index.d.ts +9 -0
  141. package/dist/core/encryption/index.d.ts.map +1 -0
  142. package/dist/core/encryption/index.js +17 -0
  143. package/dist/core/encryption/index.js.map +1 -0
  144. package/dist/core/encryption/types.d.ts +29 -0
  145. package/dist/core/encryption/types.d.ts.map +1 -0
  146. package/dist/core/encryption/types.js +12 -0
  147. package/dist/core/encryption/types.js.map +1 -0
  148. package/dist/core/index.d.ts +24 -0
  149. package/dist/core/index.d.ts.map +1 -0
  150. package/dist/core/index.js +57 -0
  151. package/dist/core/index.js.map +1 -0
  152. package/dist/{shared → core}/version.d.ts +1 -0
  153. package/dist/core/version.d.ts.map +1 -0
  154. package/dist/core/version.js +31 -0
  155. package/dist/core/version.js.map +1 -0
  156. package/dist/index.d.ts +8 -25
  157. package/dist/index.d.ts.map +1 -0
  158. package/dist/index.js +29 -47
  159. package/dist/index.js.map +1 -0
  160. package/dist/node/ZipCompressNode.d.ts +123 -0
  161. package/dist/node/ZipCompressNode.d.ts.map +1 -0
  162. package/dist/node/ZipCompressNode.js +576 -0
  163. package/dist/node/ZipCompressNode.js.map +1 -0
  164. package/dist/node/ZipDecompressNode.d.ts +120 -0
  165. package/dist/node/ZipDecompressNode.d.ts.map +1 -0
  166. package/dist/node/ZipDecompressNode.js +461 -0
  167. package/dist/node/ZipDecompressNode.js.map +1 -0
  168. package/dist/node/ZipkitNode.d.ts +406 -0
  169. package/dist/node/ZipkitNode.d.ts.map +1 -0
  170. package/dist/node/ZipkitNode.js +1305 -0
  171. package/dist/node/ZipkitNode.js.map +1 -0
  172. package/dist/node/index.d.ts +26 -0
  173. package/dist/node/index.d.ts.map +1 -0
  174. package/dist/node/index.js +65 -0
  175. package/dist/node/index.js.map +1 -0
  176. package/dist/types/index.d.ts +59 -0
  177. package/dist/types/index.d.ts.map +1 -0
  178. package/dist/types/index.js +36 -1
  179. package/dist/types/index.js.map +1 -0
  180. package/examples/README.md +269 -0
  181. package/examples/blockchain-tokenize.ts +354 -0
  182. package/examples/create-zip.ts +172 -0
  183. package/examples/extract-zip.ts +158 -0
  184. package/examples/list-zip.ts +161 -0
  185. package/examples/test-files/data.json +116 -0
  186. package/examples/test-files/document.md +80 -0
  187. package/examples/test-files/document.txt +2 -0
  188. package/examples/test-files/file1.txt +48 -0
  189. package/examples/test-files/file2.txt +80 -0
  190. package/examples/tsconfig.json +44 -0
  191. package/examples/unzip-token.ts +6 -3
  192. package/examples/verify-tokenized-zip.ts +305 -0
  193. package/package.json +117 -23
  194. package/src/blockchain/README.md +222 -0
  195. package/src/{browser → blockchain/browser}/TokenVerifierBrowser.ts +125 -79
  196. package/src/blockchain/browser/WalletManagerBrowser.ts +486 -0
  197. package/src/blockchain/browser/ZipkitMinterBrowser.ts +400 -0
  198. package/src/blockchain/browser/index.ts +13 -0
  199. package/src/blockchain/core/WalletManager.ts +436 -0
  200. package/src/blockchain/core/ZipkitMinter.ts +716 -0
  201. package/src/blockchain/core/ZipkitOTS.ts +588 -0
  202. package/src/blockchain/core/ZipkitVerifier.ts +853 -0
  203. package/src/blockchain/core/contracts.ts +370 -0
  204. package/src/blockchain/core/index.ts +71 -0
  205. package/src/blockchain/index.ts +27 -0
  206. package/src/blockchain/node/WalletManagerNode.ts +171 -0
  207. package/src/blockchain/node/index.ts +40 -0
  208. package/src/browser/{ZipKitBrowser.ts → ZipkitBrowser.ts} +104 -41
  209. package/src/browser/index.esm.ts +37 -0
  210. package/src/browser/index.ts +25 -0
  211. package/src/core/ZipCompress.ts +398 -0
  212. package/src/core/ZipDecompress.ts +212 -0
  213. package/src/{shared → core}/ZipEntry.ts +239 -89
  214. package/src/core/Zipkit.ts +794 -0
  215. package/src/core/components/HashCalculator.ts +384 -0
  216. package/src/core/components/Logger.ts +180 -0
  217. package/src/core/components/ProgressTracker.ts +134 -0
  218. package/src/{shared → core}/components/Util.ts +12 -34
  219. package/src/{shared → core}/constants/Errors.ts +0 -4
  220. package/src/{shared → core}/constants/Headers.ts +19 -17
  221. package/src/core/encryption/Manager.ts +137 -0
  222. package/src/core/encryption/ZipCrypto.ts +650 -0
  223. package/src/core/encryption/index.ts +15 -0
  224. package/src/core/encryption/types.ts +33 -0
  225. package/src/core/index.ts +34 -0
  226. package/src/core/version.ts +33 -0
  227. package/src/index.ts +54 -32
  228. package/src/node/ZipCompressNode.ts +632 -0
  229. package/src/node/ZipDecompressNode.ts +508 -0
  230. package/src/node/ZipkitNode.ts +1559 -0
  231. package/src/node/index.ts +69 -0
  232. package/src/types/index.ts +131 -1
  233. package/src/types/opentimestamps.d.ts +1 -23
  234. package/contracts/Lock.sol +0 -34
  235. package/contracts/bytecode.txt +0 -1
  236. package/contracts/compile-contract.js +0 -168
  237. package/contracts/deploy/deploy-both-contracts.js +0 -286
  238. package/contracts/deploy/deploy-enhanced-contract.js +0 -197
  239. package/contracts/deploy/deploy-private-contract.js +0 -190
  240. package/contracts/deploy/deploy-public-clean.js +0 -1063
  241. package/contracts/deploy/deploy-public-contract.js +0 -1107
  242. package/contracts/deployment.config.example.js +0 -25
  243. package/contracts/remix-compile.js +0 -222
  244. package/contracts/setup-deployment.js +0 -51
  245. package/contracts/src/ZipFileNFT-DEPRECATED-6field.sol +0 -260
  246. package/contracts/src/ZipFileNFT-DEPRECATED-Enhanced.sol +0 -289
  247. package/dist/browser/CertificateGeneratorBrowser.d.ts +0 -75
  248. package/dist/browser/CertificateGeneratorBrowser.js +0 -433
  249. package/dist/browser/ZipKitBrowser.d.ts +0 -18
  250. package/dist/browser/ZipKitStampBrowser.d.ts +0 -2
  251. package/dist/browser/ZipKitStampBrowser.js +0 -12
  252. package/dist/browser-index.d.ts +0 -21
  253. package/dist/browser-index.js +0 -58
  254. package/dist/server/blockchain/CertificateToken.d.ts +0 -48
  255. package/dist/server/blockchain/CertificateToken.js +0 -386
  256. package/dist/server/blockchain/NFTMinter.d.ts +0 -41
  257. package/dist/server/blockchain/NFTMinter.js +0 -323
  258. package/dist/server/blockchain/TokenQuerier.d.ts +0 -31
  259. package/dist/server/blockchain/TokenQuerier.js +0 -259
  260. package/dist/server/blockchain/TokenVerifier.d.ts +0 -20
  261. package/dist/server/blockchain/TokenVerifier.js +0 -395
  262. package/dist/server/blockchain/WalletFormatter.d.ts +0 -39
  263. package/dist/server/blockchain/WalletFormatter.js +0 -196
  264. package/dist/server/blockchain/WalletManager.d.ts +0 -46
  265. package/dist/server/blockchain/WalletManager.js +0 -294
  266. package/dist/server/blockchain/ZipMetadata.d.ts +0 -27
  267. package/dist/server/blockchain/ZipMetadata.js +0 -131
  268. package/dist/server/blockchain/ZipTokenProcessor.d.ts +0 -44
  269. package/dist/server/blockchain/ZipTokenProcessor.js +0 -204
  270. package/dist/server/blockchain/constants.d.ts +0 -102
  271. package/dist/server/blockchain/constants.js +0 -968
  272. package/dist/server/blockchain/index.d.ts +0 -9
  273. package/dist/server/blockchain/index.js +0 -44
  274. package/dist/server/blockchain/test-certificate.d.ts +0 -8
  275. package/dist/server/blockchain/test-certificate.js +0 -100
  276. package/dist/server/blockchain/types.d.ts +0 -69
  277. package/dist/server/blockchain/types.js +0 -51
  278. package/dist/server/platform/server/ZipKitServer.d.ts +0 -105
  279. package/dist/server/platform/server/ZipKitServer.js +0 -437
  280. package/dist/server/platform/servercomponents/ZipKitOTS.d.ts +0 -91
  281. package/dist/server/platform/servercomponents/ZipKitOTS.js +0 -271
  282. package/dist/shared/ZipKit.d.ts +0 -249
  283. package/dist/shared/ZipKit.js +0 -789
  284. package/dist/shared/components/CertificateOTS.d.ts +0 -15
  285. package/dist/shared/components/CertificateOTS.js +0 -116
  286. package/dist/shared/components/FileSys.d.ts +0 -2
  287. package/dist/shared/components/FileSys.js +0 -113
  288. package/dist/shared/components/HashAccumulator.d.ts +0 -55
  289. package/dist/shared/components/HashAccumulator.js +0 -100
  290. package/dist/shared/components/ZipCrypto.d.ts +0 -3
  291. package/dist/shared/components/ZipCrypto.js +0 -78
  292. package/dist/shared/components/merkleTree.d.ts +0 -66
  293. package/dist/shared/components/merkleTree.js +0 -136
  294. package/dist/shared/types/index.d.ts +0 -21
  295. package/dist/shared/types/index.js +0 -3
  296. package/dist/shared/types.d.ts +0 -33
  297. package/dist/shared/types.js +0 -8
  298. package/dist/shared/version.js +0 -7
  299. package/src/browser/CertificateGeneratorBrowser.ts +0 -498
  300. package/src/browser/ZipKitStampBrowser.ts +0 -9
  301. package/src/browser-index.ts +0 -36
  302. package/src/server/blockchain/CertificateToken.ts +0 -444
  303. package/src/server/blockchain/NFTMinter.ts +0 -357
  304. package/src/server/blockchain/TokenQuerier.ts +0 -287
  305. package/src/server/blockchain/TokenVerifier.ts +0 -453
  306. package/src/server/blockchain/WalletAnalyzer.ts +0 -397
  307. package/src/server/blockchain/WalletFormatter.ts +0 -206
  308. package/src/server/blockchain/WalletManager.ts +0 -294
  309. package/src/server/blockchain/ZipMetadata.ts +0 -117
  310. package/src/server/blockchain/ZipTokenProcessor.ts +0 -234
  311. package/src/server/blockchain/constants.ts +0 -969
  312. package/src/server/blockchain/index.ts +0 -42
  313. package/src/server/blockchain/test-certificate.ts +0 -137
  314. package/src/server/blockchain/types.ts +0 -134
  315. package/src/server/platform/server/ZipKitServer.ts +0 -459
  316. package/src/server/platform/servercomponents/ZipKitOTS.ts +0 -313
  317. package/src/server/platform/servercomponents/opentimestamps.d.ts +0 -23
  318. package/src/shared/ZipKit.ts +0 -899
  319. package/src/shared/components/CertificateOTS.ts +0 -132
  320. package/src/shared/components/FileSys.ts +0 -87
  321. package/src/shared/components/HashAccumulator.ts +0 -113
  322. package/src/shared/components/ZipCrypto.ts +0 -91
  323. package/src/shared/components/merkleTree.ts +0 -162
  324. package/src/shared/types/index.ts +0 -25
  325. package/src/shared/types/modules.d.ts +0 -22
  326. package/src/shared/types/opentimestamps.d.ts +0 -23
  327. package/src/shared/types.d.ts +0 -8
  328. package/src/shared/types.ts +0 -43
  329. package/src/shared/version.ts +0 -4
  330. /package/src/{shared → core}/components/Support.ts +0 -0
@@ -0,0 +1,83 @@
1
+ export interface ContractConfig {
2
+ address: string;
3
+ network: string;
4
+ chainId: number;
5
+ explorerUrl: string;
6
+ rpcUrls: string[];
7
+ nameAliases?: string[];
8
+ }
9
+ export declare const CONTRACT_CONFIGS: Record<number, ContractConfig>;
10
+ export declare const NZIP_CONTRACT_ABI: string[];
11
+ export declare const NZIP_CONTRACT_ABI_WEB3: ({
12
+ inputs: {
13
+ name: string;
14
+ type: string;
15
+ }[];
16
+ name: string;
17
+ outputs: {
18
+ name: string;
19
+ type: string;
20
+ }[];
21
+ stateMutability: string;
22
+ type: string;
23
+ anonymous?: undefined;
24
+ } | {
25
+ inputs: {
26
+ name: string;
27
+ type: string;
28
+ }[];
29
+ name: string;
30
+ outputs: {
31
+ components: {
32
+ name: string;
33
+ type: string;
34
+ }[];
35
+ name: string;
36
+ type: string;
37
+ }[];
38
+ stateMutability: string;
39
+ type: string;
40
+ anonymous?: undefined;
41
+ } | {
42
+ anonymous: boolean;
43
+ inputs: {
44
+ indexed: boolean;
45
+ name: string;
46
+ type: string;
47
+ }[];
48
+ name: string;
49
+ type: string;
50
+ outputs?: undefined;
51
+ stateMutability?: undefined;
52
+ })[];
53
+ export declare const DEFAULT_NETWORK = 84532;
54
+ export declare const CURRENT_DEPLOYMENT: ContractConfig;
55
+ export declare const getContractConfig: (chainId: number) => ContractConfig;
56
+ export declare const getSupportedNetworks: () => number[];
57
+ export declare const isNetworkSupported: (chainId: number) => boolean;
58
+ /**
59
+ * Normalize network name for matching (lowercase, trim, replace spaces with hyphens)
60
+ */
61
+ export declare function normalizeNetworkName(networkName: string): string;
62
+ /**
63
+ * Get chain ID by network name (supports aliases)
64
+ * Returns chain ID if found, null otherwise
65
+ */
66
+ export declare function getChainIdByName(networkName: string): number | null;
67
+ /**
68
+ * Get network configuration by network name (supports aliases)
69
+ * Returns ContractConfig if found, null otherwise
70
+ */
71
+ export declare function getNetworkByName(networkName: string): ContractConfig | null;
72
+ /**
73
+ * Get all supported network name aliases
74
+ * Returns array of all supported network names (primary + aliases)
75
+ */
76
+ export declare function getSupportedNetworkNames(): string[];
77
+ /**
78
+ * Fuzzy match network name (for backward compatibility)
79
+ * Handles partial matches like "sepolia" matching "Base Sepolia" or "Arbitrum Sepolia"
80
+ * Returns best match or null
81
+ */
82
+ export declare function fuzzyMatchNetworkName(networkName: string): ContractConfig | null;
83
+ //# sourceMappingURL=contracts.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contracts.d.ts","sourceRoot":"","sources":["../../../src/blockchain/core/contracts.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,cAAc;IAC7B,OAAO,EAAE,MAAM,CAAA;IACf,OAAO,EAAE,MAAM,CAAA;IACf,OAAO,EAAE,MAAM,CAAA;IACf,WAAW,EAAE,MAAM,CAAA;IACnB,OAAO,EAAE,MAAM,EAAE,CAAA;IACjB,WAAW,CAAC,EAAE,MAAM,EAAE,CAAA;CACvB;AAGD,eAAO,MAAM,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAAE,cAAc,CA0F3D,CAAA;AAGD,eAAO,MAAM,iBAAiB,UAa7B,CAAA;AAGD,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAmHlC,CAAA;AAGD,eAAO,MAAM,eAAe,QAAQ,CAAA;AACpC,eAAO,MAAM,kBAAkB,gBAAoC,CAAA;AAGnE,eAAO,MAAM,iBAAiB,GAAI,SAAS,MAAM,KAAG,cAEnD,CAAA;AAED,eAAO,MAAM,oBAAoB,QAAO,MAAM,EAE7C,CAAA;AAED,eAAO,MAAM,kBAAkB,GAAI,SAAS,MAAM,KAAG,OAEpD,CAAA;AAED;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAEhE;AAED;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAuBnE;AAED;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,WAAW,EAAE,MAAM,GAAG,cAAc,GAAG,IAAI,CAM3E;AAED;;;GAGG;AACH,wBAAgB,wBAAwB,IAAI,MAAM,EAAE,CAcnD;AAED;;;;GAIG;AACH,wBAAgB,qBAAqB,CAAC,WAAW,EAAE,MAAM,GAAG,cAAc,GAAG,IAAI,CAyChF"}
@@ -0,0 +1,341 @@
1
+ "use strict";
2
+ // Contract addresses and configurations for different networks
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.isNetworkSupported = exports.getSupportedNetworks = exports.getContractConfig = exports.CURRENT_DEPLOYMENT = exports.DEFAULT_NETWORK = exports.NZIP_CONTRACT_ABI_WEB3 = exports.NZIP_CONTRACT_ABI = exports.CONTRACT_CONFIGS = void 0;
5
+ exports.normalizeNetworkName = normalizeNetworkName;
6
+ exports.getChainIdByName = getChainIdByName;
7
+ exports.getNetworkByName = getNetworkByName;
8
+ exports.getSupportedNetworkNames = getSupportedNetworkNames;
9
+ exports.fuzzyMatchNetworkName = fuzzyMatchNetworkName;
10
+ // NZIP NFT Contract configurations by network
11
+ exports.CONTRACT_CONFIGS = {
12
+ // Base Sepolia (Primary testnet)
13
+ 84532: {
14
+ // address: '0xFD76a5d420704F34d84b0767961835c43D7b30a8', // Production contract v2.0
15
+ address: '0xdAe9D83d7AC62197fAE7704abc66b13DA28D3143', // Production contract v2.10
16
+ network: 'Base Sepolia',
17
+ chainId: 84532,
18
+ explorerUrl: 'https://sepolia.basescan.org',
19
+ rpcUrls: [
20
+ 'https://sepolia.base.org',
21
+ 'https://base-sepolia-rpc.publicnode.com',
22
+ 'https://base-sepolia.gateway.tenderly.co'
23
+ ],
24
+ nameAliases: ['base-sepolia', 'base sepolia', 'basesepolia', 'base-sepolia-testnet']
25
+ },
26
+ // Base Mainnet (Production)
27
+ 8453: {
28
+ // address: '0x2716c4609fD97DaEdF429BC4B4Ec2faa81e2cC60', // Production contract v2.0
29
+ address: '0xd871Fba59F85108aF29299786DD8243B38dD9686', // Production contract v2.10
30
+ network: 'Base Mainnet',
31
+ chainId: 8453,
32
+ explorerUrl: 'https://basescan.org',
33
+ rpcUrls: [
34
+ 'https://mainnet.base.org',
35
+ 'https://base.drpc.org',
36
+ 'https://base.gateway.tenderly.co'
37
+ ],
38
+ nameAliases: ['base-mainnet', 'base mainnet', 'basemainnet', 'base']
39
+ },
40
+ // Ethereum Sepolia (Testnet)
41
+ // WARNING: Sepolia testnet has been experiencing instability since the Pectra upgrade (March 2025)
42
+ // Network issues include transaction processing failures and RPC timeouts
43
+ // Consider using Base Sepolia (84532) for more reliable testing
44
+ 11155111: {
45
+ address: '0x2716c4609fD97DaEdF429BC4B4Ec2faa81e2cC60', // Production contract v2.10
46
+ network: 'Sepolia Testnet',
47
+ chainId: 11155111,
48
+ explorerUrl: 'https://sepolia.etherscan.io',
49
+ rpcUrls: [
50
+ // Official Sepolia RPC endpoints (most reliable)
51
+ 'https://rpc.sepolia.ethpandaops.io',
52
+ // Popular public RPC providers
53
+ 'https://eth-sepolia.public.blastapi.io',
54
+ 'https://ethereum-sepolia-rpc.publicnode.com',
55
+ 'https://sepolia.drpc.org',
56
+ 'https://1rpc.io/sepolia',
57
+ ],
58
+ nameAliases: ['sepolia-testnet', 'sepolia testnet', 'sepoliatestnet', 'sepolia', 'ethereum-sepolia', 'ethereum sepolia']
59
+ },
60
+ // Arbitrum Sepolia (Testnet)
61
+ 421614: {
62
+ address: '0x2716c4609fD97DaEdF429BC4B4Ec2faa81e2cC60', // Production contract v2.10
63
+ network: 'Arbitrum Sepolia',
64
+ chainId: 421614,
65
+ explorerUrl: 'https://sepolia.arbiscan.io',
66
+ rpcUrls: [
67
+ 'https://sepolia-rollup.arbitrum.io/rpc',
68
+ 'https://arbitrum-sepolia-rpc.publicnode.com'
69
+ ],
70
+ nameAliases: ['arbitrum-sepolia', 'arbitrum sepolia', 'arbitrumsepolia', 'arbitrum-sepolia-testnet']
71
+ },
72
+ // Arbitrum One (Production)
73
+ // Note: Same contract address as Arbitrum Sepolia due to deterministic deployment
74
+ // (same deployer address + same nonce = same contract address on both networks)
75
+ 42161: {
76
+ address: '0x2716c4609fD97DaEdF429BC4B4Ec2faa81e2cC60', // Production contract v2.10
77
+ network: 'Arbitrum One',
78
+ chainId: 42161,
79
+ explorerUrl: 'https://arbiscan.io',
80
+ rpcUrls: [
81
+ 'https://arb1.arbitrum.io/rpc',
82
+ 'https://arbitrum.llamarpc.com',
83
+ 'https://arbitrum.publicnode.com'
84
+ ],
85
+ nameAliases: ['arbitrum-one', 'arbitrum one', 'arbitrumone', 'arbitrum', 'arbitrum-mainnet', 'arbitrum mainnet']
86
+ },
87
+ // Ethereum Mainnet (Production) - disabled until NZIP is deployed
88
+ // 1: {
89
+ // address: '0x0000000000000000000000000000000000000000',
90
+ // network: 'Ethereum Mainnet',
91
+ // chainId: 1,
92
+ // explorerUrl: 'https://etherscan.io',
93
+ // rpcUrls: []
94
+ // }
95
+ };
96
+ // Contract ABI (ethers.js human-readable format)
97
+ exports.NZIP_CONTRACT_ABI = [
98
+ "function publicMintZipFile(string memory merkleRootHash, uint256 creationTimestamp, string memory ipfsHash, string memory metadataURI) public returns (uint256)",
99
+ "function totalSupply() external view returns (uint256)",
100
+ "function getTokensByMerkleRoot(string memory merkleRoot) external view returns (uint256[])",
101
+ "function getTokensByOwner(address owner) external view returns (uint256[])",
102
+ "function getZipFileInfo(uint256 tokenId) external view returns (tuple(string merkleRootHash, string ipfsHash, address creator, uint256 creationTimestamp, uint256 tokenizationTime, uint256 blockNumber))",
103
+ "function ownerOf(uint256 tokenId) external view returns (address)",
104
+ "function balanceOf(address owner) external view returns (uint256)",
105
+ "function isZipFileTokenized(string memory merkleRootHash, uint256 creationTimestamp) external view returns (bool exists, uint256 tokenId)",
106
+ "function verifyZipFile(uint256 tokenId, string memory providedMerkleRoot) external view returns (bool isValid)",
107
+ "function getVersion() external pure returns (string memory)",
108
+ "event Transfer(address indexed from, address indexed to, uint256 indexed tokenId)",
109
+ "event ZipFileTokenized(uint256 indexed tokenId, address indexed creator, string merkleRootHash, uint256 creationTimestamp, string ipfsHash, uint256 tokenizationTime, uint256 blockNumber)"
110
+ ];
111
+ // Contract ABI (Web3.js JSON format)
112
+ exports.NZIP_CONTRACT_ABI_WEB3 = [
113
+ {
114
+ inputs: [
115
+ { name: "merkleRootHash", type: "string" },
116
+ { name: "creationTimestamp", type: "uint256" },
117
+ { name: "ipfsHash", type: "string" },
118
+ { name: "metadataURI", type: "string" }
119
+ ],
120
+ name: "publicMintZipFile",
121
+ outputs: [{ name: "", type: "uint256" }],
122
+ stateMutability: "nonpayable",
123
+ type: "function"
124
+ },
125
+ {
126
+ inputs: [],
127
+ name: "totalSupply",
128
+ outputs: [{ name: "", type: "uint256" }],
129
+ stateMutability: "view",
130
+ type: "function"
131
+ },
132
+ {
133
+ inputs: [{ name: "merkleRoot", type: "string" }],
134
+ name: "getTokensByMerkleRoot",
135
+ outputs: [{ name: "", type: "uint256[]" }],
136
+ stateMutability: "view",
137
+ type: "function"
138
+ },
139
+ {
140
+ inputs: [{ name: "tokenId", type: "uint256" }],
141
+ name: "getZipFileInfo",
142
+ outputs: [
143
+ {
144
+ components: [
145
+ { name: "merkleRootHash", type: "string" },
146
+ { name: "ipfsHash", type: "string" },
147
+ { name: "creator", type: "address" },
148
+ { name: "creationTimestamp", type: "uint256" },
149
+ { name: "tokenizationTime", type: "uint256" },
150
+ { name: "blockNumber", type: "uint256" }
151
+ ],
152
+ name: "",
153
+ type: "tuple"
154
+ }
155
+ ],
156
+ stateMutability: "view",
157
+ type: "function"
158
+ },
159
+ {
160
+ inputs: [{ name: "tokenId", type: "uint256" }],
161
+ name: "ownerOf",
162
+ outputs: [{ name: "", type: "address" }],
163
+ stateMutability: "view",
164
+ type: "function"
165
+ },
166
+ {
167
+ inputs: [{ name: "owner", type: "address" }],
168
+ name: "balanceOf",
169
+ outputs: [{ name: "", type: "uint256" }],
170
+ stateMutability: "view",
171
+ type: "function"
172
+ },
173
+ {
174
+ inputs: [
175
+ { name: "merkleRootHash", type: "string" },
176
+ { name: "creationTimestamp", type: "uint256" }
177
+ ],
178
+ name: "isZipFileTokenized",
179
+ outputs: [
180
+ { name: "exists", type: "bool" },
181
+ { name: "tokenId", type: "uint256" }
182
+ ],
183
+ stateMutability: "view",
184
+ type: "function"
185
+ },
186
+ {
187
+ inputs: [
188
+ { name: "tokenId", type: "uint256" },
189
+ { name: "providedMerkleRoot", type: "string" }
190
+ ],
191
+ name: "verifyZipFile",
192
+ outputs: [{ name: "isValid", type: "bool" }],
193
+ stateMutability: "view",
194
+ type: "function"
195
+ },
196
+ {
197
+ inputs: [],
198
+ name: "getVersion",
199
+ outputs: [{ name: "", type: "string" }],
200
+ stateMutability: "pure",
201
+ type: "function"
202
+ },
203
+ {
204
+ anonymous: false,
205
+ inputs: [
206
+ { indexed: true, name: "from", type: "address" },
207
+ { indexed: true, name: "to", type: "address" },
208
+ { indexed: true, name: "tokenId", type: "uint256" }
209
+ ],
210
+ name: "Transfer",
211
+ type: "event"
212
+ },
213
+ {
214
+ anonymous: false,
215
+ inputs: [
216
+ { indexed: true, name: "tokenId", type: "uint256" },
217
+ { indexed: true, name: "creator", type: "address" },
218
+ { indexed: false, name: "merkleRootHash", type: "string" },
219
+ { indexed: false, name: "creationTimestamp", type: "uint256" },
220
+ { indexed: false, name: "ipfsHash", type: "string" },
221
+ { indexed: false, name: "tokenizationTime", type: "uint256" },
222
+ { indexed: false, name: "blockNumber", type: "uint256" }
223
+ ],
224
+ name: "ZipFileTokenized",
225
+ type: "event"
226
+ }
227
+ ];
228
+ // Default configuration (Base Sepolia for development)
229
+ exports.DEFAULT_NETWORK = 84532;
230
+ exports.CURRENT_DEPLOYMENT = exports.CONTRACT_CONFIGS[exports.DEFAULT_NETWORK];
231
+ // Helper functions
232
+ const getContractConfig = (chainId) => {
233
+ return exports.CONTRACT_CONFIGS[chainId] || exports.CURRENT_DEPLOYMENT;
234
+ };
235
+ exports.getContractConfig = getContractConfig;
236
+ const getSupportedNetworks = () => {
237
+ return Object.keys(exports.CONTRACT_CONFIGS).map(Number);
238
+ };
239
+ exports.getSupportedNetworks = getSupportedNetworks;
240
+ const isNetworkSupported = (chainId) => {
241
+ return chainId in exports.CONTRACT_CONFIGS;
242
+ };
243
+ exports.isNetworkSupported = isNetworkSupported;
244
+ /**
245
+ * Normalize network name for matching (lowercase, trim, replace spaces with hyphens)
246
+ */
247
+ function normalizeNetworkName(networkName) {
248
+ return networkName.toLowerCase().trim().replace(/\s+/g, '-').replace(/_/g, '-');
249
+ }
250
+ /**
251
+ * Get chain ID by network name (supports aliases)
252
+ * Returns chain ID if found, null otherwise
253
+ */
254
+ function getChainIdByName(networkName) {
255
+ const normalized = normalizeNetworkName(networkName);
256
+ // Search through all configs
257
+ for (const [chainIdStr, config] of Object.entries(exports.CONTRACT_CONFIGS)) {
258
+ const chainId = Number(chainIdStr);
259
+ // Check primary network name
260
+ if (normalizeNetworkName(config.network) === normalized) {
261
+ return chainId;
262
+ }
263
+ // Check name aliases
264
+ if (config.nameAliases) {
265
+ for (const alias of config.nameAliases) {
266
+ if (normalizeNetworkName(alias) === normalized) {
267
+ return chainId;
268
+ }
269
+ }
270
+ }
271
+ }
272
+ return null;
273
+ }
274
+ /**
275
+ * Get network configuration by network name (supports aliases)
276
+ * Returns ContractConfig if found, null otherwise
277
+ */
278
+ function getNetworkByName(networkName) {
279
+ const chainId = getChainIdByName(networkName);
280
+ if (chainId === null) {
281
+ return null;
282
+ }
283
+ return (0, exports.getContractConfig)(chainId);
284
+ }
285
+ /**
286
+ * Get all supported network name aliases
287
+ * Returns array of all supported network names (primary + aliases)
288
+ */
289
+ function getSupportedNetworkNames() {
290
+ const names = [];
291
+ for (const config of Object.values(exports.CONTRACT_CONFIGS)) {
292
+ // Add primary network name
293
+ names.push(config.network);
294
+ // Add aliases
295
+ if (config.nameAliases) {
296
+ names.push(...config.nameAliases);
297
+ }
298
+ }
299
+ return names;
300
+ }
301
+ /**
302
+ * Fuzzy match network name (for backward compatibility)
303
+ * Handles partial matches like "sepolia" matching "Base Sepolia" or "Arbitrum Sepolia"
304
+ * Returns best match or null
305
+ */
306
+ function fuzzyMatchNetworkName(networkName) {
307
+ const normalized = normalizeNetworkName(networkName);
308
+ // First try exact match
309
+ const exactMatch = getNetworkByName(networkName);
310
+ if (exactMatch) {
311
+ return exactMatch;
312
+ }
313
+ // Try partial matching
314
+ const matches = [];
315
+ for (const config of Object.values(exports.CONTRACT_CONFIGS)) {
316
+ const configNormalized = normalizeNetworkName(config.network);
317
+ let score = 0;
318
+ // Check if normalized input is contained in config name or vice versa
319
+ if (configNormalized.includes(normalized) || normalized.includes(configNormalized)) {
320
+ score = Math.max(configNormalized.length, normalized.length) / Math.min(configNormalized.length, normalized.length);
321
+ matches.push({ config, score });
322
+ }
323
+ // Check aliases
324
+ if (config.nameAliases) {
325
+ for (const alias of config.nameAliases) {
326
+ const aliasNormalized = normalizeNetworkName(alias);
327
+ if (aliasNormalized.includes(normalized) || normalized.includes(aliasNormalized)) {
328
+ score = Math.max(aliasNormalized.length, normalized.length) / Math.min(aliasNormalized.length, normalized.length);
329
+ matches.push({ config, score });
330
+ }
331
+ }
332
+ }
333
+ }
334
+ // Return best match (highest score)
335
+ if (matches.length > 0) {
336
+ matches.sort((a, b) => b.score - a.score);
337
+ return matches[0].config;
338
+ }
339
+ return null;
340
+ }
341
+ //# sourceMappingURL=contracts.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contracts.js","sourceRoot":"","sources":["../../../src/blockchain/core/contracts.ts"],"names":[],"mappings":";AAAA,+DAA+D;;;AAkQ/D,oDAEC;AAMD,4CAuBC;AAMD,4CAMC;AAMD,4DAcC;AAOD,sDAyCC;AAtWD,8CAA8C;AACjC,QAAA,gBAAgB,GAAmC;IAC9D,iCAAiC;IACjC,KAAK,EAAE;QACL,qFAAqF;QACrF,OAAO,EAAE,4CAA4C,EAAE,4BAA4B;QACnF,OAAO,EAAE,cAAc;QACvB,OAAO,EAAE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
1
+ /**
2
+ * Core Blockchain Module Exports
3
+ * Platform-agnostic blockchain functionality for ZIP file tokenization
4
+ */
5
+ export * from '../../types';
6
+ export { ZipkitMinter, MintingOptions, MintingResult, DuplicateCheckResult, WalletInfo, validatePrivateKey } from './ZipkitMinter';
7
+ export { ZipkitVerifier, VerificationOptions, VerificationResult } from './ZipkitVerifier';
8
+ export { TokenMetadata } from '../../types';
9
+ export { CoreWalletManager, WalletAnalyzer, CommonTokenConfig, TokenInfo, WalletBasicInfo, TokenScanResult, NZipTokenDetails } from './WalletManager';
10
+ export { NZIP_CONTRACT_ABI, NZIP_CONTRACT_ABI_WEB3, CONTRACT_CONFIGS, CURRENT_DEPLOYMENT, DEFAULT_NETWORK, getContractConfig, getSupportedNetworks, isNetworkSupported, getChainIdByName, getSupportedNetworkNames, getNetworkByName, normalizeNetworkName, ContractConfig } from './contracts';
11
+ export { createTimestamp, deserializeOts, parseVerifyResult, upgradeOTS, createOtsMetadataEntry, bufferToArrayBuffer, getOtsEntry, getOtsBuffer, getMerkleRootSafe, verifyOts, verifyOtsZip, TimestampResult, TimestampInfo, DeserializeOtsResult, OtsVerifyResult } from './ZipkitOTS';
12
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/blockchain/core/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,cAAc,aAAa,CAAC;AAE5B,OAAO,EACL,YAAY,EACZ,cAAc,EACd,aAAa,EACb,oBAAoB,EACpB,UAAU,EACV,kBAAkB,EACnB,MAAM,gBAAgB,CAAC;AAExB,OAAO,EACL,cAAc,EACd,mBAAmB,EACnB,kBAAkB,EACnB,MAAM,kBAAkB,CAAC;AAE1B,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAG5C,OAAO,EACL,iBAAiB,EACjB,cAAc,EACd,iBAAiB,EACjB,SAAS,EACT,eAAe,EACf,eAAe,EACf,gBAAgB,EACjB,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EACL,iBAAiB,EACjB,sBAAsB,EACtB,gBAAgB,EAChB,kBAAkB,EAClB,eAAe,EACf,iBAAiB,EACjB,oBAAoB,EACpB,kBAAkB,EAClB,gBAAgB,EAChB,wBAAwB,EACxB,gBAAgB,EAChB,oBAAoB,EACpB,cAAc,EACf,MAAM,aAAa,CAAC;AAGrB,OAAO,EACL,eAAe,EACf,cAAc,EACd,iBAAiB,EACjB,UAAU,EACV,sBAAsB,EACtB,mBAAmB,EACnB,WAAW,EACX,YAAY,EACZ,iBAAiB,EACjB,SAAS,EACT,YAAY,EAEZ,eAAe,EACf,aAAa,EACb,oBAAoB,EACpB,eAAe,EAChB,MAAM,aAAa,CAAC"}
@@ -0,0 +1,59 @@
1
+ "use strict";
2
+ /**
3
+ * Core Blockchain Module Exports
4
+ * Platform-agnostic blockchain functionality for ZIP file tokenization
5
+ */
6
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
7
+ if (k2 === undefined) k2 = k;
8
+ var desc = Object.getOwnPropertyDescriptor(m, k);
9
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
10
+ desc = { enumerable: true, get: function() { return m[k]; } };
11
+ }
12
+ Object.defineProperty(o, k2, desc);
13
+ }) : (function(o, m, k, k2) {
14
+ if (k2 === undefined) k2 = k;
15
+ o[k2] = m[k];
16
+ }));
17
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
18
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
19
+ };
20
+ Object.defineProperty(exports, "__esModule", { value: true });
21
+ exports.verifyOtsZip = exports.verifyOts = exports.getMerkleRootSafe = exports.getOtsBuffer = exports.getOtsEntry = exports.bufferToArrayBuffer = exports.createOtsMetadataEntry = exports.upgradeOTS = exports.parseVerifyResult = exports.deserializeOts = exports.createTimestamp = exports.normalizeNetworkName = exports.getNetworkByName = exports.getSupportedNetworkNames = exports.getChainIdByName = exports.isNetworkSupported = exports.getSupportedNetworks = exports.getContractConfig = exports.DEFAULT_NETWORK = exports.CURRENT_DEPLOYMENT = exports.CONTRACT_CONFIGS = exports.NZIP_CONTRACT_ABI_WEB3 = exports.NZIP_CONTRACT_ABI = exports.WalletAnalyzer = exports.CoreWalletManager = exports.ZipkitVerifier = exports.validatePrivateKey = exports.ZipkitMinter = void 0;
22
+ // Export all types from consolidated types location
23
+ __exportStar(require("../../types"), exports);
24
+ var ZipkitMinter_1 = require("./ZipkitMinter");
25
+ Object.defineProperty(exports, "ZipkitMinter", { enumerable: true, get: function () { return ZipkitMinter_1.ZipkitMinter; } });
26
+ Object.defineProperty(exports, "validatePrivateKey", { enumerable: true, get: function () { return ZipkitMinter_1.validatePrivateKey; } });
27
+ var ZipkitVerifier_1 = require("./ZipkitVerifier");
28
+ Object.defineProperty(exports, "ZipkitVerifier", { enumerable: true, get: function () { return ZipkitVerifier_1.ZipkitVerifier; } });
29
+ // Export core wallet functionality
30
+ var WalletManager_1 = require("./WalletManager");
31
+ Object.defineProperty(exports, "CoreWalletManager", { enumerable: true, get: function () { return WalletManager_1.CoreWalletManager; } });
32
+ Object.defineProperty(exports, "WalletAnalyzer", { enumerable: true, get: function () { return WalletManager_1.WalletAnalyzer; } });
33
+ var contracts_1 = require("./contracts");
34
+ Object.defineProperty(exports, "NZIP_CONTRACT_ABI", { enumerable: true, get: function () { return contracts_1.NZIP_CONTRACT_ABI; } });
35
+ Object.defineProperty(exports, "NZIP_CONTRACT_ABI_WEB3", { enumerable: true, get: function () { return contracts_1.NZIP_CONTRACT_ABI_WEB3; } });
36
+ Object.defineProperty(exports, "CONTRACT_CONFIGS", { enumerable: true, get: function () { return contracts_1.CONTRACT_CONFIGS; } });
37
+ Object.defineProperty(exports, "CURRENT_DEPLOYMENT", { enumerable: true, get: function () { return contracts_1.CURRENT_DEPLOYMENT; } });
38
+ Object.defineProperty(exports, "DEFAULT_NETWORK", { enumerable: true, get: function () { return contracts_1.DEFAULT_NETWORK; } });
39
+ Object.defineProperty(exports, "getContractConfig", { enumerable: true, get: function () { return contracts_1.getContractConfig; } });
40
+ Object.defineProperty(exports, "getSupportedNetworks", { enumerable: true, get: function () { return contracts_1.getSupportedNetworks; } });
41
+ Object.defineProperty(exports, "isNetworkSupported", { enumerable: true, get: function () { return contracts_1.isNetworkSupported; } });
42
+ Object.defineProperty(exports, "getChainIdByName", { enumerable: true, get: function () { return contracts_1.getChainIdByName; } });
43
+ Object.defineProperty(exports, "getSupportedNetworkNames", { enumerable: true, get: function () { return contracts_1.getSupportedNetworkNames; } });
44
+ Object.defineProperty(exports, "getNetworkByName", { enumerable: true, get: function () { return contracts_1.getNetworkByName; } });
45
+ Object.defineProperty(exports, "normalizeNetworkName", { enumerable: true, get: function () { return contracts_1.normalizeNetworkName; } });
46
+ // Export OpenTimestamps utilities
47
+ var ZipkitOTS_1 = require("./ZipkitOTS");
48
+ Object.defineProperty(exports, "createTimestamp", { enumerable: true, get: function () { return ZipkitOTS_1.createTimestamp; } });
49
+ Object.defineProperty(exports, "deserializeOts", { enumerable: true, get: function () { return ZipkitOTS_1.deserializeOts; } });
50
+ Object.defineProperty(exports, "parseVerifyResult", { enumerable: true, get: function () { return ZipkitOTS_1.parseVerifyResult; } });
51
+ Object.defineProperty(exports, "upgradeOTS", { enumerable: true, get: function () { return ZipkitOTS_1.upgradeOTS; } });
52
+ Object.defineProperty(exports, "createOtsMetadataEntry", { enumerable: true, get: function () { return ZipkitOTS_1.createOtsMetadataEntry; } });
53
+ Object.defineProperty(exports, "bufferToArrayBuffer", { enumerable: true, get: function () { return ZipkitOTS_1.bufferToArrayBuffer; } });
54
+ Object.defineProperty(exports, "getOtsEntry", { enumerable: true, get: function () { return ZipkitOTS_1.getOtsEntry; } });
55
+ Object.defineProperty(exports, "getOtsBuffer", { enumerable: true, get: function () { return ZipkitOTS_1.getOtsBuffer; } });
56
+ Object.defineProperty(exports, "getMerkleRootSafe", { enumerable: true, get: function () { return ZipkitOTS_1.getMerkleRootSafe; } });
57
+ Object.defineProperty(exports, "verifyOts", { enumerable: true, get: function () { return ZipkitOTS_1.verifyOts; } });
58
+ Object.defineProperty(exports, "verifyOtsZip", { enumerable: true, get: function () { return ZipkitOTS_1.verifyOtsZip; } });
59
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/blockchain/core/index.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;;;;;;;;;;;;;;;AAEH,oDAAoD;AACpD,8CAA4B;AAE5B,+CAOwB;AANtB,4GAAA,YAAY,OAAA;AAKZ,kHAAA,kBAAkB,OAAA;AAGpB,mDAI0B;AAHxB,gHAAA,cAAc,OAAA;AAOhB,mCAAmC;AACnC,iDAQyB;AAPvB,kHAAA,iBAAiB,OAAA;AACjB,+GAAA,cAAc,OAAA;AAQhB,yCAcqB;AAbnB,8GAAA,iBAAiB,OAAA;AACjB,mHAAA,sBAAsB,OAAA;AACtB,6GAAA,gBAAgB,OAAA;AAChB,+GAAA,kBAAkB,OAAA;AAClB,4GAAA,eAAe,OAAA;AACf,8GAAA,iBAAiB,OAAA;AACjB,iHAAA,oBAAoB,OAAA;AACpB,+GAAA,kBAAkB,OAAA;AAClB,6GAAA,gBAAgB,OAAA;AAChB,qHAAA,wBAAwB,OAAA;AACxB,6GAAA,gBAAgB,OAAA;AAChB,iHAAA,oBAAoB,OAAA;AAItB,kCAAkC;AAClC,yCAiBqB;AAhBnB,4GAAA,eAAe,OAAA;AACf,2GAAA,cAAc,OAAA;AACd,8GAAA,iBAAiB,OAAA;AACjB,uGAAA,UAAU,OAAA;AACV,mHAAA,sBAAsB,OAAA;AACtB,gHAAA,mBAAmB,OAAA;AACnB,wGAAA,WAAW,OAAA;AACX,yGAAA,YAAY,OAAA;AACZ,8GAAA,iBAAiB,OAAA;AACjB,sGAAA,SAAS,OAAA;AACT,yGAAA,YAAY,OAAA"}
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Blockchain Module Exports
3
+ * Unified blockchain functionality for ZIP file tokenization
4
+ */
5
+ export * from './core';
6
+ export * from './browser';
7
+ export { WalletManagerNode, ZipkitWallet } from './node';
8
+ export type { EnhancedVerificationResult, BatchVerificationResult, VerificationJob } from './core/ZipkitVerifier';
9
+ export { Logger, configureLoggerFromEnvironment } from '../core';
10
+ export type { LogLevel, LoggerConfig } from '../core';
11
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/blockchain/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,cAAc,QAAQ,CAAC;AAGvB,cAAc,WAAW,CAAC;AAG1B,OAAO,EACL,iBAAiB,EACjB,YAAY,EACb,MAAM,QAAQ,CAAC;AAGhB,YAAY,EACV,0BAA0B,EAC1B,uBAAuB,EACvB,eAAe,EAChB,MAAM,uBAAuB,CAAC;AAG/B,OAAO,EAAE,MAAM,EAAE,8BAA8B,EAAE,MAAM,SAAS,CAAC;AACjE,YAAY,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC"}
@@ -0,0 +1,34 @@
1
+ "use strict";
2
+ /**
3
+ * Blockchain Module Exports
4
+ * Unified blockchain functionality for ZIP file tokenization
5
+ */
6
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
7
+ if (k2 === undefined) k2 = k;
8
+ var desc = Object.getOwnPropertyDescriptor(m, k);
9
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
10
+ desc = { enumerable: true, get: function() { return m[k]; } };
11
+ }
12
+ Object.defineProperty(o, k2, desc);
13
+ }) : (function(o, m, k, k2) {
14
+ if (k2 === undefined) k2 = k;
15
+ o[k2] = m[k];
16
+ }));
17
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
18
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
19
+ };
20
+ Object.defineProperty(exports, "__esModule", { value: true });
21
+ exports.configureLoggerFromEnvironment = exports.Logger = exports.ZipkitWallet = exports.WalletManagerNode = void 0;
22
+ // Export core blockchain functionality (platform-agnostic)
23
+ __exportStar(require("./core"), exports);
24
+ // Export browser-specific blockchain functionality
25
+ __exportStar(require("./browser"), exports);
26
+ // Export Node.js-specific blockchain functionality (only WalletManagerNode is Node-specific)
27
+ var node_1 = require("./node");
28
+ Object.defineProperty(exports, "WalletManagerNode", { enumerable: true, get: function () { return node_1.WalletManagerNode; } });
29
+ Object.defineProperty(exports, "ZipkitWallet", { enumerable: true, get: function () { return node_1.ZipkitWallet; } });
30
+ // Export Logger utility for console control (from core module)
31
+ var core_1 = require("../core");
32
+ Object.defineProperty(exports, "Logger", { enumerable: true, get: function () { return core_1.Logger; } });
33
+ Object.defineProperty(exports, "configureLoggerFromEnvironment", { enumerable: true, get: function () { return core_1.configureLoggerFromEnvironment; } });
34
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/blockchain/index.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;;;;;;;;;;;;;;;AAEH,2DAA2D;AAC3D,yCAAuB;AAEvB,mDAAmD;AACnD,4CAA0B;AAE1B,6FAA6F;AAC7F,+BAGgB;AAFd,yGAAA,iBAAiB,OAAA;AACjB,oGAAA,YAAY,OAAA;AAUd,+DAA+D;AAC/D,gCAAiE;AAAxD,8FAAA,MAAM,OAAA;AAAE,sHAAA,8BAA8B,OAAA"}
@@ -0,0 +1,47 @@
1
+ /**
2
+ * WalletManagerNode - Node.js-specific wallet functionality with file system operations
3
+ * Extends CoreWalletManager with file-based wallet management
4
+ */
5
+ import { CoreWalletManager } from '../core/WalletManager';
6
+ import { WalletSetupResult, MintingOptions } from '../../types';
7
+ /**
8
+ * Node.js-specific wallet manager with file system operations
9
+ */
10
+ export declare class WalletManagerNode extends CoreWalletManager {
11
+ constructor();
12
+ /**
13
+ * Setup wallet with file system support
14
+ */
15
+ setupWalletWithOptions(options: MintingOptions): Promise<WalletSetupResult>;
16
+ /**
17
+ * Find existing wallet files
18
+ */
19
+ private findExistingWallets;
20
+ /**
21
+ * Load wallet from file
22
+ *
23
+ * SECURITY WARNING: This method reads private keys from disk.
24
+ * - Only use for development/testing
25
+ * - Wallet files are automatically excluded from git via .gitignore
26
+ * - Wallet files are excluded from NPM packages via .npmignore
27
+ * - Use secure key management (HSMs, KMS) for production
28
+ */
29
+ private loadWalletFromFile;
30
+ /**
31
+ * Create a new wallet and save to file
32
+ *
33
+ * SECURITY WARNING: This method saves private keys to disk.
34
+ * - Only use for development/testing
35
+ * - Never commit wallet files to version control
36
+ * - Use secure key management for production
37
+ * - Wallet files are automatically excluded via .gitignore and .npmignore
38
+ * - Protect file system permissions on wallet files
39
+ */
40
+ private createNewWallet;
41
+ /**
42
+ * Detect NZIP contract from deployment file
43
+ */
44
+ static detectNZipContract(): string | undefined;
45
+ }
46
+ export { WalletManagerNode as ZipkitWallet };
47
+ //# sourceMappingURL=WalletManagerNode.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WalletManagerNode.d.ts","sourceRoot":"","sources":["../../../src/blockchain/node/WalletManagerNode.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAKH,OAAO,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAC1D,OAAO,EAAE,iBAAiB,EAAc,cAAc,EAAE,MAAM,aAAa,CAAC;AAG5E;;GAEG;AACH,qBAAa,iBAAkB,SAAQ,iBAAiB;;IAKtD;;OAEG;IACG,sBAAsB,CAAC,OAAO,EAAE,cAAc,GAAG,OAAO,CAAC,iBAAiB,CAAC;IAwCjF;;OAEG;IACH,OAAO,CAAC,mBAAmB;IAqB3B;;;;;;;;OAQG;IACH,OAAO,CAAC,kBAAkB;IAuB1B;;;;;;;;;OASG;YACW,eAAe;IAyB7B;;OAEG;IACH,MAAM,CAAC,kBAAkB,IAAI,MAAM,GAAG,SAAS;CAUhD;AAGD,OAAO,EAAE,iBAAiB,IAAI,YAAY,EAAE,CAAC"}