v1.48.1: auditoría en frío, parche 3 — validaciones de formato, fuera el motor automático, transacciones reales como pruebas
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01L5npnUYgSPkAaHkdaeUqBr
This commit is contained in:
Vendored
+413
@@ -0,0 +1,413 @@
|
||||
{
|
||||
"_nota": "Transacciones reales y públicas del contraste con am-i-exposed y Blockchair (25-oct-2026). Datos de mempool.space, recortados a los campos que usa el analizador (sin testigos ni scriptSig). Ver COMPARATIVA-AIE.md (privado) y el roadmap de la auditoría en frío.",
|
||||
"txs": {
|
||||
"whirlpool": {
|
||||
"txid": "323df21f0b0756f98336437aa3d2fb87e02b59f1946b714a7b09df04d429dec2",
|
||||
"version": 1,
|
||||
"locktime": 0,
|
||||
"size": 911,
|
||||
"weight": 2021,
|
||||
"fee": 30000,
|
||||
"status": {
|
||||
"confirmed": true,
|
||||
"block_height": 574682,
|
||||
"block_time": 1557046992
|
||||
},
|
||||
"vin": [
|
||||
{
|
||||
"txid": "333f45431e47b9543772013ac83a9b33cc58dc3245ccfd48b972107bb8405c13",
|
||||
"vout": 8,
|
||||
"sequence": 4294967295,
|
||||
"is_coinbase": false,
|
||||
"prevout": {
|
||||
"value": 5010000,
|
||||
"scriptpubkey": "001443985bccbe28f2678ee90c7169a5b620d167d6a5",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1qgwv9hn979rex0rhfp3cknfdkyrgk04493gclvv"
|
||||
}
|
||||
},
|
||||
{
|
||||
"txid": "5fab266662be1b2705aa5790b1924978c14e7c1525d6966f5aaa129bc8f62695",
|
||||
"vout": 1,
|
||||
"sequence": 4294967295,
|
||||
"is_coinbase": false,
|
||||
"prevout": {
|
||||
"value": 5000000,
|
||||
"scriptpubkey": "00145d9105feb5163eb6374a87ad85997204aeb78b7c",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1qtkgstl44zcltvd62s7kctxtjqjht0zmufhqr9f"
|
||||
}
|
||||
},
|
||||
{
|
||||
"txid": "8a9d461ef53ac3d6c13b5d80720996a0a93b1a7adbc6c68ba8c29733aa5d8c16",
|
||||
"vout": 150,
|
||||
"sequence": 4294967295,
|
||||
"is_coinbase": false,
|
||||
"prevout": {
|
||||
"value": 5010000,
|
||||
"scriptpubkey": "0014a28e1237a5792b22cf801e37aa0fe611566fc973",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1q528pyda90y4j9nuqrcm65rlxz9txljtn208dqm"
|
||||
}
|
||||
},
|
||||
{
|
||||
"txid": "b76e75372049605789cae79d60635be1fa483d1d2c877a05ec93fb9b199384a4",
|
||||
"vout": 2,
|
||||
"sequence": 4294967295,
|
||||
"is_coinbase": false,
|
||||
"prevout": {
|
||||
"value": 5000000,
|
||||
"scriptpubkey": "00149f39ae1db51efd6eb3639e4338ebeb5d10097169",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1qnuu6u8d4rm7kavmrnepn36ltt5gqjutf34rtfv"
|
||||
}
|
||||
},
|
||||
{
|
||||
"txid": "c209f94473c3cf044bd2d5245ac90a87df96cfed38436466dee25447bff4ab72",
|
||||
"vout": 3,
|
||||
"sequence": 4294967295,
|
||||
"is_coinbase": false,
|
||||
"prevout": {
|
||||
"value": 5010000,
|
||||
"scriptpubkey": "001439c8c5c60037afcc41d996e7df0581c551df49fc",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1q88yvt3sqx7hucswejmna7pvpc4ga7j0ukfppwq"
|
||||
}
|
||||
}
|
||||
],
|
||||
"vout": [
|
||||
{
|
||||
"value": 5000000,
|
||||
"scriptpubkey": "001406f788c2baca46d03e48fdd27f9e48799d1f64c8",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1qqmmc3s46efrdq0jglhf8l8jg0xw37exgne6q3k"
|
||||
},
|
||||
{
|
||||
"value": 5000000,
|
||||
"scriptpubkey": "00141caf1f8283db1d5e6f90fa020c4f44bfcb81d995",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1qrjh3lq5rmvw4umuslgpqcn6yhl9crkv45z03gg"
|
||||
},
|
||||
{
|
||||
"value": 5000000,
|
||||
"scriptpubkey": "0014239c27def665e5136b29d14cf1e5c2d325d1f0c0",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1qywwz0hhkvhj3x6ef69x0rewz6vjaruxqxva0fz"
|
||||
},
|
||||
{
|
||||
"value": 5000000,
|
||||
"scriptpubkey": "00144e1fa58e6c601117d4ccb2450699a3c1222d6535",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1qfc06trnvvqg304xvkfzsdxdrcy3z6ef4lflsxt"
|
||||
},
|
||||
{
|
||||
"value": 5000000,
|
||||
"scriptpubkey": "0014be588d8043f9a40edfbbed135691a3cee3c4d59d",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1qhevgmqzrlxjqahama5f4dydrem3uf4vaj43kg2"
|
||||
}
|
||||
]
|
||||
},
|
||||
"joinmarket": {
|
||||
"txid": "4f112abd2eefe3484a7bbf7c1731f784cba19de677468835145e9c448fb18b7d",
|
||||
"version": 2,
|
||||
"locktime": 878484,
|
||||
"size": 433,
|
||||
"weight": 1081,
|
||||
"fee": 1290,
|
||||
"status": {
|
||||
"confirmed": true,
|
||||
"block_height": 878487,
|
||||
"block_time": 1736432008
|
||||
},
|
||||
"vin": [
|
||||
{
|
||||
"txid": "b38b9fbe1976e3aa5e878e32597d847cf945df84119036e18e3b73a914922656",
|
||||
"vout": 0,
|
||||
"sequence": 4294967294,
|
||||
"is_coinbase": false,
|
||||
"prevout": {
|
||||
"value": 148798,
|
||||
"scriptpubkey": "0014a4cfdb3413cdc02b847fe9a9517dc3c193baa3c2",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1q5n8akdqnehqzhprlax54zlwrcxfm4g7znc4m9c"
|
||||
}
|
||||
},
|
||||
{
|
||||
"txid": "be47e5560c0f369f4abc373f19c34bff9bc757acbee68057c5147b9ebbf88048",
|
||||
"vout": 4,
|
||||
"sequence": 4294967294,
|
||||
"is_coinbase": false,
|
||||
"prevout": {
|
||||
"value": 1448113,
|
||||
"scriptpubkey": "0014eff2d096e1b800809f84f7e7e170502213efdb2b",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1qaledp9hphqqgp8uy7ln7zuzsygf7lketjvxgzd"
|
||||
}
|
||||
}
|
||||
],
|
||||
"vout": [
|
||||
{
|
||||
"value": 46981,
|
||||
"scriptpubkey": "0014784e7b3c069bb4f20d190a4991aaf382827463d1",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1q0p88k0qxnw60yrgepfyer2hns2p8gc73j9yhq9"
|
||||
},
|
||||
{
|
||||
"value": 100420,
|
||||
"scriptpubkey": "0014808cbff1a1a3b4ec88bfb0276f0fd6f76914be05",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1qszxtludp5w6wez9lkqnk7r7k7a53f0s9v30jxd"
|
||||
},
|
||||
{
|
||||
"value": 1347800,
|
||||
"scriptpubkey": "0014a4a8fa2008d2ed5a0da3d182d2a81b976e9cf9b2",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1q5j505gqg6tk45rdr6xpd92qmjahfe7djml36ey"
|
||||
},
|
||||
{
|
||||
"value": 100420,
|
||||
"scriptpubkey": "001416c03664cb044ea82fa93d0320fb916a7fdc48f4",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1qzmqrvextq382staf85pjp7u3dflacj85r9k9jf"
|
||||
}
|
||||
]
|
||||
},
|
||||
"taproot_opreturn": {
|
||||
"txid": "0bf67b1f05326afbd613e11631a2b86466ac7e255499f6286e31b9d7d889cee7",
|
||||
"version": 1,
|
||||
"locktime": 0,
|
||||
"size": 401,
|
||||
"weight": 800,
|
||||
"fee": 4020,
|
||||
"status": {
|
||||
"confirmed": true,
|
||||
"block_height": 709635,
|
||||
"block_time": 1636868413
|
||||
},
|
||||
"vin": [
|
||||
{
|
||||
"txid": "436be185c1021ff7ded3d44ca18b144ec97b1ffea602ecf54a985ed1177beb67",
|
||||
"vout": 0,
|
||||
"sequence": 4294967294,
|
||||
"is_coinbase": false,
|
||||
"prevout": {
|
||||
"value": 6490,
|
||||
"scriptpubkey": "51200bbccdfb4b7a53aaccec0777d39d596f71ca936dd433bd15a69dec6ed60469b1",
|
||||
"scriptpubkey_type": "v1_p2tr",
|
||||
"scriptpubkey_address": "bc1ppw7vm76t0ff64n8vqama882edacu4ymd6sem69dxnhkxa4sydxcstcuh40"
|
||||
}
|
||||
}
|
||||
],
|
||||
"vout": [
|
||||
{
|
||||
"value": 1000,
|
||||
"scriptpubkey": "6a27e2889e2f32316d696c6c696f6e2e205468616e6b73205361746f7368692120e28094426974476f",
|
||||
"scriptpubkey_type": "op_return"
|
||||
},
|
||||
{
|
||||
"value": 1470,
|
||||
"scriptpubkey": "a9148432893b31905290618a5cce909b32978ab7f12a87",
|
||||
"scriptpubkey_type": "p2sh",
|
||||
"scriptpubkey_address": "3Dk1fAx11VSiTFyiWkZK8JUoLsuQ31RUNV"
|
||||
}
|
||||
]
|
||||
},
|
||||
"simple": {
|
||||
"txid": "0b6461de422c46a221db99608fcbe0326e4f2325ebf2a47c9faf660ed61ee6a4",
|
||||
"version": 1,
|
||||
"locktime": 399983,
|
||||
"size": 226,
|
||||
"weight": 904,
|
||||
"fee": 10000,
|
||||
"status": {
|
||||
"confirmed": true,
|
||||
"block_height": 399996,
|
||||
"block_time": 1456416472
|
||||
},
|
||||
"vin": [
|
||||
{
|
||||
"txid": "09dc22bb36e520e4e1120a1d5659dbb3d07bdc29ee42850b539eddecd4e036e6",
|
||||
"vout": 1,
|
||||
"sequence": 4294967294,
|
||||
"is_coinbase": false,
|
||||
"prevout": {
|
||||
"value": 83013905944,
|
||||
"scriptpubkey": "76a914c6df807683c6a26f25eebf2add7017098a55cc8a88ac",
|
||||
"scriptpubkey_type": "p2pkh",
|
||||
"scriptpubkey_address": "1K8YYAJJN3E3KD9FFPUXGAxQEVbt2hVj1M"
|
||||
}
|
||||
}
|
||||
],
|
||||
"vout": [
|
||||
{
|
||||
"value": 39852779,
|
||||
"scriptpubkey": "76a914cb4f45b4ecfe54b25106a919237cf34ce193c1b988ac",
|
||||
"scriptpubkey_type": "p2pkh",
|
||||
"scriptpubkey_address": "1KY18ssAXBZ5iX8zVQiLF7UKpBUx6Phj3H"
|
||||
},
|
||||
{
|
||||
"value": 82974043165,
|
||||
"scriptpubkey": "76a91455ae51684c43435da751ac8d2173b2652eb6410588ac",
|
||||
"scriptpubkey_type": "p2pkh",
|
||||
"scriptpubkey_address": "18p3G8gQ3oKy4U9EqnWs7UZswdqAMhE3r8"
|
||||
}
|
||||
]
|
||||
},
|
||||
"dust": {
|
||||
"txid": "655c533bf059721cec9d3d70b3171a07997991a02fedfa1c9b593abc645e1cc5",
|
||||
"version": 2,
|
||||
"locktime": 545753,
|
||||
"size": 225,
|
||||
"weight": 900,
|
||||
"fee": 226,
|
||||
"status": {
|
||||
"confirmed": true,
|
||||
"block_height": 545760,
|
||||
"block_time": 1539550430
|
||||
},
|
||||
"vin": [
|
||||
{
|
||||
"txid": "67fde18fe140073483325ff02b7885bb6af95b2ac18d79fcd34455af5edd7609",
|
||||
"vout": 1,
|
||||
"sequence": 4294967293,
|
||||
"is_coinbase": false,
|
||||
"prevout": {
|
||||
"value": 34313,
|
||||
"scriptpubkey": "76a914662367a3d78a4b0fcbb3020b3d724981d10934f688ac",
|
||||
"scriptpubkey_type": "p2pkh",
|
||||
"scriptpubkey_address": "1AK4LYE6PYwBmSYHQX3v2UsXXHTvCAsJeK"
|
||||
}
|
||||
}
|
||||
],
|
||||
"vout": [
|
||||
{
|
||||
"value": 555,
|
||||
"scriptpubkey": "76a914628d52443573305b34167c0f2b6cbf0b8dde76fd88ac",
|
||||
"scriptpubkey_type": "p2pkh",
|
||||
"scriptpubkey_address": "19z6WynrjHeD5MMv6919BuQRwybuen1sRv"
|
||||
},
|
||||
{
|
||||
"value": 33532,
|
||||
"scriptpubkey": "76a914662367a3d78a4b0fcbb3020b3d724981d10934f688ac",
|
||||
"scriptpubkey_type": "p2pkh",
|
||||
"scriptpubkey_address": "1AK4LYE6PYwBmSYHQX3v2UsXXHTvCAsJeK"
|
||||
}
|
||||
]
|
||||
},
|
||||
"hodlhodl": {
|
||||
"txid": "7723b1bba65cfe805e9dc19fd3981791bdd0984afd5d144bf78abc3bdd522577",
|
||||
"version": 1,
|
||||
"locktime": 0,
|
||||
"size": 402,
|
||||
"weight": 846,
|
||||
"fee": 709,
|
||||
"status": {
|
||||
"confirmed": true,
|
||||
"block_height": 867583,
|
||||
"block_time": 1730031351
|
||||
},
|
||||
"vin": [
|
||||
{
|
||||
"txid": "00627dedcaddf995632a9ab806a9aee4a9e1ec4be95fd362981fd53f519ab5b6",
|
||||
"vout": 1,
|
||||
"sequence": 4294967295,
|
||||
"is_coinbase": false,
|
||||
"prevout": {
|
||||
"value": 87234,
|
||||
"scriptpubkey": "a914d71fecff831d3acd6f5f6932d33b3df22841703587",
|
||||
"scriptpubkey_type": "p2sh",
|
||||
"scriptpubkey_address": "3MJVT2ddTmrLWpg5B9rUXMpSGR4muMKgk8"
|
||||
}
|
||||
}
|
||||
],
|
||||
"vout": [
|
||||
{
|
||||
"value": 85829,
|
||||
"scriptpubkey": "001495f770898312c1d19922645d9f68a7e1aa92ca9c",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1qjhmhpzvrztqarxfzv3we7698ux4f9j5uum047z"
|
||||
},
|
||||
{
|
||||
"value": 696,
|
||||
"scriptpubkey": "001406f625bd53e5460365f186542005da8d9f6bcdc0",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1qqmmzt02nu4rqxe03se2zqpw63k0khnwq959zxq"
|
||||
}
|
||||
]
|
||||
},
|
||||
"sweep": {
|
||||
"txid": "d41bdca5474d5405153fe9cd57163eea72f16534ea0ac0ad3fd8d46aed2e3a09",
|
||||
"version": 2,
|
||||
"locktime": 0,
|
||||
"size": 191,
|
||||
"weight": 437,
|
||||
"fee": 2025,
|
||||
"status": {
|
||||
"confirmed": true,
|
||||
"block_height": 714571,
|
||||
"block_time": 1639770690
|
||||
},
|
||||
"vin": [
|
||||
{
|
||||
"txid": "a8f4edaaf60fcd8776a1750f3a0fa8d056aa2e11389ca10b835c10006bdac3ea",
|
||||
"vout": 0,
|
||||
"sequence": 4294967295,
|
||||
"is_coinbase": false,
|
||||
"prevout": {
|
||||
"value": 973702,
|
||||
"scriptpubkey": "00149fa967156792152beeccfbc8d2207ec5d4a6ff3c",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1qn75kw9t8jg2jhmkvl0ydygr7ch22dleu4jrjtj"
|
||||
}
|
||||
}
|
||||
],
|
||||
"vout": [
|
||||
{
|
||||
"value": 971677,
|
||||
"scriptpubkey": "00141fc1042f92aa972c8d4d67c1462293f6e1c5fa49",
|
||||
"scriptpubkey_type": "v0_p2wpkh",
|
||||
"scriptpubkey_address": "bc1qrlqsgtuj42tjer2dvlq5vg5n7msut7jf783d6c"
|
||||
}
|
||||
]
|
||||
},
|
||||
"hal": {
|
||||
"txid": "f4184fc596403b9d638783cf57adfe4c75c605f6356fbc91338530e9831e9e16",
|
||||
"version": 1,
|
||||
"locktime": 0,
|
||||
"size": 275,
|
||||
"weight": 1100,
|
||||
"fee": 0,
|
||||
"status": {
|
||||
"confirmed": true,
|
||||
"block_height": 170,
|
||||
"block_time": 1231731025
|
||||
},
|
||||
"vin": [
|
||||
{
|
||||
"txid": "0437cd7f8525ceed2324359c2d0ba26006d92d856a9c20fa0241106ee5a597c9",
|
||||
"vout": 0,
|
||||
"sequence": 4294967295,
|
||||
"is_coinbase": false,
|
||||
"prevout": {
|
||||
"value": 5000000000,
|
||||
"scriptpubkey": "410411db93e1dcdb8a016b49840f8c53bc1eb68a382e97b1482ecad7b148a6909a5cb2e0eaddfb84ccf9744464f82e160bfa9b8b64f9d4c03f999b8643f656b412a3ac",
|
||||
"scriptpubkey_type": "p2pk"
|
||||
}
|
||||
}
|
||||
],
|
||||
"vout": [
|
||||
{
|
||||
"value": 1000000000,
|
||||
"scriptpubkey": "4104ae1a62fe09c5f51b13905f07f06b99a2f7159b2225f374cd378d71302fa28414e7aab37397f554a7df5f142c21c1b7303b8a0626f1baded5c72a704f7e6cd84cac",
|
||||
"scriptpubkey_type": "p2pk"
|
||||
},
|
||||
{
|
||||
"value": 4000000000,
|
||||
"scriptpubkey": "410411db93e1dcdb8a016b49840f8c53bc1eb68a382e97b1482ecad7b148a6909a5cb2e0eaddfb84ccf9744464f82e160bfa9b8b64f9d4c03f999b8643f656b412a3ac",
|
||||
"scriptpubkey_type": "p2pk"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
+1
-1
@@ -34,7 +34,7 @@ const motor = cut("// ── FORMATO: lógica pura", "// ── fin formato") +
|
||||
+ cut("function behavioralChangeGuess", "// Busca la tx que gasta un output concreto") + "\n"
|
||||
+ cut("function detectPeelingChains", "// ── Motor de rastreo forense") + "\n"
|
||||
+ cut("const ALMACEN_PREFIJO", "// ── fin almacén") + "\n"
|
||||
+ cut("function parsePsbt", "// ── Auditoría de PSBT");
|
||||
+ cut("// ── Parser PSBT (BIP174)", "// ── Auditoría de PSBT");
|
||||
const E = new Function("crypto", preludio + motor + `
|
||||
return { analyzeTx, analyzeAddress, guessChangeOutput, detectWallets, fraseBanda, roundness,
|
||||
buildWalletReport, behavioralChangeGuess, combineChangeSignals, detectPeelingChains,
|
||||
|
||||
+1
-1
@@ -18,7 +18,7 @@ const ok = (n, c, x) => { console.log(` ${c ? "✓" : "✗"} ${n}`); if (!c &&
|
||||
const P = new Function(`const C = {}; const ENTITY_INDEX = new Map();
|
||||
${cut("// ── FORMATO: lógica pura", "// ── fin formato")}
|
||||
${cut("function roundness", "const FORMATO_DIR")}
|
||||
${cut("function parsePsbt", "// ── Auditoría de PSBT")}
|
||||
${cut("// ── Parser PSBT (BIP174)", "// ── Auditoría de PSBT")}
|
||||
${cut("const mensajeTxNoLlega", "async function apiGetJson")}
|
||||
return { parsePsbt, analyzePsbt, leerTxPrevia, mensajeTxNoLlega };`)();
|
||||
|
||||
|
||||
+174
@@ -0,0 +1,174 @@
|
||||
// v1.48.1 — segundo parche de la auditoría en frío: validaciones de formato.
|
||||
//
|
||||
// · A2-03: un testigo final vacío ya no cuenta como «firma final puesta».
|
||||
// · A2-04: claves BIP32 de profundidad 0 con padre o índice ≠ 0 (vectores
|
||||
// inválidos oficiales de BIP32) se rechazan.
|
||||
// · A2-05: importes de más de 21 millones de BTC en una PSBT se rechazan.
|
||||
// · A2-06: witness_utxo con longitud de script en CompactSize de 3 bytes.
|
||||
// · A2-07: BBQr comprimido con tope de 4 MB al descomprimir.
|
||||
// · A3-06: direcciones bech32 con relleno inválido (BIP173) se rechazan.
|
||||
// · A3-07: un «autoenvío» con una entrada sin dirección (P2PK) no se afirma.
|
||||
// · A4-03: el reparto proporcional conserva la suma.
|
||||
// · A4-07: las notas y declaraciones van como cita en el Markdown.
|
||||
// · A1-04: «Borrar todo» no deja que lo que estaba en vuelo repueble la caché.
|
||||
//
|
||||
// Uso: node tests/test37.js
|
||||
|
||||
const lines = require("./fuente.js")().split("\n");
|
||||
const cut = (desde, hasta) => {
|
||||
const s = lines.findIndex(l => l.includes(desde));
|
||||
const e = lines.findIndex((l, i) => i > s && l.includes(hasta));
|
||||
if (s === -1 || e === -1) { console.error(`No se localiza «${desde}» en el código de la app`); process.exit(1); }
|
||||
return lines.slice(s, e).join("\n");
|
||||
};
|
||||
const fn = (cabecera) => {
|
||||
const s = lines.findIndex(l => l.startsWith(cabecera));
|
||||
const e = lines.findIndex((l, i) => i > s && l === " }");
|
||||
if (s === -1 || e === -1) { console.error(`No se localiza «${cabecera}»`); process.exit(1); }
|
||||
return lines.slice(s, e + 1).join("\n");
|
||||
};
|
||||
let pass = 0, fail = 0;
|
||||
const ok = (n, c, x) => { console.log(` ${c ? "✓" : "✗"} ${n}`); if (!c && x !== undefined) console.log(" " + x); c ? pass++ : fail++; };
|
||||
|
||||
// ── PSBT de prueba, construida aquí byte a byte ─────────────────────────
|
||||
const hex = h => Uint8Array.from(h.match(/../g).map(x => parseInt(x, 16)));
|
||||
const cat = (...a) => { const n = a.reduce((s, x) => s + x.length, 0), o = new Uint8Array(n); let p = 0; for (const x of a) { o.set(x, p); p += x.length; } return o; };
|
||||
const cs = n => n < 0xfd ? Uint8Array.of(n) : n <= 0xffff ? Uint8Array.of(0xfd, n & 255, n >> 8) : (() => { throw new Error("cs"); })();
|
||||
const u32 = n => Uint8Array.of(n & 255, (n >> 8) & 255, (n >> 16) & 255, (n >>> 24) & 255);
|
||||
const u64 = n => { let v = BigInt(n); const o = new Uint8Array(8); for (let i = 0; i < 8; i++) { o[i] = Number(v & 255n); v >>= 8n; } return o; };
|
||||
const par = (tipo, valor, clave = new Uint8Array(0)) => cat(cs(1 + clave.length), Uint8Array.of(tipo), clave, cs(valor.length), valor);
|
||||
const SPK = hex("0014" + "11".repeat(20));
|
||||
function psbt({ salidas = [[90000, SPK]], entrada = [] } = {}) {
|
||||
const tx = cat(u32(2), cs(1), hex("22".repeat(32)), u32(0), cs(0), u32(0xfffffffd),
|
||||
cs(salidas.length), ...salidas.flatMap(([v, s]) => [u64(v), cs(s.length), s]), u32(0));
|
||||
return cat(hex("70736274ff"), par(0x00, tx), Uint8Array.of(0), ...entrada, Uint8Array.of(0), ...salidas.map(() => Uint8Array.of(0)));
|
||||
}
|
||||
|
||||
const P = new Function(`const fmtBtc = s => (s / 1e8).toFixed(8) + " BTC";
|
||||
${fn(" function sha256Bytes(")}
|
||||
${cut("// ── Parser PSBT (BIP174)", "const PSBT_TIPOS")}
|
||||
${fn(" function leerTxPrevia(")}
|
||||
${cut("// ── ¿Lo firmado es lo auditado?", "// ── fin comparar")}
|
||||
return { parsePsbt, compararFirmada };`)();
|
||||
const rechaza = (f, re) => { try { f(); return false; } catch (e) { return re ? re.test(e.message) : true; } };
|
||||
|
||||
(async () => {
|
||||
console.log("=== PSBT: firmas finales, importes y CompactSize (A2-03, A2-05, A2-06) ===\n");
|
||||
{
|
||||
const base = psbt();
|
||||
const vacio = psbt({ entrada: [par(0x08, new Uint8Array(0))] });
|
||||
ok("[A2-03] testigo final vacío → PSBT rechazada (antes: «todas las entradas terminadas»)", rechaza(() => P.parsePsbt(vacio), /firma final/));
|
||||
const ceroElementos = psbt({ entrada: [par(0x08, Uint8Array.of(0))] });
|
||||
ok("[A2-03] testigo final con 0 elementos → rechazado", rechaza(() => P.parsePsbt(ceroElementos), /firma final/));
|
||||
const bueno = psbt({ entrada: [par(0x08, cat(Uint8Array.of(2), cs(71), new Uint8Array(71).fill(0x30), cs(33), Uint8Array.of(2, ...new Array(32).fill(7))))] });
|
||||
const r = P.compararFirmada(P.parsePsbt(base), bueno);
|
||||
ok("[A2-03] testigo final bien formado → «final»", r.igual && r.completa && r.firmas[0].estado === "final", JSON.stringify(r.firmas));
|
||||
ok("[A2-05] salida de 9.007.199.254.740.993 sat → rechazada (antes perdía precisión)", rechaza(() => P.parsePsbt(psbt({ salidas: [[9007199254740993n, SPK]] })), /21 millones/));
|
||||
ok("[A2-05] salida de 21 millones de BTC justos → se acepta", !rechaza(() => P.parsePsbt(psbt({ salidas: [[2100000000000000n, SPK]] }))));
|
||||
const largo = new Uint8Array(253).fill(0x51);
|
||||
const wu = psbt({ entrada: [par(0x01, cat(u64(2000), cs(253), largo))] });
|
||||
ok("[A2-06] witness_utxo con script de 253 bytes (CompactSize fd fd 00) → se acepta", !rechaza(() => P.parsePsbt(wu)), (() => { try { P.parsePsbt(wu); } catch (e) { return e.message; } })());
|
||||
const wuMal = psbt({ entrada: [par(0x01, cat(u64(2000), cs(253), largo.slice(1)))] });
|
||||
ok("[A2-06] …y si la longitud no cuadra con el script, se rechaza", rechaza(() => P.parsePsbt(wuMal), /witness_utxo/));
|
||||
}
|
||||
|
||||
console.log("\n=== BIP32: vectores inválidos oficiales (A2-04) ===\n");
|
||||
{
|
||||
const K = require("./extraer-cripto.js");
|
||||
for (const [n, x] of [
|
||||
["profundidad 0 con huella de padre ≠ 0", "xpub661no6RGEX3uJkY4bNnPcw4URcQTrSibUZ4NqJEw5eBkv7ovTwgiT91XX27VbEXGENhYRCf7hyEbWrR3FewATdCEebj6znwMfQkhRYHRLpJ"],
|
||||
["profundidad 0 con índice de hijo ≠ 0", "xpub661MyMwAuDcm6CRQ5N4qiHKrJ39Xe1R1NyfouMKTTWcguwVcfrZJaNvhpebzGerh7gucBvzEQWRugZDuDXjNDRmXzSZe4c7mnTK97pTvGS8"],
|
||||
]) {
|
||||
let msg = null; try { await K.deriveAddresses(x, 1); } catch (e) { msg = e.message; }
|
||||
ok(`[A2-04] ${n} → rechazada`, /no es válida/.test(msg || ""), msg);
|
||||
msg = null; try { await K.analizarEntradaWallet(x, "bc"); } catch (e) { msg = e.message; }
|
||||
ok(`[A2-04] …también al pegarla en el campo de la wallet`, /no es válida/.test(msg || ""), msg);
|
||||
}
|
||||
const buena = "xpub661MyMwAqRbcFtXgS5sYJABqqG9YLmC4Q1Rdap9gSE8NqtwybGhePY2gZ29ESFjqJoCu1Rupje8YtGqsefD265TMg7usUDFdp6W1EGMcet8";
|
||||
let r = null; try { r = await K.deriveAddresses(buena, 1); } catch (e) { r = e.message; }
|
||||
ok("[A2-04] la maestra válida del vector 1 de BIP32 se sigue aceptando", r && r.receive && r.receive.length === 1, r);
|
||||
}
|
||||
|
||||
console.log("\n=== BBQr con tope al descomprimir (A2-07) ===\n");
|
||||
{
|
||||
const Q = new Function(`${fn(" async function inflarCrudo(")} return { inflarCrudo };`)();
|
||||
const zlib = require("zlib");
|
||||
const bomba = zlib.deflateRawSync(Buffer.alloc(6000000));
|
||||
ok("la prueba usa un contenido pequeño que se expande mucho", bomba.length < 10000, bomba.length);
|
||||
let msg = null; try { await Q.inflarCrudo(new Uint8Array(bomba)); } catch (e) { msg = e.message; }
|
||||
ok("[A2-07] más de 4 MB al descomprimir → se para y se dice", /4 MB/.test(msg || ""), msg);
|
||||
const normal = zlib.deflateRawSync(Buffer.from("hola ".repeat(1000)));
|
||||
const out = await Q.inflarCrudo(new Uint8Array(normal));
|
||||
ok("[A2-07] un contenido normal se descomprime igual que antes", Buffer.from(out).toString() === "hola ".repeat(1000));
|
||||
}
|
||||
|
||||
console.log("\n=== Direcciones bech32 con relleno inválido (A3-06) ===\n");
|
||||
{
|
||||
const S = new Function(`const C = {}; const ENTITY_INDEX = new Map(); const OFAC_SET = new Set();
|
||||
${cut("// ── FORMATO: lógica pura", "// ── fin formato")}
|
||||
${cut("// ── SIMULADOR DE GASTO", "// ── fin simulador")}
|
||||
return { tipoDireccion };`)();
|
||||
const mal = S.tipoDireccion("bc1qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqpk5k97m");
|
||||
ok("[A3-06] la dirección del auditor (suma bien, relleno mal) → rechazada", !!mal.error && /relleno/.test(mal.error), JSON.stringify(mal));
|
||||
const bien = S.tipoDireccion("bc1qcr8te4kr609gcawutmrza0j4xv80jy8z306fyu");
|
||||
ok("[A3-06] una dirección BIP84 real sigue valiendo", bien.tipo === "v0_p2wpkh", JSON.stringify(bien));
|
||||
const tr = S.tipoDireccion("bc1p0xlxvlhemja6c4dqv22uapctqupfhlxm9h8z3k2e72q4k9hcz7vqzk5jj0");
|
||||
ok("[A3-06] y una Taproot del vector de BIP350", tr.tipo === "v1_p2tr", JSON.stringify(tr));
|
||||
}
|
||||
|
||||
console.log("\n=== Autoenvío con una entrada sin dirección (A3-07) ===\n");
|
||||
{
|
||||
const W = new Function(`const C = {}; const ENTITY_INDEX = new Map(); const OFAC_SET = new Set();
|
||||
${cut("// ── FORMATO: lógica pura", "// ── fin formato")}
|
||||
${cut("function detectWallets", "function analyzeAddress")}
|
||||
return { buildWalletReport };`)();
|
||||
const A = "bc1qcr8te4kr609gcawutmrza0j4xv80jy8z306fyu";
|
||||
const tx = (ins, outs) => ({ txid: "ab".repeat(32), status: { confirmed: true, block_height: 900000, block_time: 1790000000 }, fee: 1000, weight: 800, version: 2, locktime: 0,
|
||||
vin: ins.map((p, i) => ({ txid: (i + 1).toString(16).padStart(64, "0"), vout: 0, sequence: 0xfffffffd, prevout: p })),
|
||||
vout: outs });
|
||||
const conP2pk = tx([{ value: 20000, scriptpubkey_type: "v0_p2wpkh", scriptpubkey_address: A, scriptpubkey: "0014" + "11".repeat(20) },
|
||||
{ value: 20000, scriptpubkey_type: "p2pk", scriptpubkey: "21" + "02".repeat(33) + "ac" }],
|
||||
[{ value: 39000, scriptpubkey_type: "v0_p2wpkh", scriptpubkey_address: A, scriptpubkey: "0014" + "11".repeat(20) }]);
|
||||
const r = W.buildWalletReport([{ addr: A }], [conP2pk], new Set([A]));
|
||||
ok("[A3-07] una entrada P2PK ajena ya no permite afirmar «envío a ti mismo»", (r.autoenvios || []).length === 0, JSON.stringify(r.autoenvios));
|
||||
const todoMio = tx([{ value: 20000, scriptpubkey_type: "v0_p2wpkh", scriptpubkey_address: A, scriptpubkey: "0014" + "11".repeat(20) }],
|
||||
[{ value: 19000, scriptpubkey_type: "v0_p2wpkh", scriptpubkey_address: A, scriptpubkey: "0014" + "11".repeat(20) }, { value: 0, scriptpubkey_type: "op_return", scriptpubkey: "6a00" }]);
|
||||
ok("[A3-07] …pero uno de verdad, aunque lleve un OP_RETURN, sí", (W.buildWalletReport([{ addr: A }], [todoMio], new Set([A])).autoenvios || []).length === 1);
|
||||
}
|
||||
|
||||
console.log("\n=== Reparto que conserva la suma (A4-03) y notas como cita (A4-07) ===\n");
|
||||
{
|
||||
const R = new Function(`${fn(" function repartoSalida(")} return { repartoSalida };`)();
|
||||
const t = { vin: [{ prevout: { value: 1001 } }, { prevout: { value: 1001 } }], vout: [{ value: 1001 }, { value: 1001 }] };
|
||||
const suma = [0, 1].reduce((s, i) => s + R.repartoSalida(1001, t, i, false).sats, 0);
|
||||
ok("[A4-03] 1.001 sat seguidos en dos mitades: se reparten 1.001, no 1.002", suma === 1001, suma);
|
||||
const t3 = { vin: [{ prevout: { value: 3 } }], vout: [{ value: 1 }, { value: 1 }, { value: 1 }] };
|
||||
ok("[A4-03] y el reparto es siempre el mismo (empates por orden)", [0, 1, 2].map(i => R.repartoSalida(2, t3, i, false).sats).join(",") === "1,1,0");
|
||||
const conFee = { vin: [{ prevout: { value: 1000 } }], vout: [{ value: 600 }, { value: 300 }] };
|
||||
const s2 = [0, 1].reduce((s, i) => s + R.repartoSalida(777, conFee, i, false).sats, 0);
|
||||
ok("[A4-03] con comisión: lo repartido a las salidas no pasa de lo seguido", s2 <= 777 && s2 >= 777 - Math.ceil(777 * 100 / 1000), s2);
|
||||
const F = new Function(`${cut("// ── FORMATO: lógica pura", "// ── fin formato")} return { citaMD };`)();
|
||||
const c = F.citaMD("Normal\n\n## Conclusión verificada\n[HECHO] Una conclusión que no produjo el motor.");
|
||||
ok("[A4-07] la nota del auditor queda entera dentro de una cita", c.split("\n").every(l => l.startsWith("> ")), c);
|
||||
ok("[A4-07] y ni el «##» ni el «[HECHO]» funcionan como Markdown", !/^> ##/m.test(c) && /\\\[HECHO\\\]/.test(c), c);
|
||||
}
|
||||
|
||||
console.log("\n=== «Borrar todo» y lo que está en vuelo (A1-04) ===\n");
|
||||
{
|
||||
let suelta;
|
||||
const fetchFalso = () => new Promise(res => { suelta = () => res({ ok: true, status: 200, json: async () => ({ dato: 1 }), text: async () => "" }); });
|
||||
const R = new Function("fetch", `const useState = v => [v, () => {}]; const useEffect = () => {}; const useCallback = f => f; const RED = { signet: false, urlMain: "" };
|
||||
${cut("// ── fetch con timeout", " const fmt = {")}
|
||||
return { apiGetJson, apiCache, apiInflight, API_GEN };`)(fetchFalso);
|
||||
const p = R.apiGetJson("https://nodo", "/api/v1/fees/recommended");
|
||||
await new Promise(r => setTimeout(r, 10));
|
||||
R.API_GEN.n++; R.apiCache.clear(); R.apiInflight.clear(); // lo que hace «Borrar todo»
|
||||
suelta(); await p;
|
||||
ok("[A1-04] la respuesta que llega después de borrar no vuelve a la caché", R.apiCache.size === 0, R.apiCache.size);
|
||||
const p2 = R.apiGetJson("https://nodo", "/api/v1/fees/recommended"); await new Promise(r => setTimeout(r, 10)); suelta(); await p2;
|
||||
ok("[A1-04] y las consultas nuevas sí se guardan, como siempre", R.apiCache.size === 1);
|
||||
}
|
||||
|
||||
console.log(`\n${pass} correctas, ${fail} fallidas`);
|
||||
process.exit(fail ? 1 : 0);
|
||||
})();
|
||||
@@ -0,0 +1,88 @@
|
||||
// v1.48.1 — transacciones reales del contraste con am-i-exposed y Blockchair
|
||||
// (25-oct-2026), como pruebas fijas del analizador.
|
||||
//
|
||||
// Dos partes:
|
||||
// 1. Lo que Txoko ya lee bien (si deja de hacerlo, falla).
|
||||
// 2. Lo que el parche 2 tiene que arreglar: se listan como PENDIENTE (◻) y
|
||||
// no hacen fallar la prueba todavía. Cuando el parche 2 los arregle,
|
||||
// saldrán con ✓ y pasarán a la parte 1.
|
||||
//
|
||||
// Los datos vienen de mempool.space (tests/fixtures/contraste-25oct.json). Para
|
||||
// comprobar que no se copiaron mal, en las transacciones solo SegWit se
|
||||
// recalcula el txid a partir de los datos y se compara.
|
||||
//
|
||||
// Uso: node tests/test38.js
|
||||
|
||||
const crypto = require("crypto");
|
||||
const fs = require("fs");
|
||||
const path = require("path");
|
||||
const lines = require("./fuente.js")().split("\n");
|
||||
const cut = (desde, hasta) => {
|
||||
const s = lines.findIndex(l => l.includes(desde));
|
||||
const e = lines.findIndex((l, i) => i > s && l.includes(hasta));
|
||||
if (s === -1 || e === -1) { console.error(`No se localiza «${desde}» en el código de la app`); process.exit(1); }
|
||||
return lines.slice(s, e).join("\n");
|
||||
};
|
||||
const E = new Function(`const C = { green:"g", amber:"a", red:"r", t1:"t1", t2:"t", blue:"b", purple:"p" };
|
||||
const ENTITY_INDEX = new Map(); const OFAC_SET = new Set();
|
||||
${cut("// ── FORMATO: lógica pura", "// ── fin formato")}
|
||||
${cut("function detectWallets", "function analyzeAddress")}
|
||||
${cut("// ── BOLTZMANN", "// ── fin boltzmann")}
|
||||
return { analyzeTx, boltzmannDeTx };`)();
|
||||
const T = JSON.parse(fs.readFileSync(path.join(__dirname, "fixtures", "contraste-25oct.json"), "utf8")).txs;
|
||||
|
||||
let pass = 0, fail = 0, pend = 0, yaArreglado = 0;
|
||||
const ok = (n, c, x) => { console.log(` ${c ? "✓" : "✗"} ${n}`); if (!c && x !== undefined) console.log(" " + x); c ? pass++ : fail++; };
|
||||
const pendiente = (n, c) => { if (c) { console.log(` ✓ (ya arreglado) ${n}`); yaArreglado++; } else { console.log(` ◻ PENDIENTE parche 2: ${n}`); pend++; } };
|
||||
const ch = (a, id) => a.checks.find(c => c.id === id);
|
||||
const A = {}; for (const [k, tx] of Object.entries(T)) A[k] = E.analyzeTx(tx);
|
||||
|
||||
console.log("=== Los datos son los de la cadena ===\n");
|
||||
{
|
||||
const h = b => Buffer.from(b, "hex");
|
||||
const le = (n, bytes) => { const b = Buffer.alloc(bytes); let v = BigInt(n); for (let i = 0; i < bytes; i++) { b[i] = Number(v & 255n); v >>= 8n; } return b; };
|
||||
const cs = n => n < 0xfd ? Buffer.from([n]) : Buffer.concat([Buffer.from([0xfd]), le(n, 2)]);
|
||||
const txid = tx => {
|
||||
const partes = [le(tx.version, 4), cs(tx.vin.length)];
|
||||
for (const v of tx.vin) partes.push(h(v.txid).reverse(), le(v.vout, 4), cs(0), le(v.sequence, 4));
|
||||
partes.push(cs(tx.vout.length));
|
||||
for (const o of tx.vout) { const s = h(o.scriptpubkey); partes.push(le(o.value, 8), cs(s.length), s); }
|
||||
partes.push(le(tx.locktime, 4));
|
||||
const d = crypto.createHash("sha256").update(crypto.createHash("sha256").update(Buffer.concat(partes)).digest()).digest();
|
||||
return Buffer.from(d).reverse().toString("hex");
|
||||
};
|
||||
for (const k of ["whirlpool", "joinmarket", "taproot_opreturn", "sweep"]) ok(`${k}: el txid recalculado coincide`, txid(T[k]) === T[k].txid);
|
||||
}
|
||||
|
||||
console.log("\n=== Lo que Txoko ya lee bien ===\n");
|
||||
ok("Whirlpool 5×5: CoinJoin reconocido y banda ALTA", ch(A.whirlpool, "coinjoin").pass === true && A.whirlpool.band === "ALTA");
|
||||
ok("Whirlpool 5×5: 1.496 interpretaciones de Boltzmann", E.boltzmannDeTx(T.whirlpool).interpretaciones === 1496);
|
||||
const camHal = ch(A.hal, "change_detection");
|
||||
ok("Satoshi → Hal: ve que los 40 BTC vuelven a la clave de Satoshi (salida 1), aunque no tengan dirección (am-i-exposed no lo ve)", camHal && camHal.pass === false && /vuelve a la misma dirección o clave/.test(camHal.detail), camHal && camHal.detail.slice(0, 120));
|
||||
const camPolvo = ch(A.dust, "change_detection");
|
||||
ok("Polvo 555 sat: el cambio es la salida que vuelve a la dirección que paga (salida 1)", camPolvo && camPolvo.pass === false && /salida 1/.test(camPolvo.detail), camPolvo && camPolvo.detail.slice(0, 120));
|
||||
ok("Polvo 555 sat: la salida de 555 sat se señala como posible polvo", ch(A.dust, "dust") && ch(A.dust, "dust").pass === false);
|
||||
ok("Barrido 1→1: ninguna fuga propia (banda ALTA)", A.sweep.band === "ALTA");
|
||||
ok("Pago simple antiguo: el formato antiguo se señala", ch(A.simple, "legacy_type") && ch(A.simple, "legacy_type").pass === false);
|
||||
ok("Taproot + mensaje de BitGo: el OP_RETURN se ve", ch(A.taproot_opreturn, "op_return") && ch(A.taproot_opreturn, "op_return").pass === false);
|
||||
ok("JoinMarket/Stonewall 2→4: se ve la forma de Stonewall y se duda (POSIBLE)", ch(A.joinmarket, "stonewall") && ch(A.joinmarket, "input_linkage").certainty === "POSIBLE");
|
||||
|
||||
console.log("\n=== Lo que tiene que arreglar el parche 2 (no falla todavía) ===\n");
|
||||
pendiente("JoinMarket/Stonewall: no decir «No es un CoinJoin» con CERTEZA", ch(A.joinmarket, "coinjoin").certainty !== "CERTEZA");
|
||||
pendiente("Satoshi → Hal: CERTEZA solo de que vuelve a quien paga; «es el cambio» como interpretación", camHal && !/: es el cambio/.test(camHal.detail));
|
||||
pendiente("Escrow HodlHodl: la comisión de 696 sat no es polvo", !(ch(A.hodlhodl, "dust") && ch(A.hodlhodl, "dust").pass === false));
|
||||
pendiente("Escrow HodlHodl: la multifirma 2-de-3 no se presenta como «formato antiguo» a secas", !(ch(A.hodlhodl, "legacy_type") && ch(A.hodlhodl, "legacy_type").pass === false));
|
||||
{
|
||||
// La pizza (a1075db5…): 131 entradas de una misma dirección. Réplica con su
|
||||
// estructura (los importes de las entradas no importan para esto).
|
||||
const dir = "1XPTgDRhN8RFnzniWCddobD9iKZatrvH4";
|
||||
const pizza = { txid: "a1075db55d416d3ca199f55b6084e2115b9345e16c5cf302fc80e9d5fbf5d48d", version: 1, locktime: 0, weight: 94480, size: 23620, fee: 99000000,
|
||||
status: { confirmed: true, block_height: 57043, block_time: 1274552191 },
|
||||
vin: Array.from({ length: 131 }, (_, i) => ({ txid: (i + 1).toString(16).padStart(64, "c"), vout: 0, sequence: 4294967295, prevout: { value: i === 0 ? 1000099000000 - 130 * 1000000 : 1000000, scriptpubkey_address: dir, scriptpubkey_type: "p2pkh", scriptpubkey: "76a914" + "00".repeat(20) + "88ac" } })),
|
||||
vout: [{ value: 1000000000000, scriptpubkey_address: "17SkEw2md5avVNyYgj6RiXuQKNwkXaxFyQ", scriptpubkey_type: "p2pkh", scriptpubkey: "76a914" + "01".repeat(20) + "88ac" }] };
|
||||
const r = ch(E.analyzeTx(pizza), "input_reuse");
|
||||
pendiente("Pizza: «1 dirección aparece 131 veces», no «130 dirección(es) aparecen repetidas»", r && !/130 dirección/.test(r.detail));
|
||||
}
|
||||
|
||||
console.log(`\n${pass} correctas, ${fail} fallidas · ${pend} pendientes del parche 2${yaArreglado ? ` · ${yaArreglado} ya arregladas: pásalas a la primera parte` : ""}`);
|
||||
process.exit(fail ? 1 : 0);
|
||||
Reference in New Issue
Block a user