2018-06-05 09:24:47 +02:00
|
|
|
{
|
|
|
|
"valid": [
|
|
|
|
{
|
|
|
|
"description": "output from address",
|
|
|
|
"arguments": {
|
|
|
|
"address": "bc1qafk4yhqvj4wep57m62dgrmutldusqde8adh20d"
|
|
|
|
},
|
|
|
|
"expected": {
|
|
|
|
"hash": "ea6d525c0c955d90d3dbd29a81ef8bfb79003727",
|
|
|
|
"output": "OP_0 ea6d525c0c955d90d3dbd29a81ef8bfb79003727",
|
|
|
|
"signature": null,
|
|
|
|
"input": null,
|
|
|
|
"witness": null
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"description": "output from hash",
|
|
|
|
"arguments": {
|
|
|
|
"hash": "ea6d525c0c955d90d3dbd29a81ef8bfb79003727"
|
|
|
|
},
|
|
|
|
"expected": {
|
|
|
|
"address": "bc1qafk4yhqvj4wep57m62dgrmutldusqde8adh20d",
|
|
|
|
"output": "OP_0 ea6d525c0c955d90d3dbd29a81ef8bfb79003727",
|
|
|
|
"signature": null,
|
|
|
|
"input": null,
|
|
|
|
"witness": null
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"description": "output from output",
|
|
|
|
"arguments": {
|
|
|
|
"output": "OP_0 ea6d525c0c955d90d3dbd29a81ef8bfb79003727"
|
|
|
|
},
|
|
|
|
"expected": {
|
|
|
|
"address": "bc1qafk4yhqvj4wep57m62dgrmutldusqde8adh20d",
|
|
|
|
"hash": "ea6d525c0c955d90d3dbd29a81ef8bfb79003727",
|
|
|
|
"signature": null,
|
|
|
|
"input": null,
|
|
|
|
"witness": null
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"description": "output from pubkey",
|
|
|
|
"arguments": {
|
|
|
|
"pubkey": "030000000000000000000000000000000000000000000000000000000000000001"
|
|
|
|
},
|
|
|
|
"expected": {
|
|
|
|
"address": "bc1qz69ej270c3q9qvgt822t6pm3zdksk2x35j2jlm",
|
|
|
|
"hash": "168b992bcfc44050310b3a94bd0771136d0b28d1",
|
|
|
|
"output": "OP_0 168b992bcfc44050310b3a94bd0771136d0b28d1",
|
|
|
|
"signature": null,
|
|
|
|
"input": null,
|
|
|
|
"witness": null
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"description": "witness/output from pubkey/signature",
|
|
|
|
"arguments": {
|
|
|
|
"pubkey": "030000000000000000000000000000000000000000000000000000000000000001",
|
|
|
|
"signature": "300602010002010001"
|
|
|
|
},
|
|
|
|
"expected": {
|
|
|
|
"address": "bc1qz69ej270c3q9qvgt822t6pm3zdksk2x35j2jlm",
|
|
|
|
"hash": "168b992bcfc44050310b3a94bd0771136d0b28d1",
|
|
|
|
"output": "OP_0 168b992bcfc44050310b3a94bd0771136d0b28d1",
|
|
|
|
"input": "",
|
|
|
|
"witness": [
|
|
|
|
"300602010002010001",
|
|
|
|
"030000000000000000000000000000000000000000000000000000000000000001"
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"description": "witness/output from witness",
|
|
|
|
"arguments": {
|
|
|
|
"witness": [
|
|
|
|
"300602010002010001",
|
|
|
|
"030000000000000000000000000000000000000000000000000000000000000001"
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"expected": {
|
|
|
|
"address": "bc1qz69ej270c3q9qvgt822t6pm3zdksk2x35j2jlm",
|
|
|
|
"hash": "168b992bcfc44050310b3a94bd0771136d0b28d1",
|
|
|
|
"output": "OP_0 168b992bcfc44050310b3a94bd0771136d0b28d1",
|
|
|
|
"pubkey": "030000000000000000000000000000000000000000000000000000000000000001",
|
|
|
|
"signature": "300602010002010001",
|
|
|
|
"input": ""
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"invalid": [
|
|
|
|
{
|
|
|
|
"exception": "Not enough data",
|
|
|
|
"arguments": {}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"exception": "Not enough data",
|
|
|
|
"arguments": {
|
|
|
|
"signature": "300602010002010001"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"exception": "Output is invalid",
|
|
|
|
"description": "Unexpected OP",
|
|
|
|
"arguments": {
|
|
|
|
"output": "OP_RESERVED ea6d525c0c955d90d3dbd29a81ef8bfb79003727"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"exception": "Pubkey mismatch",
|
|
|
|
"arguments": {
|
|
|
|
"pubkey": "030000000000000000000000000000000000000000000000000000000000000001",
|
|
|
|
"witness": [
|
|
|
|
"300602010002010001",
|
|
|
|
"030000000000000000000000000000000000000000000000000000000000000002"
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
2018-07-14 12:24:11 +02:00
|
|
|
{
|
|
|
|
"exception": "Invalid prefix or Network mismatch",
|
|
|
|
"arguments": {
|
2018-07-17 07:22:03 +02:00
|
|
|
"address": "foo1qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqs30dvv"
|
2018-07-14 12:24:11 +02:00
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"exception": "Invalid address version",
|
|
|
|
"arguments": {
|
2018-07-17 07:22:03 +02:00
|
|
|
"address": "bc1pqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq5us4ke"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"exception": "Invalid address data",
|
|
|
|
"arguments": {
|
|
|
|
"address": "bc1qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqmql8k8"
|
2018-07-14 12:24:11 +02:00
|
|
|
}
|
|
|
|
},
|
2018-06-05 09:24:47 +02:00
|
|
|
{
|
|
|
|
"exception": "Hash mismatch",
|
|
|
|
"arguments": {
|
|
|
|
"pubkey": "030000000000000000000000000000000000000000000000000000000000000001",
|
|
|
|
"hash": "ffffffffffffffffffffffffffffffffffffffff"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"exception": "Hash mismatch",
|
|
|
|
"arguments": {
|
|
|
|
"address": "bc1qafk4yhqvj4wep57m62dgrmutldusqde8adh20d",
|
|
|
|
"hash": "ffffffffffffffffffffffffffffffffffffffff"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"exception": "Hash mismatch",
|
|
|
|
"arguments": {
|
|
|
|
"output": "OP_0 ea6d525c0c955d90d3dbd29a81ef8bfb79003727",
|
|
|
|
"hash": "ffffffffffffffffffffffffffffffffffffffff"
|
|
|
|
}
|
|
|
|
},
|
2018-07-14 12:24:11 +02:00
|
|
|
{
|
|
|
|
"exception": "Hash mismatch",
|
|
|
|
"arguments": {
|
|
|
|
"hash": "ffffffffffffffffffffffffffffffffffffffff",
|
|
|
|
"pubkey": "030000000000000000000000000000000000000000000000000000000000000001"
|
|
|
|
}
|
|
|
|
},
|
2018-06-05 09:24:47 +02:00
|
|
|
{
|
|
|
|
"exception": "Hash mismatch",
|
|
|
|
"arguments": {
|
|
|
|
"hash": "ffffffffffffffffffffffffffffffffffffffff",
|
|
|
|
"witness": [
|
|
|
|
"300602010002010001",
|
|
|
|
"030000000000000000000000000000000000000000000000000000000000000001"
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
2018-07-14 12:13:50 +02:00
|
|
|
"exception": "Witness is invalid",
|
|
|
|
"arguments": {
|
|
|
|
"witness": []
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"exception": "Witness has invalid signature",
|
2018-06-05 09:24:47 +02:00
|
|
|
"arguments": {
|
|
|
|
"witness": [
|
|
|
|
"ffffffffffffffffff",
|
|
|
|
"030000000000000000000000000000000000000000000000000000000000000001"
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
2018-07-14 12:13:50 +02:00
|
|
|
"exception": "Witness has invalid pubkey",
|
2018-06-05 09:24:47 +02:00
|
|
|
"arguments": {
|
|
|
|
"witness": [
|
|
|
|
"300602010002010001",
|
|
|
|
"ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"
|
|
|
|
]
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"dynamic": {
|
|
|
|
"depends": {
|
|
|
|
"address": [ "address", "output", "hash", "pubkey", "witness" ],
|
|
|
|
"hash": [ "address", "output", "hash", "pubkey", "witness" ],
|
|
|
|
"output": [ "address", "output", "hash", "pubkey", "witness" ],
|
|
|
|
"pubkey": [ "witness" ],
|
|
|
|
"signature": [ "witness" ],
|
|
|
|
"input": [ "witness" ],
|
|
|
|
"witness": [ [ "pubkey", "signature" ] ]
|
|
|
|
},
|
|
|
|
"details": [
|
|
|
|
{
|
|
|
|
"description": "p2wpkh",
|
|
|
|
"address": "bc1qz69ej270c3q9qvgt822t6pm3zdksk2x35j2jlm",
|
|
|
|
"hash": "168b992bcfc44050310b3a94bd0771136d0b28d1",
|
|
|
|
"output": "OP_0 168b992bcfc44050310b3a94bd0771136d0b28d1",
|
|
|
|
"pubkey": "030000000000000000000000000000000000000000000000000000000000000001",
|
|
|
|
"signature": "300602010002010001",
|
|
|
|
"input": "",
|
|
|
|
"witness": [
|
|
|
|
"300602010002010001",
|
|
|
|
"030000000000000000000000000000000000000000000000000000000000000001"
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
}
|