Adapt existing functional tests to CA

This commit is contained in:
Steven Roose 2019-03-20 11:22:45 +00:00
parent 6113bf89cf
commit 39020cdc7b
No known key found for this signature in database
GPG key ID: 7FC91380BB4CE800
53 changed files with 887 additions and 514 deletions

View file

@ -1,117 +1,117 @@
{
"blocks": [
"0100000000000000000000000000000000000000000000000000000000000000000000007598567fa9cac9236823eb32b293121c11b51e39e14c35fb7114840d9883d23bdae5494d00000000015100010100000000010000000000000000000000000000000000000000000000000000000000000000ffffffff212000c7ac6641f4d9f883879df37385a9998553114d01c2c8e47608581773d7db37ffffffff010000000000000000016a00000000",
"0000002066d931a80634d0faa37b4cbb8a02f205677bb1ca3ba9a7cc52aa35e7ba15b8fe406dbfcd6f199cbde669d09fc693c9bfa16e4dd1328a2af3d5e56a9ed778c8091194485c01000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03510101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020e1ef218614ed1c754db1ebfd03ba09a02b98e1da25a51c92fb7549b11b8d7f6730dc3ca7036a1b897e3363e9e60afb5c7f0d0cb0541e108456c0c13221ac567f1294485c02000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03520101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000206f89bd6fdabdee0b88214ec4c88c0ee67af61e1e0a19f98c1b152d06cff10880a55f1f7d55d836e89be3562aa82f04ece8beb56b068c9d15569336c47f44ddc51294485c03000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03530101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020ac82a0e1088a94229f736534f2b6742e0f956bfed021f11a80c2804acafe53270756391af8f25cc9d9421647fe44ec6bb259505e8308890b35e6b0fab8d272291394485c04000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03540101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020ec145895e6b8eb9f09f8d2092341e41f8b242ea1886f9f19647aeab12eaa43f65dbaa591d1fea2f722f758c7b227a40f44049a9603d5f9691716b179b2d62e1f1394485c05000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03550101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000208cb70e5924d7d4ab2b17d59bc40457b5437988af0d89d6965a377b0b90f28337bd0ad9b5a44141e2afaa94df473b264aca483dc41328f206dc88336be18fddf11394485c06000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03560101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000206c37cf4f672674df3e44338d8d65c0a81b49c8e760f950bef5bc495f4441a8f1f6ed5658305e579bd629e7e8ad582c028444aaaa1807588c8b1d485a40d59c591394485c07000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03570101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002068b268edf1bd7faf7d22471519023cb8b4948e4974b20cab6bde9d943dbe9b98b5bd331d8c1817e329f8610c9b9dfff5ef797ba4846f65f70a69d13cd9d886a01494485c08000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03580101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000208e58d5fd78e06af9785faa1688cb37554d7853e5587dc8dfd89e5682429a8c0fe38196eb52284e4a469f66f8ff0f2bb1d2d0bcf427d360d664d63b4160ab98121494485c09000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03590101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020c4c3e11a9c2e87f28adc1efb671ce10cfb1ad8568401e8b70ad137cae0b0ce6c4ec6fbd4262409af7f35e749b6b60ef4f4667a204eac56b599fb56ab46a1c1981494485c0a000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff035a0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020567680d46a94b563266ab59233a54c212981764bd48361463b59ebac1bbd9852986399ed6b74d59e090eddfca832982b53aeafe8446d1dfa50564995fdc57d9b1494485c0b000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff035b0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020d22320cfa272faa61637f3f710b56ac02c93e8ca7cbe3c66f3a35fe2f814a7674fe5db02251a552e8eebf6dd5a7aa87783c90f5f7245d095dfeaadca18910ad01494485c0c000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff035c0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020c2306ba70c5a8b35513f6f3d5927e7a025d901f6e21bb8ecdbdd55caf9750cc06ba2cf26811d9474d81c46d4960d81d5ed2921d902ec6edce703a70735975d981494485c0d000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff035d0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020bb5111dcf92969e8ab1b49905696cbb0a794eebf5d14185a76e1e3798aa4410eeee7e285a9f51697b426358f387ea8fc793fde3fd3e2b7555733fa89b0a0634a1594485c0e000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff035e0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000209017c1e6a52bdc1a28aea391e53150ad2d3ac21a126608ffefcd508f462751858a17a5bbfaba9bb802b2ee313b6d0386660a681825c0e71699966126d2a2e39d1594485c0f000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff035f0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002007f2cb80ace987e15d4892166f137112288e844eebc018b84a9125a7401842f3ac8ce0aefeffea4f60559731a4e083b400b25878e303299218553517725bff9f1594485c10000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03600101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020b5b80518a6e768d027130a0f2b54cd853856d161c465362c9c60ff737119aaba818bb93f1f00b31c26c44bcd3f55a170f367e10a8f779ce25826fd3bc309d59b1594485c11000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401110101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002082e8dc946cf72bec61b933d5cf1eca879989ffa3c2224969892db3f7203a4c3138f278135cdafeb9cf93013b5c88f47df9dc9029a3a0026b5629966b4745246e1594485c12000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401120101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020b75376b259b8a0e3a6a5dacd6889531d8fcb7dd2594bbdf33e05951e9e5154a484c8129703dd8bce26207fe95b415fda811639e223cd1d0e235104c3dc7483211594485c13000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401130101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000206105dfa6504ca3efcd9d995f5880d7b33bb74e8f5bedb005a312f84fc2ff37e2ebf7f6b1221d0a58fb8a88b7b62c7757802ac0dfe4c929f02bb08c85eac71c401694485c14000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401140101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002040c6037d1d5e63dbdb1894aad148f68cb317375058bf0bd4399071f62bcaa13518e389c4e88004d92294b18dcd78323398ca862e1c221e4f6977bb4ee20b888a1694485c15000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401150101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020381f204215b8163868074585ee3334275c61674130be4bcfa0a752c3fd4fc8c359cc1f49f5ca20c64a93a2900ffb3f2a2f4e50b2a8680e545c04c85beec467d91694485c16000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401160101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000202bc5e2b05f4e46aae3010f175bb4873647a4468e9323cd8348fadac43cbda2de5ef148efbf7e4c9c984688aee720cbd2468c67c099543288462d9f794fc1a6961694485c17000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401170101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000200cbd694b4f469d67e428881d5734a62d1b5de761682ec070d590ece1ea4786c321d4c2afd1b036b19a148742f97759f800f924ddba7b2621a319d963835fe0611694485c18000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401180101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000209f8cdf1b1eb3cb7c2927ccd97a47cc798fd69d050be0624e3e092eca828315601b0dd077a09a8c603c5b0af4b7c5927dabc281b104ac14a795828aa2277338f51694485c19000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401190101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020075928cae94535cc70fb8f8008b51113ffda0bdcc99ea1525bb77396a7e72dc1c070d8e57f6517697ce447589ae83d9d8b81ad0e17c1e70b86af889cd1f3f4fc1794485c1a000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04011a0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002060dd6dac54c2688e53124bbef30accb7665e080aa6f144cc9be9430385de77c76300b9151ef45a73671852fb6bc9f3394bc2805959a07318b52256aae1f0cb091794485c1b000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04011b0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002077ec9d71f61286f0a53b5175c0405a413c4c51ca0a62aab6b93cee6148fb8fca8eec7884ee73bdd519dc329b3f9f07bd392e97c439376a37ddc5492afe9367c51794485c1c000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04011c0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000201f3bea06f93b9491197fde6a37c059fb829aac2f4a5c98d57b4c177500cac51f02f100035d48eee4cdc05cc0a443270c874cff599a021e2d7ab34419dd8cc91f1794485c1d000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04011d0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002003ef1998abc89439eb094618c521cde00153dff220c80e6c6d6195e5d17f172f25dbc6a4098a842dc1338cd5f461304a134e236dc3d3ecffbea509d027bb661b1794485c1e000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04011e0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020a6a5e46e17384b4d41f1f4c549df3cb035bc7bac05df01f1d5179fae76582aded2e79cf61b93f3788b5b54050201b68b6ff35afa21205eb5342af05d720bc3d11794485c1f000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04011f0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020afe9b51f2e0f079639bbd5dbec7208bfcc236107c03aa51b6f357a730e8bafd0358d77e708080c9af7543fecd791bd77d0f26ca403df0a76ccf1d31e6c9f73c71894485c20000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401200101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020975f224cbd66e11d99e8eb21c545592bc620be18ff28b04e9dbd12010e16198e9898f5d8be2b25bbca000ba12bf1fd64699f452941ca05037a98642a967d2ca51894485c21000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401210101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000207e349f5b00946744ced973a5a03021ca934763f09716fab04cd7297fd6ccf3433dda375ba4376d214bc8f7008a3cc7d0c71dbf1569b098f2f3cf83558b89b05d1894485c22000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401220101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000205a249f8b4fba9b3a2a1d32a7bfbed8345ce25e9407f74cf1e6d363b6d8979bff44a6610ddf01669b04174df2262b700489006c21ff2310e95ab763492384bb411894485c23000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401230101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000201ab3897da0ea266fdd6227e5f481a49260fc73187f2bcb8549d77c11572a45ed4d5af81abcef369dd26df0c3a715df275ce7d9db28b801dd3fabfa79773cb33e1894485c24000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401240101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000203e533d81eba3851e8993514889b216f6eb07a27b5321eaf59db6ef80081100b852a0ce8f0c5318a661d0fa0063d9646fc3270d40f497f97ca5fb62845a3244251894485c25000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401250101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020038dfd54be3feffba12f4a4b8135c1a89f92ac641bb991c3c8327674458e4bd0d6d78bed0c6222652cdc19fcd860e407e8760e2ccd718299d392cb16b037c7e31994485c26000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401260101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002078647f4feedc4a0b2ef759d83f4d05a2fbb931550bfaadb5e87723ebce582eb21c51755259cb5849f7094617702fe2be87d636322a95c1506278359ced4ab9b51994485c27000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401270101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020285a03442ee19f7fbcde632b1cac616958ed743f83e4ea0bd097ebbe84fa506c1edb45fc35ac0ca66285f89400927ab2cef1609a547babd17af669a5bd44a52f1994485c28000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401280101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020722f73cf91ac7748a793e0ac5989d9826b0bdfb157c0ab02e3906c002cdead61025a5bb3b576e4acbe13ef778bf0c805beaeff9de0ce7a67935f4be7ff073e411994485c29000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401290101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020b22dc34ad29fc2050ebe1ad587abf056a09d7d76ab84af5501b3afef18e601ff523646d2754f5b4157b04814b815cfdc0045d67abe16e2ce6d841518f7d675801994485c2a000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04012a0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002051904b6439acb096794c9f9729066b0a9353d32b13d02d4072308b0a149572be0b9a943939843b8fd7a8747937a1eb628bc84168bc70d1f9566700a5c6a90ca61994485c2b000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04012b0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020f8010e22f4fec6c21bc5fe08d6e7cdd2a7f8e6e8586e150e21f740d55f58c21c75204a06f18631273980aef5bfee39c0c72b5d6122a4f87161a276f93707371e1a94485c2c000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04012c0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000208ad30b06401edc96a6fcf4461059386ea53b8c8243e258ec31b42e2170eb1b5e08bd5b23980db05061170163dfa68d611e84cf212a69dfc2bac89894092fb5f01a94485c2d000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04012d0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020abe780b5f4e2b7819fab1bc1e29bd2682049890b809480a85c2734cb070f31901b8b5d14c71cb5dc9689563bbdeb506dc01c5e04b43060e097391e03a05c4d251a94485c2e000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04012e0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000209b9a96818c3274ac923400711639056373155fdf2dcd45eb559b4a5b9e3aa50ccbcdf9c2ef2d812079bccd147c3eb406d2c57e1139f2dabec44c80078d82be861a94485c2f000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04012f0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002051243db1bfe9321f7d474b61abd0a0fe8ff601d4d7fedb037c18ea0926e556da339eaeb0776a22b8aa91de95b32f08f1f630f2ccf969d11bfdae055cf80929d81a94485c30000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401300101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020f455d1b01454b2b1e9ccbce18f1a0fe0a9c3dc36dcb437ca2af2d636465228014c2fd897df770175f1bbb30f5875d52341c26d971a28742488371e53b450b2761a94485c31000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401310101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020aaf15d370dceafd10320c629db9e3510672ea7e552d8fb7f596439da210e177c15bf85c0de2eeb0eac3ba5a22daa7bc4872f58a6e9b24aa87a0be1403a800a4a1b94485c32000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401320101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000202064af4b2a01947e6c5f60301f50cea1e911a9f4c7efc33b6d40b3ba5bb955871c4d4f7e4be7112399d2026632b99ee96e1b320f6f6341020f1a5c45358eca611b94485c33000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401330101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002096547d2e54e556c3bb3e60bc8292a2fa71f88ca037dce0cea6400412ba02e13a8724df616628435f026cf80b2b60cf8c4e5cbf0d91fdd9b353376a24f052e84d1b94485c34000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401340101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000204484e29eade1230005694cd5e42f2241d6c908a2c9320436b4b375e769faf3115375dfd165ba20c7f44be9a64fe4c88c6a75992567973bbc50ede5f5778ea1c71b94485c35000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401350101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002066b781a861448e1f5530a7183610340a89e73f09e44acbde6d75d511c512145cd89deddaecfe6a5906aa4ccd5ed87e8c8afe3c136966e403b94a1edee0d3886a1b94485c36000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401360101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020561e9ae40ad375ab6250f1511503d7793ad8713f6627d8637e9e3f8e3bbfb671161c266a79a4ac0f73ce72e693a7a7ebfb43e1db61026aeaa56f7ae956f508a61b94485c37000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401370101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020d520466bcc57031c5a5668dbde0331e892e88214ce9c87a534bf6afb1db9c2c9ae1b96a2143a1748c034d5e6db2cb04d2fb58720cdc120a6f6f801472f5745521c94485c38000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401380101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000209ea17e59179d6a0210901e381b5b53209a8d5ee8523ce03031804b7f52df682316ff97f5e27c866ba18f912de54ade046f73385982de9a7af7b626c109e4ef281c94485c39000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401390101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020d08bcc1f2cb409803a5819dc95e415afd37adb0902ced2cf713585de31009aec4eddb0ee7650081d28e774c42b49d3468d2bc6b38579b4f44da580b124e1e2381c94485c3a000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04013a0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020331c7f4dae2206c47e68bf14b49eaf95d6436b90b66aba37394df72aaa28b05a815064858c2b9dc80f669deeefb79d25abc6ec6224ed67b2704f8611c9d526fd1c94485c3b000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04013b0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020bf3c1626a3c70345124b9ce1b0c269216788dfeabaa0346831a405645bc8cbe00b9c98a421479ae9a06c6da1b4339838b6998ae7a87053a61c9b0bda3e3707f11c94485c3c000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04013c0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000204b1cfbc2f7f1b206d76ce233ee2d97cb8bff35d2c66b0170734748444f7ef8caebed3d60cc21fef288ab6376bf30091d1eb1761fb6a22fd8c5db1d3ffd5be6e61c94485c3d000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04013d0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020dd893834f13d6b922b05c764a1146fba095ac521e97e3ad8accca31de12431e828ceeff16aabf29080e3198043ac9bfd166b324fd02f123cc1858dae6a53c0e51d94485c3e000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04013e0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002068f0624d88bff3322a84de1ce434de3ae053f1d453df0ab9d043f920e0130b5a2d69f02fb14d31e9bf7274c8d008a45ff7d465b221a65c7609c4a2970895c4901d94485c3f000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04013f0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020f52b91661ccd0e534dd2288dbc2344e15c871a64a757a050ca9cf4e38f9cad2215c4d67b92d64130918f8b075e82ac55ba5a7c23e7a742c5a197e013391c34291d94485c40000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401400101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000203bdbde3de1cecbeee84a1cfa873f735ae624efaa703472bc9da219b458769d01bdbfe3bb853322fe5126817ec7b3866d86da94104b2bf9a198fb952a5cace4691d94485c41000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401410101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002064b8ef38cc37bb7ea4fbccb0c805efba66b9cb069ec59219d10abba7dd2cdbcf4a6241542321faa75b5819888faff7bd55b2c6fb933a6045ec97560c05d453891d94485c42000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401420101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020b9cc62a3b91bec65f1270b43b2a628ac5e58a27cc66f4f9f201eb514d084492b1ca0c811d00fb7bb07b6d0cdf20d95a63868be34b02948d2bab2b8c24af664b21d94485c43000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401430101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020f6fc241741200209aee295ac02fc28534c0c859baf01a9a8a6edabf5a7da47e7721ebb23e72e3c0caec8eba8a50d9962a32eebf1f6f2822ad1cf97abb876f57b1e94485c44000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401440101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002081fd3ec936e08cc76bd4e9bdbb76d2b572d0da2f1c4aa56d8745a0e1c671a74a9872323259654bcbecaf03d659594b05ada5aa270caf0e8611db8b3bf74dfdd41e94485c45000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401450101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020f6e319ebf9d622aa6803edda3f855658118410098a2adeffe33d135a2e260552525d4e6fb86d02aec0d6a0b0d99cd6b7a556e4aeca317f84567a41c3f532017c1e94485c46000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401460101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020a8a5489b4f0d5cec7c457079b41adbc0df68f4d5f3d1e21e8090b1afb0ad097d656204f99599b93b91654100ef5023c7e3bead10fe853158418d15826142d4be1e94485c47000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401470101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020595552d02db74e4b8426aaf00da1804f28532e25f353b71778f565a4288b802761d973b668db6107f8e375ad0cc696f2aa301d17d5df8c72acdfabd09e3425c11e94485c48000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401480101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000208a7eb98cdadc6b294105b27abe6ee617951fd89c2d1ac2610130e79de75cfb3fcf8c7daf6ac82f12e4085ba1d6a4e4bb37987a19aeb955cd1d3ca52e5cb94fcb1e94485c49000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401490101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000200a25f2f5137da2ef048e11211278a64c63554bf791250d9bfe85ba9d2d269833d0cec20593f73178d7ada10e5d39d2c354e604a1564e1fbd44fbbbb8730e33c51f94485c4a000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04014a0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002045fe5aa1b1ad10a8a102530b46c622a8ad0928231c51aebd855f311c8d0b1e22afd4f46f62189477bc4c363a3b8ddea763bcd03bce17c675a0a8233238172ed31f94485c4b000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04014b0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020b793ef685f3ceb67158e44e01bcac490699c57bdf90cf7a82e8f23d7150eb850d8caf96ab291f7aface4cf3d326e3a26869ae332aabf29268ff2caec3179d8641f94485c4c000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04014c0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000208a87cd963e394675944a818df597d9248bebbd37cbe5ebd2ffc7622f3f7715b9028955f4d9cba51b3f20e5a57d5cba5d293caee2c22f39d2896babf408a6a1ec1f94485c4d000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04014d0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020152005678b0eb36f0cd76b9391bfe85cc8bc9608e8def41a72ea866c9c4d50678d4b2c8a206131aa133a52d4f79b2d215cd69d2c9afb17c83f7cbe3bc4862b3e1f94485c4e000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04014e0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002019e42ece448b7afd3a2d069a891559458d1c4666471a000bf08d55aea9e5a52804d35048f814d3c9c91fd2d4264014aa6a2a0db00e90c1370b5020abb0e3ab741f94485c4f000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04014f0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020efb6ef3df6c2ed7a79af393f133ddf83fdca0f303534f5a2c5c2be63e78b9c91522eb4d5122c66a0361bc65c64984fd3ff4aa8c2ca110eb21e0d855086e663fe2094485c50000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401500101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020801d05baeb47244ad678486a5804023e6a8302c13cb990d07d360db02acf04565f64098dee95479f014f9360d413d33c70c948923b189997b65f2b19a610e2392094485c51000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401510101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000203ee3a4e811c091ed982ebe117f9f960c0d29d697d8ed39c3b9e892bf70afca040d6bac48fdc5612e6a9cead9ce44bfbf554202001c233725bb9b9fbfd5b430d02094485c52000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401520101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020151b1756313d52efaa33bbbf5e013e61cbaee2200218d50558d3d6caa0c134e8de3a05820dabdc5ca501912a4640906f2198bb57f861be251a029f5982a7343c2094485c53000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401530101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000200e4c027b78103e4d7971c29ad0307dddbc14915f7f598d994fa47976ac2fa3f384c2b92e06bb9b58a4e7b04ca44ee544520044deca1829948348b225681048772094485c54000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401540101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020c95daea532659cce0496acb55667999422d8ec897be94af348c6adffe29bd2245e722a00b1bc737dda2e95b87dc175f57049c2b6246e72d0d6ef252eb2cce0442094485c55000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401550101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020995795830a41eb30efdc77db361f2092ca7cd222a148bfdeb823685df8395ac08284787496520322540b18aeb78ca8703f56b7e1dbd9396fd65ce53049da6c272194485c56000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401560101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002030646eaaf9046a65a3b67b2bfeb2807f705110ed87a67c2769dc598b471128948a797a9383f9babe23211276dd4800d1faa0bc2022a2b53c7473585c474d5f1a2194485c57000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401570101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000200de4b037c047be1b61ccf195d096029ef6144dc1e74393c9e55d69d19bfdda1340db8f52cada76a84298d7b773484b8b7d7d0a053a18e1473855fcc879db25a32194485c58000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401580101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020656f984b4c383918e106c9bc3138a29fe00be7a6524b62d60bef87d47775619b5e1c16c9adfd79af6376ab0447e8a40572053b8e4e85bcbfffae5f8fa1b6678f2194485c59000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401590101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020b92c503dcb34abed28efcd1a7db5d944d6293cc8bf22a7065c1d1a06741802d772b7b1c28ca485a1ab77af9d496262d3240e720053d4137d7b897c144586fd5b2194485c5a000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04015a0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020536a377271d6f0843351bc8e14240be8ad03553a77f0aff4e5d32d7f76f3ae146607eb28b814aa80b972103414968acf4a7aee777b902b186e632de1be44ae7c2194485c5b000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04015b0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002071f30960a35b079d0b462090c4eb97fe21a5d29996cc16188861fbf52af96ac203ce45f1530d6512068fe40be43e9947bea93dcf20e3b58d57fe4efcd04b50b22294485c5c000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04015c0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020f4822749c9cf3165f2dfd4dc4018908d8d3a17046882db6c19c8fdbc25149dd1ebc1eed7218a663962cb905a7a54b9137faa95a5af817bd1a566f4cba99f3ee52294485c5d000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04015d0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000203eb887bb4f16f7194703f2cf4992ee9c80b33dda6282525731233215338ee2f1935ac11a2b054239c3b42b25413b6fa2111b829024704e629667abe5f67b6cce2294485c5e000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04015e0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000208003731ee2fa4db8acc9f9a2e436ddfbfdc478ab79297f706c373b8202e2aa4658431246a2fd79c733db727a03585bbb93ab83e24c4353ac94376c02764bdb2d2294485c5f000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04015f0101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002085ef1e4040640e90f32048629697188c48f17d028f511d7e5f569830348de1ca44eb73bcd2f14e778a53b7039f1e7deda8741cded0755e2ca9a2baab283a931b2294485c60000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401600101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"0000002086b95a5f98dfc9c584af9fe4d41b3e290a89b0751faf1172555e3400fdb08165e401b34e64b43819794ff586d0e8c09b84e1b78107713e97680e9fc0177236642294485c61000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401610101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020c638ea96808859efb035f3bc04c769a6e91095c0eea5c8b946f0f52b9b5fc915bc74416168b2d7f2f51a5643c8b4f6d51fb53a08a5cf3726d430f3f7359ea1082394485c62000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401620101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000200e6ff0a560cbaaed3ff887eadf7d9c5a382379d21e94f9f40ba6cfed31eeb860b2a17d595fed723dd3ba50080a443f1ef51b720c798c405d2b63dd9023cf503d2394485c63000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401630101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000204be76ff6ebef359465181334f047bb3ea6f31a6d336d632541ebce55f12f774a1371081c73fc174e0142b8c02f6c20898183602a1a29e194f27ad242704dd2c42394485c64000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401640101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"000000204ad82d3fb65f2acff5188150de9bff43b93d0840ff61ed1783234c89bc953685a42615727be6082edfb68f905eb24d43fadb1d8660356aa41de018028f5c8bbd2394485c65000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401650101ffffffff0200f2052a010000002321025a004424c7a8fd1c16b637de5c1c578c74ff6bd84cb8fd0ca988f3a38582177dac0000000000000000266a24aa21a9ede2f61c3f71d1defd3fa999dfa36953755c690689799962b48bebd836974e8cf9000000000120000000000000000000000000000000000000000000000000000000000000000000",
"00000020a95e653d74369746d0cd4d1621d39d7a2f3d3d33dd48d49123f107db7b6275d57f59a2b53ddfd8550f475741231f4ddf5b9851d6f1b9850853f3ecd827e2dc622394485c66000000015100020200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401660101ffffffff02b000062a010000002321037a347beb29fe060e6615746d992d19ffddb79cf16271c6d62898f1a3ce6083abac0000000000000000266a24aa21a9ed382d8ee84912819e6b649a5a54d7e68a6e37c4acdf4ec12b748826102522965c000000000120000000000000000000000000000000000000000000000000000000000000000000020000000001406dbfcd6f199cbde669d09fc693c9bfa16e4dd1328a2af3d5e56a9ed778c809000000004847304402207903f363462ae33fd93d8b8b4614d304e5c4eb3962df40b34485b2d6b79efdb70220263627a5c078c00afeeaeef51aff551114c0f53d703703a178bf580eb6b9b7b601feffffff0250bb9a3b0000000017a9142540c8553467c857872beab516a8e49b45f0dc678700286bee0000000017a914b7b1b4f0bbd20ed1a3fece3a020788acc3fa51478765000000",
"000000204d18791c9c8759359417190f39a9bf95780c4f3d6e7f54912dc5fb4e45ac65a06bdbc4996ca7e4e150c02ec82c1c83c1b29a3bcb85d4db0e217050e4604d63042394485c67000000015100040200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401670101ffffffff0230d0062a01000000232103d589857eec54577e93187c860bbc21906cd2e3991e30b335e335a4b307e8f3e7ac0000000000000000266a24aa21a9ede8a4c76ed6fde1bc29c8c2aedaf6e1af1cae3da72ef388e02371e21ee429522f0000000001200000000000000000000000000000000000000000000000000000000000000000000200000001016602a58784d330b83ee75a3d1d2570559bc4c55026e9a752f214a6255b9091ac0000000017160014298ea0a8cf41be1c95314139000897d610d0f3a7feffffff0250daa4350000000017a9140275d54d5cb288e535b74d31651871fc24d79b7787781ef5050000000017a914f7d87fc9bcfa051231b8d4f8ef3593fffaeb22bd87660000000247304402202bbbd7274eaae8da997df4d277ec6a860db5d81c78853bf722c6f39f9c416832022036e3edfe98deaf529f3ee614886b9d151df550446e1aa28005eb393d3800539d0121035e775dc614b3aece22e0ae171c06b1b8890a18d2aa1fd139a961d745c597add6000200000001016602a58784d330b83ee75a3d1d2570559bc4c55026e9a752f214a6255b9091ac010000001716001490d8469f4e9599284deeccf15f39aa5dee6f30befeffffff0208bd9a3b0000000017a914a36bf947ef6c17e05ee4dcf9471cb4347638b48687005ed0b20000000017a914c84692d657a501cc55ad8abd049c5fca58c046fb8766000000024730440220459a9375d9e5f32a5ceba02b5daa97f22a269772ef21cb83a11ce4a86e878ca202207afdebafef7fa19f8a589f3959a7d82e923fe35d2e957e2230311a0b196c3c30012102c7c26a51eac8807a484e1f7d1f5de05f8fff34ed7fabd693108ec8e80eec0e9a0002000000000130dc3ca7036a1b897e3363e9e60afb5c7f0d0cb0541e108456c0c13221ac567f000000004847304402204a8d1138a2e541a72284b9117d6ba2415badcf99599727655e29e08dc2a45f82022076285b20f39b342a3b50bc1086dc961b6b87409aff5c2ffe58f4304bc89f0f3501feffffff0250196bee0000000017a9142495b94e85e0da12acb560c6ffe614bccdd832338700ca9a3b0000000017a9141c9a1ac350b456023783da15517d74b558dcf96e872f000000"
"010000000000000000000000000000000000000000000000000000000000000000000000c3393f62b02c95bb8e3a7cee6d34687082cc6ed5e429681de5a1b14212eb3864dae5494d00000000015100010100000000010000000000000000000000000000000000000000000000000000000000000000ffffffff212000c7ac6641f4d9f883879df37385a9998553114d01c2c8e47608581773d7db37ffffffff0101000000000000000000000000000000000000000000000000000000000000000001000000000000000000016a00000000",
"000000202f0f28e1b187fae66482e1e77438f5603f4403d088d87b6bbde8f836da913012bbd98a024d2d70aad2ef8b3e1a78ef1ff6599b290b201ef8a2126b9f9fb0e77c9d02915c01000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03510101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000202da1ec9ce665e93156f36852603cfd784949565b44993a55f70f9bcb4803f8b9d7db3d92282cc077872146cdfc056f7170e51adc63d84de22cd6a2037f43dedc9e02915c02000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03520101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000208204334cc672af3631e50007a19a638df5ba01666b1ce3d0a8725917e1ef923cc41b602b6ebf608a2197a5e93c0a1c7c5aca7c0bc6d48adb19bfff959c46e6bd9e02915c03000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03530101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000209e01b460e9badcbbb8f25a1d358129f6041da2d95143b919c64235542a9d61d69b0fc435198ff7a3ae06b444d144fb396e977d8d7f16960338f2a9339d1120729f02915c04000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03540101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020c3a79791f5adf3b27c3ed419cedf3af70ff5f9574e1900f702695c5c2183f6725a0d449547208254dda242149c38fe966626318c464bad47cd6ecb144fb34d3d9f02915c05000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03550101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000209bf71be8ee00d0d0174fd235311218aa01e7c98695e8c5d251ecc1c8508c5837761ac152d9b87fdfb3a0d737ee00bfb4de1600ffbf938ebe28856cbf3c2904d29f02915c06000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03560101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002020885e749ad8d7d321018c574fdd8753156f7ff8c149ceb435ff1796c8a6c38e45f3e118464f6f7096ece24ad8fa50b28d218f6406355de6d44ebe6affea7fe79f02915c07000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03570101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020a335985a3d5ce8683b52c69fd7f46a0b5b5e20ba8a2a54efbdc911f9d008c19b89dd0de88714b636d3a999b053b3962107e772f5abf780b26bba864433193627a002915c08000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03580101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000200e882a5be6ff1c9024e7242729c29be3e008224cfa333bef5d4b22a8331dd31a0890700c6d4febe47b09ea2d56f9d9fdd1c05eec55981050bbed2771229d7934a002915c09000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03590101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002048601f806b6cc75bc30cca0fed2e8a8d0613be1453ad2b858e465b69d2870acfd78c23b5f05532d97abfe5b05f95e0532d29fd61465163abef8b7fc70edf3d27a002915c0a000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff035a0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020c25bd976932306bd47cf5aa9edd6f19f7aed47592b7c49dd5524ed964cbee2f01439b896595511873c8a331e96286bfdcb608e7c160eedd6ab31b0ebe509dc22a002915c0b000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff035b0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002004491f077795737190d54ed5ad2341a492ebf04df8aeb74e56ae56d0a56813dd1f87aa7052bf0f5a2699f786e892b06e8eb2f89236730073e750fdcf6deee71ba002915c0c000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff035c0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020d3f29618fc9806ee5d8473dbbaaf8398008f87ae2445d437bd9fe40a4cbec9f2befce0671847dfa1b5bc049a4c0159beccaba01569b75580f4b4b28d263a44bca002915c0d000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff035d0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020b6a354afa16d4ae90ada4f70f50ecfcc0c06b8dfa37a584695b249455cf46387605905e89ac4002b7dbcb09e511301997ff51aa06b59a9846ce870f8f427c38ba102915c0e000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff035e0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000205ed2ce4d910512f559fb965517ade47e7149ac6a3d44a7700094059ae2caf812eabf15ca3148be9abf84a185654db27ade6db493783a1ea7b5c437bde0ae9852a102915c0f000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff035f0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000201a3290bec4e96f217171e7616268eacb68fba4f6d60959104577ed78a790b6ed84d1f8679adc8e8b916cb947eea44e3e0bf4cdcf8c6e059874804a5a207a263da102915c10000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff03600101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020b97dfce3da99cfc316f19d74383b69b1713ed40db1989e12f259ea8453c8544d379cae64af5edcabe11efc3054f9c5e99130250e7de9812a4814ed9ce7e6014ea102915c11000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401110101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020b35833a22c2301e077d50a2507f34abc3f83e050dd4cc9a4e0bc18ccf5be4e620df4d653d36ba76167776dd55903adb8b2430dc19d1652c039fed68f7da3da0aa102915c12000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401120101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000208538dfabd8ff15f615f5ecbaa58dc6ffdaec77943868cab48e2b8acc36aaef11359aae7a7589350bbb72b16365e17d0d7dcbf848c70e8230dc70b932e7de42aea102915c13000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401130101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002004e1003785b07cc81bd7353695d196e8fa34d78efae2fbb19533cdca4320ee1a3fa237b85e51b16dd81874f3394c995451e098ff5e3e211c5052a9e16e198ee7a202915c14000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401140101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020557cae9628f3b1a955433cc67769148e20c8b9777bf52d883e4ae5530fcabdee52ab5572ce576f3451ca4b60c9c10a094834c60a2823d2de03a6cad4c44b885fa202915c15000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401150101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000204d5efed284a7a67c1d6f320354a0650835e685aacb941e26791815c9df97bc740f443d7d7d268cb607cd37dbb30b35672262ad66cfaf5fc21dc1c8b240e33f07a202915c16000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401160101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000200cfc15087e80529c594e86a501de87d00f28a74dc23faf6295ecd22f5ae5c7d2a6d03776971ca1afcaa66fa0de41a911e8ba9a72cee3835e00e1f3860e16266ea202915c17000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401170101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020f5ed5ef845d13820d2464c18d1d93f0e51ab094e04657135ac1f98fcbc43b76be7f110956454dcbb4a42b7a83b8263bf297235f60c00aa53bea10ed2c96c73bfa202915c18000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401180101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002061ee6e5acab9424762eb7edf32b0ec2ea0705f531c4f03373f92cd598919e41fa6e392492d579d4c24c7915fbc498958703903256480ffe5e0975e47e8a1b8f4a202915c19000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401190101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000209a22339b1c5b2dc250047f26879e316d9025fd81171cb847db773967d2105c5e94465261899c167cba7dc3019f312b4f80cba8eb9932641e9c53a4e78544007fa302915c1a000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04011a0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000209acbe67815dad2027ea4e14b19824aeb7265fd83db1e57ac6e4820e460821ee07c384faf78aa1526a10e5809c83274179953e63abf05008e2bb8560ee677f9c4a302915c1b000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04011b0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020af2bc3985ba146499749188ba5d26312acaae084cb579e5232b108ff71275dd2ed5ad4fe2514fbf2917a23d41fbfe774e2a9d7152a188e7692e295da033a7727a302915c1c000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04011c0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002068e626f30b75d16de01958838b484047c3fb8caae59aacb6590f6779b84ed7aed00b883ddf847162f951ee4442f0d0ede85a4a8e7c13037e8773eb4de5c1e6f3a302915c1d000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04011d0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002058425813e850db6ab721a04a269613ee9b5780aac1ec8f20a2be1e00ff6db4f3ca7c2cde5fdf68acc73d50a4cbfad45b71daf5f02e054b16a057402082c6892da302915c1e000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04011e0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020673646cffcc76bf8f1d0dbc7b43c29b2f33e87b61632c405f24f556274fd3e7c2cc8105e2b5dc9a575bdd878e843499f7664146d1019b19b7258ed6f8b127d3fa302915c1f000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04011f0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020b353f378277b8c1e48a0621e9c5d234dac56d85acbb60f80dbc4bea0459456640107ac3c8e6c1d9fedd4844ab01ee00ac7cec321d9d8b5c7c140e0bbedd9839da402915c20000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401200101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002029abdbdf968d4f7a725a031992a0d9614db55699faaa347382a72b9180117bea9418727081f4ab7f17a2519483d8e615aa15da91e82bcde9a081c57a8ced961da402915c21000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401210101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002020a61c612c5cb50b5b9ad50d0c5bf723b49f29d361b680581435d002e5820d8f97a58f49c361c39a33315ee38efe4ddb646a21b6e522db2bb18b114231b9ab27a402915c22000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401220101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020e6b34e1c1fbe333a7f5f82a168b9b38384cf41e9c673b02ff89e653e3a6ccdc96fcbc565d8310408ab2dbd22eb6f6d8a012e542c1222841569c6d70402089ab6a402915c23000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401230101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002042077bd67abcb1e6af6b32a9d1e60cd5c3449262402736c9e411168673c9899fa5a90a78001a244b0ef74b48b1cbae8c968f8c1fe519f2e79fc0862ffd3946c6a402915c24000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401240101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000202082b5936f7e263bcb66bf6f979ceed58dcbcfb07934296d309e0df9b6f70a36740fe7b763bf54ca7a63db4d86b69a7c0ec88d1d84449cd7d170463f1f378ecfa402915c25000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401250101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002033233b2deeb5cd94e1e7f1eaf7f5de63b820b246ff0b87e972064c687623cdc3337a690872596f95b9a802d8e95ac458a1d6d4f08619843e4e5b06f41042a3b4a502915c26000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401260101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002056cba074717277087a5e619090958480ed93bc6ce0a6c0eb484f73b7c1d68e2b9a0bd90abc128dcfc9d5ab572d7105cfbc62c832c66a1ffd6d52c0b5cb6e10a9a502915c27000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401270101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000209ed68bc59e304ea206636d73edbf684ba03e2a3559c083d76f1a6a6d52328d934901475b63d2044eeb355755025e3998f783f8ef1e69fe955574109e281748bba502915c28000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401280101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002079eef5d922ab32e29188cee5812caf123b7312cc29ceeda08bf3be03faa05e260d9a6a9189337f8f04594ecab3108b342b80cf65dd19758b0f9d7b1b4826e198a502915c29000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401290101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002057d9ced1a0c178b74f3a738ab05aef15fe220c1c8387ee7c22400596f14538091b100a082657519f001e3fd7d841e327a7d35b2fe07cdd9578d705d2cd6efce2a502915c2a000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04012a0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000204ecd5fedec7199028896e8c11c7ff74ecbf0092788d41fc36d8b7021f6b4559a0d1d2ac9edd2891e290b985f66bb5afd171d8f9a67284197c4bc4b9c49663e9ca502915c2b000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04012b0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000204a8a29a39d14b95cc622b74b0c4982eea79d5f933ba3e891ded0c57aa8df1ac64dd958fb82ba5181e6e65a6175520f631df3118635b392dca8e5ceaceb6c1bb7a602915c2c000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04012c0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002019aad581d7547a50e476cec6daef4f233e4c7c516af061af39ff526ba833f41881bdfe7fcd5b5ba4fbddb0c6098633826cb8054e740a71f78e25a2895f644922a602915c2d000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04012d0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020410e9211e913dd29a15d27e7c9a048fb5542530643c4bb51317165f8af1e6ec2f88c5bc59488afc37fea44716bfce0facb028fd51da1fec2e3c0eed97f438b73a602915c2e000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04012e0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020e652a8511070cf371a378399721432c410bc5747dcd382c6100e8906395d29d46225086fcfa06e90726d5e2fd09510ffcc18f5aafac81aa87ebbe4e4de846c38a602915c2f000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04012f0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000209591495f63b0a7d589aba645a31dad9e06e204a286a0501077dd01b488dd941804d57974f4e92cf239391ea2b5df2342f7ebfe1770953b86d7ff12cdadb022ada602915c30000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401300101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020a53b5f436f04f49430e824a58fc0cba5471b363f71b2db3ff739f9c0f282f461ab213c24d22ecc24f2ba32f2d2ee65507c1a767c4894f90b02cda274e1c3f92ea602915c31000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401310101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002098d051b1c85ac1e7b09a7aeca52349c90fa0350165381ccee49653ce57dafeb7af4b988a0d56987e3d3919c7048d960512c98d092b59c5b1a46324601b0f6cb5a702915c32000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401320101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020c93a60a62d96f816416fc50281a65bb19fd77e0e7d938640cdc8ba88c97ccab822a8ea468800c0429fe59a2abd265fc5f4d14f694eab3dad9318f9691cefc73ea702915c33000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401330101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000206ccf3364f43afdc2fcd4364227e9a31eda0d8f536c2532b68c1e005d3993ca4f42007ac74ce6e1b5eda1810292114e91b7c64888317dec32654138db7f2031c0a702915c34000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401340101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020ffac52e3cbf8c584aab046cb981e93dc3d21477816f828d84f9047ff78396a31c8a63e1aae4948b4a2c7fab715d0a357b21751c6b876d43bfe749d8e15d32254a702915c35000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401350101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020744cac41a4816d17f1cd5142e3890c22211db87a142fe18603f8b8a5428b579816cdb1fb2b5ef79bf30eb48d60b599e668f9f64fe2082a965e1cdf7bf7549f46a702915c36000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401360101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000208fd48bfe7c58fe148fa003a96ddfa17817e823797878e796fb67b1651fc7b8e026c9a0fb1449649714bba349932a0f62d3a5e28d2b9c585ee2c9be1a847e5e01a702915c37000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401370101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000200233a559c1c4b437c6950028e28408db80f00e3ab810bcac86f024dce494e94898538afbd970deb45714bc6209e41aa3188094fef1719961b230aca17b223919a802915c38000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401380101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002003bb4a953fdf6ed0f0018eb0d78a040359af895c7bba7febd3d56c638837a0bf1f06a3a0fc5290742dbf231626f8bb04e79d57ae97fadf9f85ee0a4c6013254ba802915c39000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401390101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020f3991bef93be65aca3076688da86e2611bb82c8a19925cd7d4c291a6ef4e478d680d89caeb42810bd01144d420dcfb1e10eab9c79e7e62691b86044dcb5fbaaca802915c3a000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04013a0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020616cc92bb11d26469f24f08c6bdb45a321a3f1a7e91ec3fafbc6642709a32e94530562182d9519688604a94909dead0b24363e6f3ff2016d878647e214b6e4daa802915c3b000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04013b0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002073a0029d38a696d6360edbbc2195c0bd82c08cf0ddf576945c042f50fc7f4c1b326000a7779a21777df7b782ae72e3ef374955fede538eb891579707b0473362a802915c3c000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04013c0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000200b231755e8aab5f80aee431ebbfbf20418a9f27f681ef859b7b682d3141b5bbfdacf3ac67971729abcba74745282356f0c6a8c577be22b1f7b3000926cc9ed78a802915c3d000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04013d0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000201862a13752e1bc14c274188f959f39d2e9d9627331c531de71240da316d7897c98a5c027599770b28191c45993f942a85345154e66a3acfd7842e13ad02a812ba902915c3e000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04013e0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020433af23a58a9fef69e9e574404e5cd95c41a96fda02a30e7bf900d2225364e7f5b0d76d8e9ce8b01558b9d7b4179462dcc0f5faf556023366c7ad2f3e2005acea902915c3f000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04013f0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002042a73527ff3a57a9d3172df1b898fa00b2f293d9faaca9b45996f1638d6d1b4025fe5509ce08a87d025fb70aaa73f58d261576e2958ed46f584a30e1b1ff0746a902915c40000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401400101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002087ec8da14dff459682819b4b1a9f842ca6912b803dcbe55a56ec95197836be700666bb97900bb7e14aba8a2ba760ceb7436864a23d82825feb4a81ffc98be597a902915c41000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401410101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020961cee505188163c3dfcc6920275cf7225718a0bac22325eeee3cee0e0a2e57792b3a0b7bc108156d5953f0ad18e1f7b6fb38950f8a62aa603640ca7839395b6a902915c42000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401420101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020ef59432e9bb1652ffc611ed8d932ccb23e551c4144b81055521e8d4f1b236b05545c185bfc1a98ee0bc3dbfe56a2e703265a8f280671f6e51ca9023cd4749aa1a902915c43000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401430101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000204bda7ce6d35ec869a2011ed284aae2328dba1b62780f919884117d8fd4860f253c3d09c3698cf581a6279749a03f42c201e5a0dea34520f5c67b9f716161fa53aa02915c44000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401440101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020fe0b14c8da908a984829247e71e7cb3f3cb3ca7070fa0d47a9337777020bad67605a9b63d3effba463d55840f91c998668b80ead90468fdb7a9607897f66001aaa02915c45000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401450101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020e35b4b7d25fa37415ea3fdab0d6806368567013187bc95a3f994a99b1f281b6c8319f2e5370af4d0c852879ff1667f9562d8f7644f9812609eea94c9c8448772aa02915c46000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401460101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000208aadf8c16346343e1414b4a30b330487ef62199a30f9b500a701fd887826b090e308cd24a23b84de57f941676b93a96b1f229baa6fb7ad7220bec488476add21aa02915c47000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401470101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000207d769f107729e118467be3154c02a4f05d00b1d21ce21057895ab7fe0e4cf0a73988a2cd7f83e9d3b5b07878f0cd1bdecf9c31536006499f6ee025ae616222caaa02915c48000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401480101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000209ca259ceb09be93316a90d5c9a4a09103a4abddf94ba9d073e1e503f90a461848e340eb1538316adab296685a87bc7c32d0e941edc165503abf6790b86bbc7ceaa02915c49000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401490101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000205388999d8cb247c12fdefed29b9f6a85a985dfd83ad4aeb8ee98bfbb8edccc530a6150a31b849fc4fc571b596a70090261fb60049c1d9372b9b8ba6f2ad4dc82ab02915c4a000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04014a0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020f53baf0d1812c6dea4b8e14acb2d6977a70c207efd48181fd6732adf261397f1621e238a5c2fe59e192d4ba1e1394b94ed44550714d5b57099b0d6b825622491ab02915c4b000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04014b0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000202cb270047b47c45be237db41d825ffeb3f4766297d0184033eb45824972dae5edd8c2f41d3a81b15bce841706b66b45f336899f0130b94fc7637492ae285fd60ab02915c4c000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04014c0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020a4ef606938a9a92f8f2a170f34616f2ee4979c13c42a815520d1aa36871f83d37d607bfab22800335b0b6d971be1ec03a01254f5a4cc75a80ba141c2c0524906ab02915c4d000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04014d0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020ca42b10948f1e218b27e356f76011dfefcbc8f5dd1a2d0419686dab1ceb0e577b7b7c2f767c21ab16be853fa6779146c4c78eabac5f8c39d29b3e43751726446ab02915c4e000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04014e0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020cc04f63390616e2215a0a0945c755f33f4d605e789976243bb35844e22479d290158cc9adff2643fa9338259e1b4362f9290735416fca75555b727203e718bfbab02915c4f000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04014f0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000207d4215ab4c13e5b4414e49973f121ff68da44b17292350a5bff786c4d3d2b584916f1ff722251a939aa55051ca9d158408995e29274207a330776a101c2fa0b3ac02915c50000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401500101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020c28211e18b41d4b8aec31df60a3135cfdcc99b11114f2eb21314e3a48938a02a71aad39e514182e10b218d23696a617b047dd1b243f5e1680b6520c8cf864beeac02915c51000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401510101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000209f640bdbb580a2557d7c7782973c0d5ff0a8a023695bc6824cffc76d83b88c3b8c2ffc8a0e0837ecf2a0c33501cbe8cd510b108154885cd8e76d584725fefa03ac02915c52000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401520101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000201e580880a75f714bc90276b98b21b97e2fcad8c0ff61fe5e378a9ff45e4e3b461d24b941da116fb12b759936b6b3238fa8fdd66e40d02cf302eb854d0847b7e7ac02915c53000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401530101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000203d94aead98f94567c41c5da5bfbe3620d40b8ea5425ae2b5683bc16a2e6782d39190525fa28832ff1d0569c0719cd2c04680f7ac2010c8c3268aad2ad3488e29ac02915c54000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401540101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002071df1cc3f5d3fff8e1a282a5b9455061597d8aac95d56e093755aa8f5f1b1db12ea8616398263e41ab1049959696413c27e3080f5e388c19da31ad76ce89e806ac02915c55000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401550101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000201a61d73ca34037d4f08920bfcc6bafb57149c547c553a0a85ca3166db2ef243461288d38731fc54dabd21700003aab86e87e849a82f614345f8da7dca8edd130ad02915c56000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401560101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000209c49486d51402018342befe3330b536ea1eac14b0f00ea131722bfd09370cefb59c5aed0422bc42c50e4138d33a6bcd659317bb3661aa9ce6657a6333ba18a8fad02915c57000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401570101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020d56e332f67acfc1128fa93f7ffbbe554cbdeef8cceb89a119156180a5e8b81e244665c973eddd5f81bf6cb6144d7e84381c6dfb783beb11130cb1cf79db90e82ad02915c58000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401580101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000208e903d31e5e278902d535e4d2cc418ee9ea63fbf36f127fdb642d6469c6aa100faf085b53859f32dfc94841f537526fca2479fe1fb943e6ab91f5c7a78f51368ad02915c59000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401590101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020ebcb3c5c9160cbecdc0734f55d4713b0fac6f7003b297988e4dad8a57eef4b92d203d5c2b6b3335fc9604c6ce95f6bfac6977467a150f3f495b4b300540e6df6ad02915c5a000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04015a0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002042c9c1a24d03b3db35ddc5573f5e23283637fcdf73b8c21be02d99d9a3ff8240924631207fc34526bbcda94cf8235882dd3a6bab5ea56743f9fbeaa38a2e5254ad02915c5b000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04015b0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002038094efd387b97cbdf9b3d8bf21cd0dda954c23cb056e38f4ecbd96855fbbcfc277ddca3e52190b7883959cfcd201b01163c3e627624f0fbd04490a970b0df63ae02915c5c000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04015c0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000204879e2df8301543265bf765fc51a894272b3e2d7e50454b4100dc00a953eab4082543e26381b87a430c7a71c0f38f192189e65f6db79267e3e0d094029ff6270ae02915c5d000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04015d0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002019a0344a4ef124f293d457b37bf4ce2d6ae7fdcaa46e375042913e254aa3ea2ffcb78ec6186bd861a02afdf2f4322e29c3d7b192c4777ee6745c7a2e36c4d073ae02915c5e000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04015e0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020986f9867d5a27cb34a0764bc2714d6fcccbcfaa125a926a82e49bd78fd0e0e7cfd3bd03f08c915434545283592a3dd0061cc7596a5c82f1bf88ddb675c955c16ae02915c5f000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff04015f0101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"0000002075a4ecb68d3f34664bb7b238394e06d750078641a51ab11c55bfa9e073b1179dfc17f4166c17371ebf3dee07a1f3b9e0fe382446729eef1c59e8cda0091b4b50ae02915c60000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401600101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020b5100cbaebfdf50984ba010451e9245cd020e1793b38cb4f0faf82f6e7c6cacdfc29ba9d90e2f7332aca7a5554b8fa845e057408d30c6e68c90e54c9e2f30a9dae02915c61000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401610101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000202672892ed7f338cf4b044bb1b632c623ffe2e222eb300f3bfad9583b3592caa0bf8afbbc47216c15ac18157df4361225b155adc6e786d194eeff74a398911e9eaf02915c62000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401620101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000207cdebf929df5e502e54df09bad1c4f3748d2eb73ac218ffef313ff867bd225fac9bc88211e589c3cb7e96448ef269cffa56e93dbd41fe785daa84d9ce1f1acb0af02915c63000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401630101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020f0ffd9ccf295979531ba943326a85d76582197ecca9f4bddd8bad5f6b53db221a944fae8912c4b71f0a626ae993222543b39ba0437bac884105961a607e61de9af02915c64000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401640101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"00000020d923740c8fc935794c02e27fa8aea90973587b9ee73b2832563c4c8e8d255531510045cfdad4bcf41bc5ce5a6fd90bfd969cf98aba8590e9d037e888348ebe87af02915c65000000015100010200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401650101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a05f20000232102d108f32b4d80982dd6dcb624444316036b2113b9370fed95dcb1829064f3978fac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed94f15ed3a62165e4a0b99699cc28b48e19cb5bc1b1f47155db62d63f1e047d45000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000",
"000000205166142c3f7669f960459763e26d53e81c8af79841207e0a22adfda4192dd3ec6294db3749a270d1896251e3a104e85c7575c4d218a8fb1b555ac345d340782daf02915c66000000015100020200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401660101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a06099800232102cdd50a6eefb5fed99acbdf9029e6d362f599f03e69b134083500cdeba7ff4e36ac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed9b1d0d73201f13ebd5461521c6ecd7bee90953e5041e9ebc697682543b04997d000000000000012000000000000000000000000000000000000000000000000000000000000000000000000000020000000001bbd98a024d2d70aad2ef8b3e1a78ef1ff6599b290b201ef8a2126b9f9fb0e77c000000004847304402202412b64ad73ddb8a3cccf96a9a539b2db4b93c443bb816b28628d89275380c3b022046f1f0b09452845813b5c587e9ac309b7915b5423276b18cdc792874c342b19b01feffffff0301ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe00100000000ee6b28000017a91462c226e5e017a9a8086959dc921f070714f26d438701ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000003b9ab2680017a914f1611c75a7a9f25eb9c0b565c4f06711fec7534d8701ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe0010000000000001798000065000000",
"000000202989c09febf56c27100fc6297ce51197290927ee981e750e5c2a033618cee7df5d7ae1b6664568dc1ea5cca4d12ef410f61c0f79002cc7ff917aa4c31cfc0deeaf02915c67000000015100040200000001010000000000000000000000000000000000000000000000000000000000000000ffffffff0401670101ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000012a076a18002321020da92238075c918151e77be19bd54152f7669e88efbd2e258baf1e21e5be789eac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000266a24aa21a9ed09f93b24b9dd3a95ac5231c9b233eec7acbc1054703e16df6998c8c241ac78bd0000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000200000001015822b24718d35bcd38a619b0b4ce4239ff9e61f13468ee7e27b9f324a6263f090100000017160014cbc25453c1a247f26a048d69b42b66710db8fd78feffffff0301ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe0010000000005f496880017a91474ec3207cdae1c779baa1f599017816fe49bdfc48701ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe0010000000035a4d1680017a9145e88481b620ef3093a0383509d663ec616c051e88701ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe0010000000000014a7800006600000000000247304402206008db7f5d1ba69127b27d6987f3803110e55133d400b8a441453f952efe1c6002202ad300ba39a3c7bda9793c0d353653725ff8cd310c3d44db702c6c57a33a632a0121033017f6207dde0cc5e8e514145bc43c949b1fa13a53de6233fb31121ae51a56c0000000000000000200000001015822b24718d35bcd38a619b0b4ce4239ff9e61f13468ee7e27b9f324a6263f0900000000171600145e84a5f10445f5407155eaa7afb51587990922cffeffffff0301ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe00100000000b2d05e000017a91413b12b0f94b15d8bd9c60ea63f51f05a655dd4e58701ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000003b9ab3f80017a9144486fe6249c47524beaf88e86a560dd4401b6d268701ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000160800006600000000000247304402202bd35d82e6f0166538840c632d69a8a1e8789c06f410ed62074ef65e6d1361de022041d596a0aa0cb4167eceb0a613373562f7284a7f9c5a0d3b3dbd09abdace1f3e012102f8b6447e355e55a8bf4a39b6ae784fd80f783fb97b17c0913da7ce4306a304fc00000000000000020000000001d7db3d92282cc077872146cdfc056f7170e51adc63d84de22cd6a2037f43dedc000000004847304402203b7412eda80c226a4812ac998c9c93af5e44d33fc9e7c1abc05196b0212c9080022057ede7f10ba59f3c6ed9e1b2a97984ff4c52ca75a1cdfb6bc4112d21bede528e01feffffff0301ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe00100000000ee6b10680017a914aabd915df14b9fa6d355081d2eb3c1738fd230158701ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000003b9aca000017a914d020b71158b074335be830a67cf11e8246290b1b8701ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe0010000000000001798000066000000"
],
"mocktime": 1548260369,
"mocktime": 1553007261,
"stats": [
{
"avgfee": 0,
"avgfeerate": 0,
"avgtxsize": 0,
"blockhash": "d575627bdb07f12391d448dd333d3d2f7a9dd321164dcdd0469736743d655ea9",
"blockhash": "ecd32d19a4fdad220a7e204198f78a1ce8536de263974560f969763f2c146651",
"feerate_percentiles": [
0,
0,
@ -125,7 +125,7 @@
"maxfeerate": 0,
"maxtxsize": 0,
"medianfee": 0,
"mediantime": 1548260386,
"mediantime": 1553007278,
"mediantxsize": 0,
"minfee": 0,
"minfeerate": 0,
@ -135,20 +135,20 @@
"swtotal_size": 0,
"swtotal_weight": 0,
"swtxs": 0,
"time": 1548260387,
"time": 1553007279,
"total_out": 0,
"total_size": 0,
"total_weight": 0,
"totalfee": 0,
"txs": 1,
"utxo_increase": 2,
"utxo_size_inc": 173
"utxo_size_inc": 0
},
{
"avgfee": 3760,
"avgfee": 6040,
"avgfeerate": 20,
"avgtxsize": 188,
"blockhash": "a065ac454efbc52d91547f6e3d4f0c7895bfa9390f1917943559879c1c79184d",
"avgtxsize": 302,
"blockhash": "dfe7ce1836032a5c0e751e98ee2709299711e57c29c60f10276cf5eb9fc08929",
"feerate_percentiles": [
20,
20,
@ -158,34 +158,34 @@
],
"height": 102,
"ins": 1,
"maxfee": 3760,
"maxfee": 6040,
"maxfeerate": 20,
"maxtxsize": 188,
"medianfee": 3760,
"mediantime": 1548260386,
"mediantxsize": 188,
"minfee": 3760,
"maxtxsize": 302,
"medianfee": 6040,
"mediantime": 1553007278,
"mediantxsize": 302,
"minfee": 6040,
"minfeerate": 20,
"mintxsize": 188,
"outs": 4,
"mintxsize": 302,
"outs": 5,
"subsidy": 5000000000,
"swtotal_size": 0,
"swtotal_weight": 0,
"swtxs": 0,
"time": 1548260387,
"total_out": 4999996240,
"total_size": 188,
"total_weight": 752,
"totalfee": 3760,
"time": 1553007279,
"total_out": 5000000000,
"total_size": 302,
"total_weight": 1208,
"totalfee": 6040,
"txs": 2,
"utxo_increase": 3,
"utxo_size_inc": 234
"utxo_increase": 4,
"utxo_size_inc": -120
},
{
"avgfee": 18960,
"avgfeerate": 109,
"avgtxsize": 227,
"blockhash": "3a131d3eaa51d02e12f2488cdf9df77074e046515822d5c5a247c7cbb18ed44d",
"avgfee": 32093,
"avgfeerate": 111,
"avgtxsize": 346,
"blockhash": "210cb143bfbc8a0f41e497a75a40c220b45b5134dc8e37ef47cf01ab3c6f5cfa",
"feerate_percentiles": [
20,
20,
@ -195,28 +195,28 @@
],
"height": 103,
"ins": 3,
"maxfee": 49800,
"maxfee": 84600,
"maxfeerate": 300,
"maxtxsize": 247,
"medianfee": 3760,
"mediantime": 1548260387,
"mediantxsize": 247,
"minfee": 3320,
"maxtxsize": 369,
"medianfee": 6040,
"mediantime": 1553007279,
"mediantxsize": 369,
"minfee": 5640,
"minfeerate": 20,
"mintxsize": 188,
"outs": 8,
"mintxsize": 302,
"outs": 11,
"subsidy": 5000000000,
"swtotal_size": 494,
"swtotal_weight": 1328,
"swtotal_size": 738,
"swtotal_weight": 2256,
"swtxs": 2,
"time": 1548260387,
"total_out": 9999939360,
"total_size": 682,
"total_weight": 2080,
"totalfee": 56880,
"time": 1553007279,
"total_out": 9999993960,
"total_size": 1040,
"total_weight": 3464,
"totalfee": 96280,
"txs": 4,
"utxo_increase": 5,
"utxo_size_inc": 380
"utxo_increase": 8,
"utxo_size_inc": -336
}
]
}

View file

@ -78,8 +78,7 @@ class BIP68Test(BitcoinTestFramework):
sequence_value = SEQUENCE_LOCKTIME_DISABLE_FLAG | 1
tx1.vin = [CTxIn(COutPoint(int(utxo["txid"], 16), utxo["vout"]), nSequence=sequence_value)]
tx1.vout = [CTxOut(value, CScript([b'a']))]
tx1.vout.append(CTxOut(int(self.relayfee*COIN)))
tx1.vout.append(CTxOut(int(utxo["amount"]*COIN) - value)) # fee
tx1_signed = self.nodes[0].signrawtransactionwithwallet(ToHex(tx1))["hex"]
tx1_id = self.nodes[0].sendrawtransaction(tx1_signed)
tx1_id = int(tx1_id, 16)
@ -185,9 +184,9 @@ class BIP68Test(BitcoinTestFramework):
tx.vin.append(CTxIn(COutPoint(int(utxos[j]["txid"], 16), utxos[j]["vout"]), nSequence=sequence_value))
value += utxos[j]["amount"]*COIN
# Overestimate the size of the tx - signatures should be less than 120 bytes, and leave 50 for the output
tx_size = len(ToHex(tx))//2 + 120*num_inputs + 50
tx_size = len(ToHex(tx))//2 + 120*num_inputs + 150 # ELEMENTS: overestimate more for output witnesses
tx.vout.append(CTxOut(int(value-self.relayfee*tx_size*COIN/1000), CScript([b'a'])))
tx.vout.append(CTxOut(int(self.relayfee*tx_size*COIN/1000)))
tx.vout.append(CTxOut(int(self.relayfee*tx_size*COIN/1000))) # fee
rawtx = self.nodes[0].signrawtransactionwithwallet(ToHex(tx))["hex"]
if (using_sequence_locks and not should_pass):
@ -216,7 +215,8 @@ class BIP68Test(BitcoinTestFramework):
tx2 = CTransaction()
tx2.nVersion = 2
tx2.vin = [CTxIn(COutPoint(tx1.sha256, 0), nSequence=0)]
tx2.vout = [CTxOut(int(tx1.vout[0].nValue - self.relayfee*COIN), CScript([b'a']))]
tx2.vout = [CTxOut(int(tx1.vout[0].nValue.getAmount() - self.relayfee*COIN), CScript([b'a']))]
tx2.vout.append(CTxOut(int(self.relayfee*COIN))) # fee
tx2_raw = self.nodes[0].signrawtransactionwithwallet(ToHex(tx2))["hex"]
tx2 = FromHex(tx2, tx2_raw)
tx2.rehash()
@ -234,7 +234,8 @@ class BIP68Test(BitcoinTestFramework):
tx = CTransaction()
tx.nVersion = 2
tx.vin = [CTxIn(COutPoint(orig_tx.sha256, 0), nSequence=sequence_value)]
tx.vout = [CTxOut(int(orig_tx.vout[0].nValue - relayfee * COIN), CScript([b'a' * 35]))]
tx.vout = [CTxOut(int(orig_tx.vout[0].nValue.getAmount() - relayfee * COIN), CScript([b'a' * 35]))]
tx.vout.append(CTxOut(int(relayfee * COIN))) # fee
tx.rehash()
if (orig_tx.hash in node.getrawmempool()):
@ -289,7 +290,7 @@ class BIP68Test(BitcoinTestFramework):
utxos = self.nodes[0].listunspent()
tx5.vin.append(CTxIn(COutPoint(int(utxos[0]["txid"], 16), utxos[0]["vout"]), nSequence=1))
tx5.vout[0].nValue += int(utxos[0]["amount"]*COIN)
tx5.vout[0].nValue.setToAmount(tx5.vout[0].nValue.getAmount() + int(utxos[0]["amount"]*COIN))
raw_tx5 = self.nodes[0].signrawtransactionwithwallet(ToHex(tx5))["hex"]
assert_raises_rpc_error(-26, NOT_FINAL_ERROR, self.nodes[0].sendrawtransaction, raw_tx5)
@ -347,7 +348,8 @@ class BIP68Test(BitcoinTestFramework):
tx2 = CTransaction()
tx2.nVersion = 1
tx2.vin = [CTxIn(COutPoint(tx1.sha256, 0), nSequence=0)]
tx2.vout = [CTxOut(int(tx1.vout[0].nValue - self.relayfee*COIN), CScript([b'a']))]
tx2.vout = [CTxOut(int(tx1.vout[0].nValue.getAmount() - self.relayfee*COIN), CScript([b'a']))]
tx2.vout.append(CTxOut(int(self.relayfee*COIN))) # fee
# sign tx2
tx2_raw = self.nodes[0].signrawtransactionwithwallet(ToHex(tx2))["hex"]
@ -362,7 +364,8 @@ class BIP68Test(BitcoinTestFramework):
tx3 = CTransaction()
tx3.nVersion = 2
tx3.vin = [CTxIn(COutPoint(tx2.sha256, 0), nSequence=sequence_value)]
tx3.vout = [CTxOut(int(tx2.vout[0].nValue - self.relayfee * COIN), CScript([b'a' * 35]))]
tx3.vout = [CTxOut(int(tx2.vout[0].nValue.getAmount() - self.relayfee * COIN), CScript([b'a' * 35]))]
tx3.vout.append(CTxOut(int(self.relayfee*COIN))) # fee
tx3.rehash()
assert_raises_rpc_error(-26, NOT_FINAL_ERROR, self.nodes[0].sendrawtransaction, ToHex(tx3))

View file

@ -270,12 +270,12 @@ class FullBlockTest(BitcoinTestFramework):
self.move_tip(15)
b23 = self.next_block(23, spend=out[6])
tx = CTransaction()
# ELEMENTS: mysterious off-by-one
#script_length = MAX_BLOCK_BASE_SIZE - len(b23.serialize()) - 69
script_length = MAX_BLOCK_BASE_SIZE - len(b23.serialize()) - 70
script_length = MAX_BLOCK_BASE_SIZE - len(b23.serialize()) - 149
script_output = CScript([b'\x00' * script_length])
tx.vout.append(CTxOut(0, script_output))
tx.vin.append(CTxIn(COutPoint(b23.vtx[1].sha256, 0)))
tx.vout.append(CTxOut(b23.vtx[1].vout[0].nValue.getAmount() - 0)) # fee
b23 = self.update_block(23, [tx])
# Make sure the math above worked out to produce a max-sized block
assert_equal(len(b23.serialize()), MAX_BLOCK_BASE_SIZE)
@ -285,11 +285,11 @@ class FullBlockTest(BitcoinTestFramework):
self.log.info("Reject a block of size MAX_BLOCK_BASE_SIZE + 1")
self.move_tip(15)
b24 = self.next_block(24, spend=out[6])
# ELEMENTS: mysterious off-by-one
#script_length = MAX_BLOCK_BASE_SIZE - len(b24.serialize()) - 69
script_length = MAX_BLOCK_BASE_SIZE - len(b24.serialize()) - 70
script_length = MAX_BLOCK_BASE_SIZE - len(b24.serialize()) - 149
script_output = CScript([b'\x00' * (script_length + 1)])
tx.vout = [CTxOut(0, script_output)]
tx.vout.append(CTxOut(b23.vtx[1].vout[0].nValue.getAmount() - 0)) # fee
b24 = self.update_block(24, [tx])
assert_equal(len(b24.serialize()), MAX_BLOCK_BASE_SIZE + 1)
self.sync_blocks([b24], success=False, reject_reason='bad-blk-length', reconnect=True)
@ -423,10 +423,11 @@ class FullBlockTest(BitcoinTestFramework):
self.move_tip(35)
b39 = self.next_block(39)
b39_outputs = 0
b39_sigops_per_output = 6
# ELEMENTS: increase the number of sigops per output to not hit max block size first
b39_sigops_per_output = 11
# Build the redeem script, hash it, use hash to create the p2sh script
redeem_script = CScript([self.coinbase_pubkey] + [OP_2DUP, OP_CHECKSIGVERIFY] * 5 + [OP_CHECKSIG])
redeem_script = CScript([self.coinbase_pubkey] + [OP_2DUP, OP_CHECKSIGVERIFY] * (b39_sigops_per_output-1) + [OP_CHECKSIG])
redeem_script_hash = hash160(redeem_script)
p2sh_script = CScript([OP_HASH160, redeem_script_hash, OP_EQUAL])
@ -434,7 +435,8 @@ class FullBlockTest(BitcoinTestFramework):
# This must be signed because it is spending a coinbase
spend = out[11]
tx = self.create_tx(spend, 0, 1, p2sh_script)
tx.vout.append(CTxOut(spend.vout[0].nValue - 1, CScript([OP_TRUE])))
tx.vout.append(CTxOut(spend.vout[0].nValue.getAmount() - 1, CScript([OP_TRUE])))
self.update_fee(tx, spend, 0)
self.sign_tx(tx, spend)
tx.rehash()
b39 = self.update_block(39, [tx])
@ -446,7 +448,8 @@ class FullBlockTest(BitcoinTestFramework):
total_size = len(b39.serialize())
while(total_size < MAX_BLOCK_BASE_SIZE):
tx_new = self.create_tx(tx_last, 1, 1, p2sh_script)
tx_new.vout.append(CTxOut(tx_last.vout[1].nValue - 1, CScript([OP_TRUE])))
tx_new.vout.append(CTxOut(tx_last.vout[1].nValue.getAmount() - 1, CScript([OP_TRUE])))
self.update_fee(tx_new, tx_last, 1)
tx_new.rehash()
total_size += len(tx_new.serialize())
if total_size >= MAX_BLOCK_BASE_SIZE:
@ -481,6 +484,7 @@ class FullBlockTest(BitcoinTestFramework):
tx.vin.append(CTxIn(lastOutpoint, b''))
# second input is corresponding P2SH output from b39
tx.vin.append(CTxIn(COutPoint(b39.vtx[i].sha256, 0), b''))
tx.vout.append(CTxOut(b39.vtx[i].vout[0].nValue.getAmount())) # fee
# Note: must pass the redeem_script (not p2sh_script) to the signature hash function
(sighash, err) = SignatureHash(redeem_script, tx, 1, SIGHASH_ALL)
sig = self.coinbase_key.sign(sighash) + bytes(bytearray([SIGHASH_ALL]))
@ -743,7 +747,7 @@ class FullBlockTest(BitcoinTestFramework):
b59 = self.next_block(59)
tx = self.create_and_sign_transaction(out[17], 51 * COIN)
b59 = self.update_block(59, [tx])
self.sync_blocks([b59], success=False, reject_reason='bad-txns-in-belowout', reconnect=True)
self.sync_blocks([b59], success=False, reject_reason='block-validation-failed', reconnect=True)
# reset to good chain
self.move_tip(57)
@ -826,12 +830,12 @@ class FullBlockTest(BitcoinTestFramework):
tx = CTransaction()
# use canonical serialization to calculate size
# ELEMENTS: mysterious off-by-one
#script_length = MAX_BLOCK_BASE_SIZE - len(b64a.normal_serialize()) - 69
script_length = MAX_BLOCK_BASE_SIZE - len(b64a.normal_serialize()) - 70
script_length = MAX_BLOCK_BASE_SIZE - len(b64a.normal_serialize()) - 149
script_output = CScript([b'\x00' * script_length])
tx.vout.append(CTxOut(0, script_output))
tx.vin.append(CTxIn(COutPoint(b64a.vtx[1].sha256, 0)))
tx.vout.append(CTxOut(b64a.vtx[1].vout[0].nValue.getAmount() - 0)) # fee
b64a = self.update_block("64a", [tx])
assert_equal(len(b64a.serialize()), MAX_BLOCK_BASE_SIZE + 8)
self.sync_blocks([b64a], success=False, reject_reason='non-canonical ReadCompactSize(): iostream error')
@ -860,8 +864,9 @@ class FullBlockTest(BitcoinTestFramework):
self.log.info("Accept a block with a transaction spending an output created in the same block")
self.move_tip(64)
b65 = self.next_block(65)
tx1 = self.create_and_sign_transaction(out[19], out[19].vout[0].nValue)
tx2 = self.create_and_sign_transaction(tx1, 0)
tx1 = self.create_and_sign_transaction(out[19], out[19].vout[0].nValue.getAmount())
# ELEMENTS: doesn't support 0 value for non-OP_RETURN
tx2 = self.create_and_sign_transaction(tx1, 1)
b65 = self.update_block(65, [tx1, tx2])
self.sync_blocks([b65], True)
self.save_spendable_output()
@ -873,7 +878,7 @@ class FullBlockTest(BitcoinTestFramework):
self.log.info("Reject a block with a transaction spending an output created later in the same block")
self.move_tip(65)
b66 = self.next_block(66)
tx1 = self.create_and_sign_transaction(out[20], out[20].vout[0].nValue)
tx1 = self.create_and_sign_transaction(out[20], out[20].vout[0].nValue.getAmount())
tx2 = self.create_and_sign_transaction(tx1, 1)
b66 = self.update_block(66, [tx2, tx1])
self.sync_blocks([b66], success=False, reject_reason='bad-txns-inputs-missingorspent', reconnect=True)
@ -887,7 +892,7 @@ class FullBlockTest(BitcoinTestFramework):
self.log.info("Reject a block with a transaction double spending a transaction creted in the same block")
self.move_tip(65)
b67 = self.next_block(67)
tx1 = self.create_and_sign_transaction(out[20], out[20].vout[0].nValue)
tx1 = self.create_and_sign_transaction(out[20], out[20].vout[0].nValue.getAmount())
tx2 = self.create_and_sign_transaction(tx1, 1)
tx3 = self.create_and_sign_transaction(tx1, 2)
b67 = self.update_block(67, [tx1, tx2, tx3])
@ -908,14 +913,14 @@ class FullBlockTest(BitcoinTestFramework):
self.log.info("Reject a block trying to claim too much subsidy in the coinbase transaction")
self.move_tip(65)
b68 = self.next_block(68, additional_coinbase_value=10)
tx = self.create_and_sign_transaction(out[20], out[20].vout[0].nValue - 9)
tx = self.create_and_sign_transaction(out[20], out[20].vout[0].nValue.getAmount() - 9)
b68 = self.update_block(68, [tx])
self.sync_blocks([b68], success=False, reject_reason='bad-cb-amount', reconnect=True)
self.log.info("Accept a block claiming the correct subsidy in the coinbase transaction")
self.move_tip(65)
b69 = self.next_block(69, additional_coinbase_value=10)
tx = self.create_and_sign_transaction(out[20], out[20].vout[0].nValue - 10)
tx = self.create_and_sign_transaction(out[20], out[20].vout[0].nValue.getAmount() - 10)
self.update_block(69, [tx])
self.sync_blocks([b69], True)
self.save_spendable_output()
@ -1113,9 +1118,9 @@ class FullBlockTest(BitcoinTestFramework):
b83 = self.next_block(83)
op_codes = [OP_IF, OP_INVALIDOPCODE, OP_ELSE, OP_TRUE, OP_ENDIF]
script = CScript(op_codes)
tx1 = self.create_and_sign_transaction(out[28], out[28].vout[0].nValue, script)
tx2 = self.create_and_sign_transaction(tx1, 0, CScript([OP_TRUE]))
tx1 = self.create_and_sign_transaction(out[28], out[28].vout[0].nValue.getAmount(), script)
# ELEMENTS: doesn't support 0 value for non-OP_RETURN
tx2 = self.create_and_sign_transaction(tx1, 1, CScript([OP_TRUE]))
tx2.vin[0].scriptSig = CScript([OP_FALSE])
tx2.rehash()
@ -1130,20 +1135,27 @@ class FullBlockTest(BitcoinTestFramework):
#
self.log.info("Test re-orging blocks with OP_RETURN in them")
b84 = self.next_block(84)
tx1 = self.create_tx(out[29], 0, 0, CScript([OP_RETURN]))
tx1.vout.append(CTxOut(0, CScript([OP_TRUE])))
tx1.vout.append(CTxOut(0, CScript([OP_TRUE])))
tx1.vout.append(CTxOut(0, CScript([OP_TRUE])))
tx1.vout.append(CTxOut(0, CScript([OP_TRUE])))
# ELEMENTS: doesn't support 0 value for non-OP_RETURN
tx1 = self.create_tx(out[29], 0, 1, CScript([OP_RETURN]))
tx1.vout.append(CTxOut(1, CScript([OP_TRUE])))
tx1.vout.append(CTxOut(1, CScript([OP_TRUE])))
tx1.vout.append(CTxOut(1, CScript([OP_TRUE])))
tx1.vout.append(CTxOut(1, CScript([OP_TRUE])))
self.update_fee(tx1, out[29], 0)
tx1.calc_sha256()
self.sign_tx(tx1, out[29])
tx1.rehash()
tx2 = self.create_tx(tx1, 1, 0, CScript([OP_RETURN]))
tx2.vout.append(CTxOut(0, CScript([OP_RETURN])))
self.update_fee(tx2, tx1, 1)
tx3 = self.create_tx(tx1, 2, 0, CScript([OP_RETURN]))
tx3.vout.append(CTxOut(0, CScript([OP_TRUE])))
tx4 = self.create_tx(tx1, 3, 0, CScript([OP_TRUE]))
# ELEMENTS: doesn't support 0 value for non-OP_RETURN
tx3.vout.append(CTxOut(1, CScript([OP_TRUE])))
self.update_fee(tx3, tx1, 2)
# ELEMENTS: doesn't support 0 value for non-OP_RETURN
tx4 = self.create_tx(tx1, 3, 1, CScript([OP_TRUE]))
tx4.vout.append(CTxOut(0, CScript([OP_RETURN])))
self.update_fee(tx4, tx1, 3)
tx5 = self.create_tx(tx1, 4, 0, CScript([OP_RETURN]))
b84 = self.update_block(84, [tx1, tx2, tx3, tx4, tx5])
@ -1168,7 +1180,8 @@ class FullBlockTest(BitcoinTestFramework):
# trying to spend the OP_RETURN output is rejected
b89a = self.next_block("89a", spend=out[32])
tx = self.create_tx(tx1, 0, 0, CScript([OP_TRUE]))
# ELEMENTS: doesn't support 0 value for non-OP_RETURN
tx = self.create_tx(tx1, 0, 1, CScript([OP_TRUE]))
b89a = self.update_block("89a", [tx])
self.sync_blocks([b89a], success=False, reject_reason='bad-txns-inputs-missingorspent', reconnect=True)
@ -1181,12 +1194,13 @@ class FullBlockTest(BitcoinTestFramework):
for i in range(89, LARGE_REORG_SIZE + 89):
b = self.next_block(i, spend)
tx = CTransaction()
# ELEMENTS: mysterious off-by-one
#script_length = MAX_BLOCK_BASE_SIZE - len(b.serialize()) - 69
script_length = MAX_BLOCK_BASE_SIZE - len(b.serialize()) - 70
script_output = CScript([b'\x00' * script_length])
script_length = MAX_BLOCK_BASE_SIZE - len(b.serialize()) - 149
# ELEMENTS: doesn't support 0 value for non-OP_RETURN
script_output = CScript([OP_RETURN, b'\x00' * (script_length-1)])
tx.vout.append(CTxOut(0, script_output))
tx.vin.append(CTxIn(COutPoint(b.vtx[1].sha256, 0)))
self.update_fee(tx, b.vtx[1], 0)
b = self.update_block(i, [tx])
assert_equal(len(b.serialize()), MAX_BLOCK_BASE_SIZE)
blocks.append(b)
@ -1223,7 +1237,21 @@ class FullBlockTest(BitcoinTestFramework):
# this is a little handier to use than the version in blocktools.py
def create_tx(self, spend_tx, n, value, script=CScript([OP_TRUE, OP_DROP] * 15 + [OP_TRUE])):
return create_tx_with_script(spend_tx, n, amount=value, script_pub_key=script)
fee = spend_tx.vout[n].nValue.getAmount() - value
return create_tx_with_script(spend_tx, n, amount=value, fee=fee, script_pub_key=script)
# update the fee output amount and also move it to the end
def update_fee(self, tx, prev_tx, prev_n):
total_out = 0
for i in reversed(range(len(tx.vout))):
if tx.vout[i].is_fee():
del tx.vout[i]
else:
total_out += tx.vout[i].nValue.getAmount()
fee = prev_tx.vout[prev_n].nValue.getAmount() - total_out
if fee > 0:
tx.vout.append(CTxOut(fee))
tx.calc_sha256()
# sign a transaction, using the key we know about
# this signs input 0 in tx, which is assumed to be spending output n in spend_tx
@ -1251,12 +1279,12 @@ class FullBlockTest(BitcoinTestFramework):
# First create the coinbase
height = self.block_heights[base_block_hash] + 1
coinbase = create_coinbase(height, self.coinbase_pubkey)
coinbase.vout[0].nValue += additional_coinbase_value
coinbase.vout[0].nValue.setToAmount(coinbase.vout[0].nValue.getAmount() + additional_coinbase_value)
coinbase.rehash()
if spend is None:
block = create_block(base_block_hash, coinbase, block_time)
else:
coinbase.vout[0].nValue += spend.vout[0].nValue - 1 # all but one satoshi to fees
coinbase.vout[0].nValue.setToAmount(coinbase.vout[0].nValue.getAmount() + spend.vout[0].nValue.getAmount() - 1) # all but one satoshi to fees
coinbase.rehash()
block = create_block(base_block_hash, coinbase, block_time)
tx = self.create_tx(spend, 0, 1, script) # spend 1 satoshi

View file

@ -8,7 +8,7 @@ from binascii import b2a_hex
from decimal import Decimal
from test_framework.blocktools import create_coinbase
from test_framework.messages import CBlock, CProof
from test_framework.messages import CBlock, CProof, CTxOutValue
from test_framework.test_framework import BitcoinTestFramework
from test_framework.util import assert_equal
@ -27,7 +27,7 @@ class BlockSubsidyTest(BitcoinTestFramework):
self.num_nodes = 2
self.setup_clean_chain = True
# 10 satoshi block subsidy at start for one node, none for other
self.extra_args = [["-con_blocksubsidy=10"], ["-con_blocksubsidy=0"]]
self.extra_args = [["-con_blocksubsidy=10"], ["-con_blocksubsidy=0", "-txindex=1"]]
def run_test(self):
@ -74,24 +74,24 @@ class BlockSubsidyTest(BitcoinTestFramework):
assert_template(self.nodes[0], block, "bad-cb-amount")
# Set to proper value, resubmit
block.vtx[0].vout[0].nValue = 10
block.vtx[0].vout[0].nValue = CTxOutValue(10)
block.vtx[0].sha256 = None
assert_template(self.nodes[0], block, None)
# No subsidy also allowed
block.vtx[0].vout[0].nValue = 0
block.vtx[0].vout[0].nValue = CTxOutValue(0)
block.vtx[0].sha256 = None
assert_template(self.nodes[0], block, None)
#assert_template(self.nodes[0], block, None) # ELEMENTS: 0-value outputs not allowed
# Change previous blockhash to other nodes' genesis block and reward to 1, test again
block.hashPrevBlock = int(self.nodes[1].getblockhash(self.nodes[1].getblockcount()), 16)
block.vtx[0].vout[0].nValue = 1
block.vtx[0].vout[0].nValue = CTxOutValue(1)
block.vtx[0].sha256 = None
assert_template(self.nodes[1], block, "bad-cb-amount")
block.vtx[0].vout[0].nValue = 0
block.vtx[0].vout[0].nValue = CTxOutValue(0)
block.vtx[0].sha256 = None
assert_template(self.nodes[1], block, None)
#assert_template(self.nodes[1], block, None) # ELEMENTS: 0-value outputs not allowed
if __name__ == '__main__':
BlockSubsidyTest().main()

View file

@ -50,6 +50,7 @@ class BlockV4Test(BitcoinTestFramework):
# Generate 100 blocks so that first coinbase matures
generated_blocks = self.nodes[0].generate(100)
spendable_coinbase_txid = self.nodes[0].getblock(generated_blocks[0])['tx'][0]
coinbase_value = self.nodes[0].decoderawtransaction(self.nodes[0].gettransaction(spendable_coinbase_txid)["hex"])["vout"][0]["value"]
tip = generated_blocks[-1]
# Construct a v4 block
@ -59,7 +60,7 @@ class BlockV4Test(BitcoinTestFramework):
# Create a CLTV transaction
spendtx = create_transaction(self.nodes[0], spendable_coinbase_txid,
self.nodeaddress, amount=1.0)
self.nodeaddress, amount=1.0, fee=coinbase_value-1)
spendtx = cltv_validate(self.nodes[0], spendtx, 1)
spendtx.rehash()

View file

@ -95,6 +95,7 @@ class BlockSignTest(BitcoinTestFramework):
# Make a few transactions to make non-empty blocks for compact transmission
if make_transactions:
print(mineridx)
for i in range(5):
miner.sendtoaddress(miner_next.getnewaddress(), int(miner.getbalance()['bitcoin']/10), "", "", True)
# miner makes a block

View file

@ -74,8 +74,9 @@ class BIP65Test(BitcoinTestFramework):
self.log.info("Test that an invalid-according-to-CLTV transaction can still appear in a block")
coinbase_value = self.nodes[0].decoderawtransaction(self.nodes[0].gettransaction(self.coinbase_txids[0])["hex"])["vout"][0]["value"]
spendtx = create_transaction(self.nodes[0], self.coinbase_txids[0],
self.nodeaddress, amount=1.0)
self.nodeaddress, amount=1.0, fee=coinbase_value-1)
cltv_invalidate(spendtx)
spendtx.rehash()
@ -105,8 +106,9 @@ class BIP65Test(BitcoinTestFramework):
self.log.info("Test that invalid-according-to-cltv transactions cannot appear in a block")
block.nVersion = 4
coinbase_value = self.nodes[0].decoderawtransaction(self.nodes[0].gettransaction(self.coinbase_txids[1])["hex"])["vout"][0]["value"]
spendtx = create_transaction(self.nodes[0], self.coinbase_txids[1],
self.nodeaddress, amount=1.0)
self.nodeaddress, amount=1.0, fee=coinbase_value-1)
cltv_invalidate(spendtx)
spendtx.rehash()

View file

@ -94,14 +94,14 @@ def sign_transaction(node, unsignedtx):
return tx
def create_bip112special(node, input, txversion, address):
tx = create_transaction(node, input, address, amount=Decimal("49.98"))
tx = create_transaction(node, input, address, amount=Decimal("49.98"), fee=Decimal("0.02"))
tx.nVersion = txversion
signtx = sign_transaction(node, tx)
signtx.vin[0].scriptSig = CScript([-1, OP_CHECKSEQUENCEVERIFY, OP_DROP] + list(CScript(signtx.vin[0].scriptSig)))
return signtx
def send_generic_input_tx(node, coinbases, address):
return node.sendrawtransaction(ToHex(sign_transaction(node, create_transaction(node, node.getblock(coinbases.pop())['tx'][0], address, amount=Decimal("49.99")))))
return node.sendrawtransaction(ToHex(sign_transaction(node, create_transaction(node, node.getblock(coinbases.pop())['tx'][0], address, amount=Decimal("49.99"), fee=Decimal("0.01")))))
def create_bip68txs(node, bip68inputs, txversion, address, locktime_delta=0):
"""Returns a list of bip68 transactions with different bits set."""
@ -109,7 +109,7 @@ def create_bip68txs(node, bip68inputs, txversion, address, locktime_delta=0):
assert(len(bip68inputs) >= 16)
for i, (sdf, srhb, stf, srlb) in enumerate(product(*[[True, False]] * 4)):
locktime = relative_locktime(sdf, srhb, stf, srlb)
tx = create_transaction(node, bip68inputs[i], address, amount=Decimal("49.98"))
tx = create_transaction(node, bip68inputs[i], address, amount=Decimal("49.98"), fee=Decimal("0.02"))
tx.nVersion = txversion
tx.vin[0].nSequence = locktime + locktime_delta
tx = sign_transaction(node, tx)
@ -124,7 +124,7 @@ def create_bip112txs(node, bip112inputs, varyOP_CSV, txversion, address, locktim
assert(len(bip112inputs) >= 16)
for i, (sdf, srhb, stf, srlb) in enumerate(product(*[[True, False]] * 4)):
locktime = relative_locktime(sdf, srhb, stf, srlb)
tx = create_transaction(node, bip112inputs[i], address, amount=Decimal("49.98"))
tx = create_transaction(node, bip112inputs[i], address, amount=Decimal("49.98"), fee=Decimal("0.02"))
if (varyOP_CSV): # if varying OP_CSV, nSequence is fixed
tx.vin[0].nSequence = BASE_RELATIVE_LOCKTIME + locktime_delta
else: # vary nSequence instead, OP_CSV is fixed
@ -271,10 +271,10 @@ class BIP68_112_113Test(BitcoinTestFramework):
# Test both version 1 and version 2 transactions for all tests
# BIP113 test transaction will be modified before each use to put in appropriate block time
bip113tx_v1 = create_transaction(self.nodes[0], bip113input, self.nodeaddress, amount=Decimal("49.98"))
bip113tx_v1 = create_transaction(self.nodes[0], bip113input, self.nodeaddress, amount=Decimal("49.98"), fee=Decimal("0.02"))
bip113tx_v1.vin[0].nSequence = 0xFFFFFFFE
bip113tx_v1.nVersion = 1
bip113tx_v2 = create_transaction(self.nodes[0], bip113input, self.nodeaddress, amount=Decimal("49.98"))
bip113tx_v2 = create_transaction(self.nodes[0], bip113input, self.nodeaddress, amount=Decimal("49.98"), fee=Decimal("0.02"))
bip113tx_v2.vin[0].nSequence = 0xFFFFFFFE
bip113tx_v2.nVersion = 2

View file

@ -61,8 +61,9 @@ class BIP66Test(BitcoinTestFramework):
self.log.info("Test that a transaction with non-DER signature can still appear in a block")
coinbase_value = self.nodes[0].decoderawtransaction(self.nodes[0].gettransaction(self.coinbase_txids[0])["hex"])["vout"][0]["value"]
spendtx = create_transaction(self.nodes[0], self.coinbase_txids[0],
self.nodeaddress, amount=1.0)
self.nodeaddress, amount=1.0, fee=coinbase_value-1)
unDERify(spendtx)
spendtx.rehash()
@ -94,8 +95,9 @@ class BIP66Test(BitcoinTestFramework):
self.log.info("Test that transactions with non-DER signatures cannot appear in a block")
block.nVersion = 3
coinbase_value = self.nodes[0].decoderawtransaction(self.nodes[0].gettransaction(self.coinbase_txids[1])["hex"])["vout"][0]["value"]
spendtx = create_transaction(self.nodes[0], self.coinbase_txids[1],
self.nodeaddress, amount=1.0)
self.nodeaddress, amount=1.0, fee=coinbase_value-1)
unDERify(spendtx)
spendtx.rehash()
@ -124,7 +126,8 @@ class BIP66Test(BitcoinTestFramework):
assert b'Non-canonical DER signature' in self.nodes[0].p2p.last_message["reject"].reason
self.log.info("Test that a version 3 block with a DERSIG-compliant transaction is accepted")
block.vtx[1] = create_transaction(self.nodes[0], self.coinbase_txids[1], self.nodeaddress, amount=1.0)
coinbase_value = self.nodes[0].decoderawtransaction(self.nodes[0].gettransaction(self.coinbase_txids[1])["hex"])["vout"][0]["value"]
block.vtx[1] = create_transaction(self.nodes[0], self.coinbase_txids[1], self.nodeaddress, amount=1.0, fee=coinbase_value-1)
block.hashMerkleRoot = block.calc_merkle_root()
block.rehash()
block.solve()

View file

@ -11,6 +11,7 @@ from test_framework.util import (
rpc_port,
p2p_port,
)
from decimal import Decimal
def get_new_unconfidential_address(node):
addr = node.getnewaddress()
@ -64,9 +65,8 @@ class FedPegTest(BitcoinTestFramework):
connect_nodes_bi(self.nodes, 0, 1)
self.parentgenesisblockhash = self.nodes[0].getblockhash(0)
print('parentgenesisblockhash', self.parentgenesisblockhash)
#TODO(rebase) CA
#if not self.options.parent_bitcoin:
# parent_pegged_asset = self.nodes[0].getsidechaininfo()['pegged_asset']
if not self.options.parent_bitcoin:
parent_pegged_asset = self.nodes[0].getsidechaininfo()['pegged_asset']
# Setup sidechain nodes
self.fedpeg_script = "512103dff4923d778550cc13ce0d887d737553b4b58f4e8e886507fc39f5e447b2186451ae"
@ -89,14 +89,10 @@ class FedPegTest(BitcoinTestFramework):
]
if not self.options.parent_bitcoin:
extra_args.extend([
#TODO(rebase) should the defaults be put back to elements-specific ones?
#'-parentpubkeyprefix=235',
#'-parentscriptprefix=75',
'-parentpubkeyprefix=111',
'-parentscriptprefix=196',
'-con_parent_chain_signblockscript=51',
#TODO(rebase) CA
#'-con_parent_pegged_asset=%s' % parent_pegged_asset,
'-con_parent_pegged_asset=%s' % parent_pegged_asset,
])
# Use rpcuser auth only for first parent.
@ -222,14 +218,13 @@ class FedPegTest(BitcoinTestFramework):
decoded = sidechain.decoderawtransaction(tx1["hex"])
assert decoded["vin"][0]["is_pegin"] == True
assert len(decoded["vin"][0]["pegin_witness"]) > 0
#TODO(rebase) CT assert fee here too
# Check that there's sufficient fee for the peg-in
#vsize = decoded["vsize"]
#fee_output = decoded["vout"][1]
#fallbackfee_pervbyte = Decimal("0.00001")/Decimal("1000")
#print("fee_output", fee_output)
#assert fee_output["scriptPubKey"]["type"] == "fee"
#assert fee_output["value"] >= fallbackfee_pervbyte*vsize
vsize = decoded["vsize"]
fee_output = decoded["vout"][1]
fallbackfee_pervbyte = Decimal("0.00001")/Decimal("1000")
print("fee_output", fee_output)
assert fee_output["scriptPubKey"]["type"] == "fee"
assert fee_output["value"] >= fallbackfee_pervbyte*vsize
# Quick reorg checks of pegs
sidechain.invalidateblock(blockhash[0])
@ -331,7 +326,7 @@ class FedPegTest(BitcoinTestFramework):
break
assert pegout_tested
print ("Now test failure to validate peg-ins based on intermittent bitcoind rpc failure")
print("Now test failure to validate peg-ins based on intermittent bitcoind rpc failure")
self.stop_node(1)
txid = parent.sendtoaddress(addr, 1)
parent.generate(12)
@ -357,57 +352,47 @@ class FedPegTest(BitcoinTestFramework):
print("Completed!\n")
print("Now send funds out in two stages, partial, and full")
some_btc_addr = get_new_unconfidential_address(parent)
#TODO(rebase) CA bitcoin balances
#bal_1 = sidechain.getwalletinfo()["balance"]["bitcoin"]
bal_1 = sidechain.getwalletinfo()["balance"]
bal_1 = sidechain.getwalletinfo()["balance"]['bitcoin']
try:
sidechain.sendtomainchain(some_btc_addr, bal_1 + 1)
raise Exception("Sending out too much; should have failed")
except JSONRPCException as e:
assert("Insufficient funds" in e.error["message"])
#assert(sidechain.getwalletinfo()["balance"]["bitcoin"] == bal_1)
assert(sidechain.getwalletinfo()["balance"] == bal_1)
assert(sidechain.getwalletinfo()["balance"]["bitcoin"] == bal_1)
try:
sidechain.sendtomainchain(some_btc_addr+"b", bal_1 - 1)
raise Exception("Sending to invalid address; should have failed")
except JSONRPCException as e:
assert("Invalid Bitcoin address" in e.error["message"])
#assert(sidechain.getwalletinfo()["balance"]["bitcoin"] == bal_1)
assert(sidechain.getwalletinfo()["balance"] == bal_1)
assert(sidechain.getwalletinfo()["balance"]["bitcoin"] == bal_1)
try:
sidechain.sendtomainchain("1Nro9WkpaKm9axmcfPVp79dAJU1Gx7VmMZ", bal_1 - 1)
raise Exception("Sending to mainchain address when should have been testnet; should have failed")
except JSONRPCException as e:
assert("Invalid Bitcoin address" in e.error["message"])
#assert(sidechain.getwalletinfo()["balance"]["bitcoin"] == bal_1)
assert(sidechain.getwalletinfo()["balance"] == bal_1)
assert(sidechain.getwalletinfo()["balance"]["bitcoin"] == bal_1)
peg_out_txid = sidechain.sendtomainchain(some_btc_addr, 1)
peg_out_details = sidechain.decoderawtransaction(sidechain.getrawtransaction(peg_out_txid))
# peg-out, change
#TODO(rebase) CA/CT fee output
#assert(len(peg_out_details["vout"]) == 3)
assert(len(peg_out_details["vout"]) == 2)
# peg-out, change, fee
assert(len(peg_out_details["vout"]) == 3)
found_pegout_value = False
for output in peg_out_details["vout"]:
if "value" in output and output["value"] == 1:
found_pegout_value = True
assert(found_pegout_value)
#bal_2 = sidechain.getwalletinfo()["balance"]["bitcoin"]
bal_2 = sidechain.getwalletinfo()["balance"]
bal_2 = sidechain.getwalletinfo()["balance"]["bitcoin"]
# Make sure balance went down
assert(bal_2 + 1 < bal_1)
sidechain.sendtomainchain(some_btc_addr, bal_2, True)
#TODO(rebase) CA bitcoin balance
#assert("bitcoin" not in sidechain.getwalletinfo()["balance"])
assert(sidechain.getwalletinfo()["balance"] == 0)
assert(sidechain.getwalletinfo()["balance"]['bitcoin'] == 0)
print('Success!')

View file

@ -61,6 +61,7 @@ def small_txpuzzle_randfee(from_node, conflist, unconflist, amount, min_fee, fee
raise RuntimeError("Insufficient funds: need %d, have %d" % (amount + fee, total_in))
tx.vout.append(CTxOut(int((total_in - amount - fee) * COIN), P2SH_1))
tx.vout.append(CTxOut(int(amount * COIN), P2SH_2))
tx.vout.append(CTxOut(int(fee*COIN))) # fee
# These transactions don't need to be signed, but we still have to insert
# the ScriptSig that will satisfy the ScriptPubKey.
for inp in tx.vin:
@ -87,6 +88,7 @@ def split_inputs(from_node, txins, txouts, initial_split=False):
rem_change = prevtxout["amount"] - half_change - Decimal("0.00001000")
tx.vout.append(CTxOut(int(half_change * COIN), P2SH_1))
tx.vout.append(CTxOut(int(rem_change * COIN), P2SH_2))
tx.vout.append(CTxOut(int(0.00001*COIN))) # fee
# If this is the initial split we actually need to sign the transaction
# Otherwise we just need to insert the proper ScriptSig
@ -153,13 +155,15 @@ class EstimateFeeTest(BitcoinTestFramework):
# resorting to tx's that depend on the mempool when those run out
for i in range(numblocks):
random.shuffle(self.confutxo)
for j in range(random.randrange(100 - 50, 100 + 50)):
# ELEMENTS: make fewer txns since larger: ~236 bytes: 69k/4/234=~73
# Pick a number smaller than that, stingy miner is even stingier
for j in range(random.randrange(55 - 15, 55 + 15)):
from_index = random.randint(1, 2)
(txhex, fee) = small_txpuzzle_randfee(self.nodes[from_index], self.confutxo,
self.memutxo, Decimal("0.005"), min_fee, min_fee)
tx_kbytes = (len(txhex) // 2) / 1000.0
self.fees_per_kb.append(float(fee) / tx_kbytes)
sync_mempools(self.nodes[0:3], wait=.1)
sync_mempools(self.nodes[0:3], wait=10, timeout=240) # Slower to sync than btc
mined = mining_node.getblock(mining_node.generate(1)[0], True)["tx"]
sync_blocks(self.nodes[0:3], wait=.1)
# update which txouts are confirmed

View file

@ -7,7 +7,8 @@
from binascii import b2a_hex
from test_framework.blocktools import create_coinbase
from test_framework.messages import CBlock, CProof
from test_framework.messages import CBlock, CProof, CTxOutValue, CTxOut
from test_framework.script import CScript, OP_RETURN
from test_framework.test_framework import BitcoinTestFramework
from test_framework.util import assert_equal, assert_raises_rpc_error
@ -72,11 +73,38 @@ class MandatoryCoinbaseTest(BitcoinTestFramework):
self.log.info("getblocktemplate: Test non-subsidy block on both nodes")
# Without block reward anything goes, this allows commitment outputs like segwit
coinbase_tx.vout[0].nValue = 0
coinbase_tx.vout[0].nValue = CTxOutValue(0)
coinbase_tx.vout[0].scriptPubKey = CScript([OP_RETURN, b'\xff'])
coinbase_tx.rehash()
block.vtx = [coinbase_tx]
assert_template(node0, block, None)
assert_template(node1, block, None)
#
# Also test that coinbases can't have fees.
self.sync_all()
tmpl = node1.getblocktemplate()
coinbase_tx = create_coinbase(height=int(tmpl["height"]))
# sequence numbers must not be max for nLockTime to have effect
coinbase_tx.vin[0].nSequence = 2 ** 32 - 2
# Add fee output.
coinbase_tx.vout[0].nValue.setToAmount(coinbase_tx.vout[0].nValue.getAmount() - 1)
coinbase_tx.vout.append(CTxOut(1))
coinbase_tx.rehash()
block = CBlock()
block.nVersion = tmpl["version"]
block.hashPrevBlock = int(tmpl["previousblockhash"], 16)
block.nTime = tmpl["curtime"]
block.nBits = int(tmpl["bits"], 16)
block.nNonce = 0
block.proof = CProof(bytearray.fromhex('51'))
block.vtx = [coinbase_tx]
block.block_height = int(tmpl["height"])
block.hashMerkleRoot = block.calc_merkle_root()
# should not be accepted
assert_template(node0, block, "bad-cb-fee")
assert_template(node1, block, "bad-cb-fee")
if __name__ == '__main__':
MandatoryCoinbaseTest().main()

View file

@ -66,16 +66,18 @@ class NULLDUMMYTest(BitcoinTestFramework):
self.lastblocktime = int(time.time()) + 429
self.log.info("Test 1: NULLDUMMY compliant base transactions should be accepted to mempool and mined before activation [430]")
test1txs = [create_transaction(self.nodes[0], coinbase_txid[0], self.ms_address, amount=49)]
coinbase_value = self.nodes[0].decoderawtransaction(self.nodes[0].gettransaction(coinbase_txid[0])["hex"])["vout"][0]["value"]
test1txs = [create_transaction(self.nodes[0], coinbase_txid[0], self.ms_address, amount=49, fee=coinbase_value-49)]
txid1 = self.nodes[0].sendrawtransaction(bytes_to_hex_str(test1txs[0].serialize_with_witness()), True)
test1txs.append(create_transaction(self.nodes[0], txid1, self.ms_address, amount=48))
test1txs.append(create_transaction(self.nodes[0], txid1, self.ms_address, amount=48, fee=49-48))
txid2 = self.nodes[0].sendrawtransaction(bytes_to_hex_str(test1txs[1].serialize_with_witness()), True)
test1txs.append(create_transaction(self.nodes[0], coinbase_txid[1], self.wit_ms_address, amount=49))
coinbase_value = self.nodes[0].decoderawtransaction(self.nodes[0].gettransaction(coinbase_txid[1])["hex"])["vout"][0]["value"]
test1txs.append(create_transaction(self.nodes[0], coinbase_txid[1], self.wit_ms_address, amount=49, fee=coinbase_value-49))
txid3 = self.nodes[0].sendrawtransaction(bytes_to_hex_str(test1txs[2].serialize_with_witness()), True)
self.block_submit(self.nodes[0], test1txs, False, True)
self.log.info("Test 2: Non-NULLDUMMY base multisig transaction should not be accepted to mempool before activation")
test2tx = create_transaction(self.nodes[0], txid2, self.ms_address, amount=47)
test2tx = create_transaction(self.nodes[0], txid2, self.ms_address, amount=47, fee=48-47)
trueDummy(test2tx)
assert_raises_rpc_error(-26, NULLDUMMY_ERROR, self.nodes[0].sendrawtransaction, bytes_to_hex_str(test2tx.serialize_with_witness()), True)
@ -83,14 +85,14 @@ class NULLDUMMYTest(BitcoinTestFramework):
self.block_submit(self.nodes[0], [test2tx], False, True)
self.log.info("Test 4: Non-NULLDUMMY base multisig transaction is invalid after activation")
test4tx = create_transaction(self.nodes[0], test2tx.hash, self.address, amount=46)
test4tx = create_transaction(self.nodes[0], test2tx.hash, self.address, amount=46, fee=47-46)
test6txs=[CTransaction(test4tx)]
trueDummy(test4tx)
assert_raises_rpc_error(-26, NULLDUMMY_ERROR, self.nodes[0].sendrawtransaction, bytes_to_hex_str(test4tx.serialize_with_witness()), True)
self.block_submit(self.nodes[0], [test4tx])
self.log.info("Test 5: Non-NULLDUMMY P2WSH multisig transaction invalid after activation")
test5tx = create_transaction(self.nodes[0], txid3, self.wit_address, amount=48)
test5tx = create_transaction(self.nodes[0], txid3, self.wit_address, amount=48, fee=49-48)
test6txs.append(CTransaction(test5tx))
test5tx.wit.vtxinwit[0].scriptWitness.stack[0] = b'\x01'
assert_raises_rpc_error(-26, NULLDUMMY_ERROR, self.nodes[0].sendrawtransaction, bytes_to_hex_str(test5tx.serialize_with_witness()), True)

View file

@ -31,13 +31,16 @@ def make_utxo(node, amount, confirmed=True, scriptPubKey=CScript([1])):
node.generate(100)
new_addr = node.getnewaddress()
unblinded_addr = node.validateaddress(new_addr)["unconfidential"]
txidstr = node.sendtoaddress(new_addr, satoshi_round((amount+fee)/COIN))
tx1 = node.getrawtransaction(txidstr, 1)
txid = int(txidstr, 16)
i = None
for i, txout in enumerate(tx1['vout']):
if txout['scriptPubKey']['addresses'] == [new_addr]:
if txout['scriptPubKey']['type'] == "fee":
continue # skip fee outputs
if txout['scriptPubKey']['addresses'] == [unblinded_addr]:
break
assert i is not None

View file

@ -566,10 +566,14 @@ class SegWitTest(BitcoinTestFramework):
for use_p2wsh in [False, True]:
if use_p2wsh:
scriptPubKey = "00203a59f3f56b713fdcf5d1a57357f02c44342cbf306ffe0c4741046837bf90561a"
transaction = "0100000000000100e1f505000000002200203a59f3f56b713fdcf5d1a57357f02c44342cbf306ffe0c4741046837bf90561a00000000"
# original btc tx:
# 01000000000100e1f505000000002200203a59f3f56b713fdcf5d1a57357f02c44342cbf306ffe0c4741046837bf90561a00000000
transaction = "0100000000000101ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe0010000000005f5e100002200203a59f3f56b713fdcf5d1a57357f02c44342cbf306ffe0c4741046837bf90561a00000000"
else:
scriptPubKey = "a9142f8c469c2f0084c48e11f998ffbe7efa7549f26d87"
transaction = "0100000000000100e1f5050000000017a9142f8c469c2f0084c48e11f998ffbe7efa7549f26d8700000000"
# original btc tx:
# 01000000000100e1f5050000000017a9142f8c469c2f0084c48e11f998ffbe7efa7549f26d8700000000
transaction = "0100000000000101ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe0010000000005f5e1000017a9142f8c469c2f0084c48e11f998ffbe7efa7549f26d8700000000"
self.nodes[1].importaddress(scriptPubKey, "", False)
rawtxfund = self.nodes[1].fundrawtransaction(transaction)['hex']

View file

@ -29,7 +29,7 @@ class TxWitnessTest(BitcoinTestFramework):
def assert_tx_format_also_signed(self, utxo, segwit):
raw = self.nodes[0].createrawtransaction(
[{"txid": utxo["txid"], "vout": utxo["vout"]}],
[{self.unknown_addr: "49.9"}]
[{self.unknown_addr: "49.9"}, {"fee": "0.1"}]
)
unsigned_decoded = self.nodes[0].decoderawtransaction(raw)
@ -40,6 +40,8 @@ class TxWitnessTest(BitcoinTestFramework):
tx = CTransaction()
tx.deserialize(BytesIO(hex_str_to_bytes(raw)))
assert_equal(tx.vin[0].prevout.hash, int("0x"+utxo["txid"], 0))
assert_equal(len(tx.vin), len(unsigned_decoded["vin"]))
assert_equal(len(tx.vout), len(unsigned_decoded["vout"]))
# assert re-encoding
serialized = bytes_to_hex_str(tx.serialize())
assert_equal(serialized, raw)
@ -73,7 +75,7 @@ class TxWitnessTest(BitcoinTestFramework):
assert_equal(nodetx["hash"], wtxid)
# witness hash stuff
assert_equal(nodetx["withash"], bytes_to_hex_str(ser_uint256(tx.calc_witness_hash())[::-1]))
assert_equal(nodetx["withash"], tx.calc_witness_hash())
return (txid, wtxid)
def test_transaction_serialization(self):

View file

@ -5,6 +5,7 @@
"""Test mempool acceptance of raw transactions."""
from io import BytesIO
from decimal import Decimal
from test_framework.test_framework import BitcoinTestFramework
from test_framework.messages import (
BIP125_SEQUENCE_NUMBER,
@ -12,6 +13,7 @@ from test_framework.messages import (
COutPoint,
CTransaction,
CTxOut,
CTxOutValue,
MAX_BLOCK_BASE_SIZE,
)
from test_framework.script import (
@ -66,7 +68,7 @@ class MempoolAcceptanceTest(BitcoinTestFramework):
coin = node.listunspent()[0] # Pick a random coin(base) to spend
raw_tx_in_block = node.signrawtransactionwithwallet(node.createrawtransaction(
inputs=[{'txid': coin['txid'], 'vout': coin['vout']}],
outputs=[{node.getnewaddress(): 0.3}, {node.getnewaddress(): 49}],
outputs=[{node.getnewaddress(): 0.3}, {node.getnewaddress(): 49}, {"fee": coin["amount"] - Decimal('49.3')}],
))['hex']
txid_in_block = node.sendrawtransaction(hexstring=raw_tx_in_block, allowhighfees=True)
node.generate(1)
@ -79,7 +81,7 @@ class MempoolAcceptanceTest(BitcoinTestFramework):
fee = 0.00000700
raw_tx_0 = node.signrawtransactionwithwallet(node.createrawtransaction(
inputs=[{"txid": txid_in_block, "vout": 0, "sequence": BIP125_SEQUENCE_NUMBER}], # RBF is used later
outputs=[{node.getnewaddress(): 0.3 - fee}],
outputs=[{node.getnewaddress(): 0.3 - fee}, {"fee": fee}],
))['hex']
tx = CTransaction()
tx.deserialize(BytesIO(hex_str_to_bytes(raw_tx_0)))
@ -99,7 +101,9 @@ class MempoolAcceptanceTest(BitcoinTestFramework):
self.log.info('A transaction that replaces a mempool transaction')
tx.deserialize(BytesIO(hex_str_to_bytes(raw_tx_0)))
tx.vout[0].nValue -= int(fee * COIN) # Double the fee
tx.vout[0].nValue.setToAmount(tx.vout[0].nValue.getAmount() - int(fee * COIN)) # Double the fee
txid_0_out = tx.vout[0].nValue.getAmount()
tx.vout[1].nValue.setToAmount(tx.vout[1].nValue.getAmount() + int(fee * COIN))
tx.vin[0].nSequence = BIP125_SEQUENCE_NUMBER + 1 # Now, opt out of RBF
raw_tx_0 = node.signrawtransactionwithwallet(bytes_to_hex_str(tx.serialize()))['hex']
tx.deserialize(BytesIO(hex_str_to_bytes(raw_tx_0)))
@ -114,7 +118,8 @@ class MempoolAcceptanceTest(BitcoinTestFramework):
node.sendrawtransaction(hexstring=bytes_to_hex_str(tx.serialize()), allowhighfees=True)
# take original raw_tx_0
tx.deserialize(BytesIO(hex_str_to_bytes(raw_tx_0)))
tx.vout[0].nValue -= int(4 * fee * COIN) # Set more fee
tx.vout[0].nValue.setToAmount(tx.vout[0].nValue.getAmount() - int(4 * fee * COIN)) # Set more fee
tx.vout[1].nValue.setToAmount(tx.vout[1].nValue.getAmount() + int(4 * fee * COIN))
# skip re-signing the tx
self.check_mempool_result(
result_expected=[{'txid': tx.rehash(), 'allowed': False, 'reject-reason': '18: txn-mempool-conflict'}],
@ -134,6 +139,8 @@ class MempoolAcceptanceTest(BitcoinTestFramework):
self.log.info('A transaction with missing inputs, that existed once in the past')
tx.deserialize(BytesIO(hex_str_to_bytes(raw_tx_0)))
tx.vin[0].prevout.n = 1 # Set vout to 1, to spend the other outpoint (49 coins) of the in-chain-tx we want to double spend
tx.vout[1].nValue.setToAmount(49*COIN - tx.vout[0].nValue.getAmount()) # fee
txid_1_out = tx.vout[0].nValue.getAmount()
raw_tx_1 = node.signrawtransactionwithwallet(bytes_to_hex_str(tx.serialize()))['hex']
txid_1 = node.sendrawtransaction(hexstring=raw_tx_1, allowhighfees=True)
# Now spend both to "clearly hide" the outputs, ie. remove the coins from the utxo set by spending them
@ -142,7 +149,7 @@ class MempoolAcceptanceTest(BitcoinTestFramework):
{'txid': txid_0, 'vout': 0},
{'txid': txid_1, 'vout': 0},
],
outputs=[{node.getnewaddress(): 0.1}]
outputs=[{node.getnewaddress(): 0.1}, {"fee": Decimal(txid_0_out + txid_1_out)/Decimal(COIN) - Decimal('0.1')}]
))['hex']
txid_spend_both = node.sendrawtransaction(hexstring=raw_tx_spend_both, allowhighfees=True)
node.generate(1)
@ -160,7 +167,7 @@ class MempoolAcceptanceTest(BitcoinTestFramework):
self.log.info('Create a signed "reference" tx for later use')
raw_tx_reference = node.signrawtransactionwithwallet(node.createrawtransaction(
inputs=[{'txid': txid_spend_both, 'vout': 0}],
outputs=[{node.getnewaddress(): 0.05}],
outputs=[{node.getnewaddress(): 0.05}, {"fee": Decimal('0.1') - Decimal('0.05')}],
))['hex']
tx.deserialize(BytesIO(hex_str_to_bytes(raw_tx_reference)))
# Reference tx should be valid on itself
@ -189,7 +196,7 @@ class MempoolAcceptanceTest(BitcoinTestFramework):
self.log.info('A transaction with negative output value')
tx.deserialize(BytesIO(hex_str_to_bytes(raw_tx_reference)))
tx.vout[0].nValue *= -1
tx.vout[0].nValue.setToAmount(tx.vout[0].nValue.getAmount() * -1)
self.check_mempool_result(
result_expected=[{'txid': tx.rehash(), 'allowed': False, 'reject-reason': '16: bad-txns-vout-negative'}],
rawtxs=[bytes_to_hex_str(tx.serialize())],
@ -197,7 +204,7 @@ class MempoolAcceptanceTest(BitcoinTestFramework):
self.log.info('A transaction with too large output value')
tx.deserialize(BytesIO(hex_str_to_bytes(raw_tx_reference)))
tx.vout[0].nValue = 21000000 * COIN + 1
tx.vout[0].nValue = CTxOutValue(21000000 * COIN + 1)
self.check_mempool_result(
result_expected=[{'txid': tx.rehash(), 'allowed': False, 'reject-reason': '16: bad-txns-vout-toolarge'}],
rawtxs=[bytes_to_hex_str(tx.serialize())],
@ -206,7 +213,7 @@ class MempoolAcceptanceTest(BitcoinTestFramework):
self.log.info('A transaction with too large sum of output values')
tx.deserialize(BytesIO(hex_str_to_bytes(raw_tx_reference)))
tx.vout = [tx.vout[0]] * 2
tx.vout[0].nValue = 21000000 * COIN
tx.vout[0].nValue = CTxOutValue(21000000 * COIN)
self.check_mempool_result(
result_expected=[{'txid': tx.rehash(), 'allowed': False, 'reject-reason': '16: bad-txns-txouttotal-toolarge'}],
rawtxs=[bytes_to_hex_str(tx.serialize())],
@ -258,7 +265,7 @@ class MempoolAcceptanceTest(BitcoinTestFramework):
)
tx.deserialize(BytesIO(hex_str_to_bytes(raw_tx_reference)))
tx.vout[0] = output_p2sh_burn
tx.vout[0].nValue -= 1 # Make output smaller, such that it is dust for our policy
tx.vout[0].nValue.setToAmount(tx.vout[0].nValue.getAmount() - 1) # Make output smaller, such that it is dust for our policy
self.check_mempool_result(
result_expected=[{'txid': tx.rehash(), 'allowed': False, 'reject-reason': '64: dust'}],
rawtxs=[bytes_to_hex_str(tx.serialize())],

View file

@ -30,11 +30,12 @@ class MempoolPackagesTest(BitcoinTestFramework):
outputs = {}
for i in range(num_outputs):
outputs[node.getnewaddress()] = send_value
outputs["fee"] = fee
rawtx = node.createrawtransaction(inputs, outputs)
signedtx = node.signrawtransactionwithwallet(rawtx)
txid = node.sendrawtransaction(signedtx['hex'])
fulltx = node.getrawtransaction(txid, 1)
assert(len(fulltx['vout']) == num_outputs) # make sure we didn't generate a change output
assert(len(fulltx['vout']) == num_outputs + 1) # make sure we didn't generate a change output
return (txid, send_value)
def run_test(self):
@ -274,6 +275,7 @@ class MempoolPackagesTest(BitcoinTestFramework):
outputs = {}
for i in range(2):
outputs[self.nodes[0].getnewaddress()] = send_value
outputs["fee"] = fee
rawtx = self.nodes[0].createrawtransaction(inputs, outputs)
signedtx = self.nodes[0].signrawtransactionwithwallet(rawtx)
txid = self.nodes[0].sendrawtransaction(signedtx['hex'])
@ -298,6 +300,7 @@ class MempoolPackagesTest(BitcoinTestFramework):
# Now generate tx8, with a big fee
inputs = [ {'txid' : tx1_id, 'vout': 0}, {'txid' : txid, 'vout': 0} ]
outputs = { self.nodes[0].getnewaddress() : send_value + value - 4*fee }
outputs["fee"] = 3*fee
rawtx = self.nodes[0].createrawtransaction(inputs, outputs)
signedtx = self.nodes[0].signrawtransactionwithwallet(rawtx)
txid = self.nodes[0].sendrawtransaction(signedtx['hex'])

View file

@ -42,12 +42,12 @@ class MempoolCoinbaseTest(BitcoinTestFramework):
# and make sure the mempool code behaves correctly.
b = [ self.nodes[0].getblockhash(n) for n in range(101, 105) ]
coinbase_txids = [ self.nodes[0].getblock(h)['tx'][0] for h in b ]
spend_101_raw = create_raw_transaction(self.nodes[0], coinbase_txids[1], node1_address, amount=49.99)
spend_102_raw = create_raw_transaction(self.nodes[0], coinbase_txids[2], node0_address, amount=49.99)
spend_103_raw = create_raw_transaction(self.nodes[0], coinbase_txids[3], node0_address, amount=49.99)
spend_101_raw = create_raw_transaction(self.nodes[0], coinbase_txids[1], node1_address, amount=49.99, fee=0.01)
spend_102_raw = create_raw_transaction(self.nodes[0], coinbase_txids[2], node0_address, amount=49.99, fee=0.01)
spend_103_raw = create_raw_transaction(self.nodes[0], coinbase_txids[3], node0_address, amount=49.99, fee=0.01)
# Create a transaction which is time-locked to two blocks in the future
timelock_tx = self.nodes[0].createrawtransaction([{"txid": coinbase_txids[0], "vout": 0}], {node0_address: 49.99})
timelock_tx = self.nodes[0].createrawtransaction([{"txid": coinbase_txids[0], "vout": 0}], {node0_address: 49.99, "fee": 0.01})
# Set the time lock
timelock_tx = timelock_tx.replace("ffffffff", "11111191", 1)
timelock_tx = timelock_tx[:-8] + hex(self.nodes[0].getblockcount() + 2)[2:] + "000000"
@ -63,8 +63,8 @@ class MempoolCoinbaseTest(BitcoinTestFramework):
assert_raises_rpc_error(-26, 'non-final', self.nodes[0].sendrawtransaction, timelock_tx)
# Create 102_1 and 103_1:
spend_102_1_raw = create_raw_transaction(self.nodes[0], spend_102_id, node1_address, amount=49.98)
spend_103_1_raw = create_raw_transaction(self.nodes[0], spend_103_id, node1_address, amount=49.98)
spend_102_1_raw = create_raw_transaction(self.nodes[0], spend_102_id, node1_address, amount=49.98, fee=0.01)
spend_103_1_raw = create_raw_transaction(self.nodes[0], spend_103_id, node1_address, amount=49.98, fee=0.01)
# Broadcast and mine 103_1:
spend_103_1_id = self.nodes[0].sendrawtransaction(spend_103_1_raw)

View file

@ -30,13 +30,13 @@ class MempoolCoinbaseTest(BitcoinTestFramework):
b = [self.nodes[0].getblockhash(n) for n in range(1, 4)]
coinbase_txids = [self.nodes[0].getblock(h)['tx'][0] for h in b]
spends1_raw = [create_raw_transaction(self.nodes[0], txid, node0_address, amount=49.99) for txid in coinbase_txids]
spends1_raw = [create_raw_transaction(self.nodes[0], txid, node0_address, amount=49.99, fee=0.01) for txid in coinbase_txids]
spends1_id = [self.nodes[0].sendrawtransaction(tx) for tx in spends1_raw]
blocks = []
blocks.extend(self.nodes[0].generate(1))
spends2_raw = [create_raw_transaction(self.nodes[0], txid, node0_address, amount=49.98) for txid in spends1_id]
spends2_raw = [create_raw_transaction(self.nodes[0], txid, node0_address, amount=49.98, fee=0.01) for txid in spends1_id]
spends2_id = [self.nodes[0].sendrawtransaction(tx) for tx in spends2_raw]
blocks.extend(self.nodes[0].generate(1))

View file

@ -34,7 +34,7 @@ class MempoolSpendCoinbaseTest(BitcoinTestFramework):
# is too immature to spend.
b = [self.nodes[0].getblockhash(n) for n in range(101, 103)]
coinbase_txids = [self.nodes[0].getblock(h)['tx'][0] for h in b]
spends_raw = [create_raw_transaction(self.nodes[0], txid, node0_address, amount=49.99) for txid in coinbase_txids]
spends_raw = [create_raw_transaction(self.nodes[0], txid, node0_address, amount=49.99, fee=0.01) for txid in coinbase_txids]
spend_101_id = self.nodes[0].sendrawtransaction(spends_raw[0])

View file

@ -125,7 +125,7 @@ class CompactBlocksTest(BitcoinTestFramework):
assert(int(self.nodes[0].getbestblockhash(), 16) == block.sha256)
self.nodes[0].generate(100)
total_value = block.vtx[0].vout[0].nValue
total_value = block.vtx[0].vout[0].nValue.getAmount()
out_value = total_value // 10
tx = CTransaction()
tx.vin.append(CTxIn(COutPoint(block.vtx[0].sha256, 0), b''))
@ -432,8 +432,9 @@ class CompactBlocksTest(BitcoinTestFramework):
tx = CTransaction()
tx.vin.append(CTxIn(COutPoint(utxo[0], utxo[1]), b''))
tx.vout.append(CTxOut(utxo[2] - 1000, CScript([OP_TRUE, OP_DROP] * 15 + [OP_TRUE])))
tx.vout.append(CTxOut(1000)) # fee
tx.rehash()
utxo = [tx.sha256, 0, tx.vout[0].nValue]
utxo = [tx.sha256, 0, tx.vout[0].nValue.getAmount()]
block.vtx.append(tx)
block.hashMerkleRoot = block.calc_merkle_root()
@ -463,7 +464,7 @@ class CompactBlocksTest(BitcoinTestFramework):
utxo = self.utxos.pop(0)
block = self.build_block_with_transactions(node, utxo, 5)
self.utxos.append([block.vtx[-1].sha256, 0, block.vtx[-1].vout[0].nValue])
self.utxos.append([block.vtx[-1].sha256, 0, block.vtx[-1].vout[0].nValue.getAmount()])
comp_block = HeaderAndShortIDs()
comp_block.initialize_from_block(block, use_witness=with_witness)
@ -477,7 +478,7 @@ class CompactBlocksTest(BitcoinTestFramework):
utxo = self.utxos.pop(0)
block = self.build_block_with_transactions(node, utxo, 5)
self.utxos.append([block.vtx[-1].sha256, 0, block.vtx[-1].vout[0].nValue])
self.utxos.append([block.vtx[-1].sha256, 0, block.vtx[-1].vout[0].nValue.getAmount()])
# Now try interspersing the prefilled transactions
comp_block.initialize_from_block(block, prefill_list=[0, 1, 5], use_witness=with_witness)
@ -488,7 +489,7 @@ class CompactBlocksTest(BitcoinTestFramework):
# Now try giving one transaction ahead of time.
utxo = self.utxos.pop(0)
block = self.build_block_with_transactions(node, utxo, 5)
self.utxos.append([block.vtx[-1].sha256, 0, block.vtx[-1].vout[0].nValue])
self.utxos.append([block.vtx[-1].sha256, 0, block.vtx[-1].vout[0].nValue.getAmount()])
test_node.send_and_ping(msg_tx(block.vtx[1]))
assert(block.vtx[1].hash in node.getrawmempool())
@ -504,7 +505,7 @@ class CompactBlocksTest(BitcoinTestFramework):
# announced and verify reconstruction happens immediately.
utxo = self.utxos.pop(0)
block = self.build_block_with_transactions(node, utxo, 10)
self.utxos.append([block.vtx[-1].sha256, 0, block.vtx[-1].vout[0].nValue])
self.utxos.append([block.vtx[-1].sha256, 0, block.vtx[-1].vout[0].nValue.getAmount()])
for tx in block.vtx[1:]:
test_node.send_message(msg_tx(tx))
test_node.sync_with_ping()
@ -532,7 +533,7 @@ class CompactBlocksTest(BitcoinTestFramework):
utxo = self.utxos.pop(0)
block = self.build_block_with_transactions(node, utxo, 10)
self.utxos.append([block.vtx[-1].sha256, 0, block.vtx[-1].vout[0].nValue])
self.utxos.append([block.vtx[-1].sha256, 0, block.vtx[-1].vout[0].nValue.getAmount()])
# Relay the first 5 transactions from the block in advance
for tx in block.vtx[1:6]:
test_node.send_message(msg_tx(tx))
@ -773,7 +774,7 @@ class CompactBlocksTest(BitcoinTestFramework):
delivery_peer.send_and_ping(msg_cmpctblock(cmpct_block.to_p2p()))
assert_equal(int(node.getbestblockhash(), 16), block.sha256)
self.utxos.append([block.vtx[-1].sha256, 0, block.vtx[-1].vout[0].nValue])
self.utxos.append([block.vtx[-1].sha256, 0, block.vtx[-1].vout[0].nValue.getAmount()])
# Now test that delivering an invalid compact block won't break relay

View file

@ -13,7 +13,7 @@ re-requested.
import copy
from test_framework.blocktools import create_block, create_coinbase, create_tx_with_script
from test_framework.messages import COIN
from test_framework.messages import COIN, CTxOutValue
from test_framework.mininode import P2PDataStore
from test_framework.test_framework import BitcoinTestFramework
from test_framework.util import assert_equal
@ -98,7 +98,7 @@ class InvalidBlockRequestTest(BitcoinTestFramework):
block3 = create_block(tip, create_coinbase(height), block_time)
block_time += 1
block3.vtx[0].vout[0].nValue = 100 * COIN # Too high!
block3.vtx[0].vout[0].nValue = CTxOutValue(100 * COIN) # Too high!
block3.vtx[0].sha256 = None
block3.vtx[0].calc_sha256()
block3.hashMerkleRoot = block3.calc_merkle_root()

View file

@ -70,7 +70,7 @@ class InvalidTxRequestTest(BitcoinTestFramework):
# Transaction will be rejected with code 16 (REJECT_INVALID)
# and we get disconnected immediately
self.log.info('Test a transaction that is rejected')
tx1 = create_tx_with_script(block1.vtx[0], 0, script_sig=b'\x64' * 35, amount=50 * COIN - 12000)
tx1 = create_tx_with_script(block1.vtx[0], 0, script_sig=b'\x64' * 35, amount=50 * COIN - 12000, fee=12000)
node.p2p.send_txs_and_test([tx1], node, success=False, expect_disconnect=True)
# Make two p2p connections to provide the node with orphans
@ -85,12 +85,14 @@ class InvalidTxRequestTest(BitcoinTestFramework):
tx_withhold = CTransaction()
tx_withhold.vin.append(CTxIn(outpoint=COutPoint(block1.vtx[0].sha256, 0)))
tx_withhold.vout.append(CTxOut(nValue=50 * COIN - 12000, scriptPubKey=SCRIPT_PUB_KEY_OP_TRUE))
tx_withhold.vout.append(CTxOut(12000)) # fee
tx_withhold.calc_sha256()
# Our first orphan tx with some outputs to create further orphan txs
tx_orphan_1 = CTransaction()
tx_orphan_1.vin.append(CTxIn(outpoint=COutPoint(tx_withhold.sha256, 0)))
tx_orphan_1.vout = [CTxOut(nValue=10 * COIN, scriptPubKey=SCRIPT_PUB_KEY_OP_TRUE)] * 3
tx_orphan_1.vout.append(CTxOut(20 * COIN - 12000)) # fee
tx_orphan_1.calc_sha256()
# A valid transaction with low fee
@ -102,6 +104,7 @@ class InvalidTxRequestTest(BitcoinTestFramework):
tx_orphan_2_valid = CTransaction()
tx_orphan_2_valid.vin.append(CTxIn(outpoint=COutPoint(tx_orphan_1.sha256, 1)))
tx_orphan_2_valid.vout.append(CTxOut(nValue=10 * COIN - 12000, scriptPubKey=SCRIPT_PUB_KEY_OP_TRUE))
tx_orphan_2_valid.vout.append(CTxOut(12000)) # fee
tx_orphan_2_valid.calc_sha256()
# An invalid transaction with negative fee
@ -119,7 +122,7 @@ class InvalidTxRequestTest(BitcoinTestFramework):
assert_equal(2, len(node.getpeerinfo())) # p2ps[1] is still connected
self.log.info('Send the withhold tx ... ')
with node.assert_debug_log(expected_msgs=["bad-txns-in-belowout"]):
with node.assert_debug_log(expected_msgs=["bad-txns-in-ne-out"]):
node.p2p.send_txs_and_test([tx_withhold], node, success=True)
# Transactions that should end up in the mempool

View file

@ -12,6 +12,7 @@ import time
from test_framework.blocktools import create_block, create_coinbase, add_witness_commitment, WITNESS_COMMITMENT_HEADER
from test_framework.key import CECKey, CPubKey
from test_framework.messages import (
COIN,
BIP125_SEQUENCE_NUMBER,
CBlockHeader,
CInv,
@ -20,6 +21,8 @@ from test_framework.messages import (
CTxIn,
CTxInWitness,
CTxOut,
CTxOutValue,
CTxOutWitness,
CTxWitness,
MAX_BLOCK_BASE_SIZE,
MSG_WITNESS_FLAG,
@ -103,7 +106,7 @@ def get_p2pkh_script(pubkeyhash):
def sign_p2pk_witness_input(script, tx_to, in_idx, hashtype, value, key):
"""Add signature for a P2PK witness program."""
tx_hash = SegwitVersion1SignatureHash(script, tx_to, in_idx, hashtype, value)
tx_hash = SegwitVersion1SignatureHash(script, tx_to, in_idx, hashtype, CTxOutValue(value))
signature = key.sign(tx_hash) + chr(hashtype).encode('latin-1')
tx_to.wit.vtxinwit[in_idx].scriptWitness.stack = [signature, script]
tx_to.rehash()
@ -310,6 +313,7 @@ class SegWitTest(BitcoinTestFramework):
tx = CTransaction()
tx.vin.append(CTxIn(COutPoint(txid, 0), b""))
tx.vout.append(CTxOut(49 * 100000000, CScript([OP_TRUE, OP_DROP] * 15 + [OP_TRUE])))
tx.vout.append(CTxOut(50*COIN - 49*COIN)) # fee
tx.calc_sha256()
# Check that serializing it with or without witness is the same
@ -330,6 +334,7 @@ class SegWitTest(BitcoinTestFramework):
tx = CTransaction()
tx.vin.append(CTxIn(COutPoint(self.utxo[0].sha256, self.utxo[0].n), b""))
tx.vout.append(CTxOut(self.utxo[0].nValue - 1000, CScript([OP_TRUE])))
tx.vout.append(CTxOut(1000)) # fee
tx.wit.vtxinwit.append(CTxInWitness())
tx.wit.vtxinwit[0].scriptWitness.stack = [CScript([CScriptNum(1)])]
@ -353,7 +358,7 @@ class SegWitTest(BitcoinTestFramework):
# Update our utxo list; we spent the first entry.
self.utxo.pop(0)
self.utxo.append(UTXO(tx.sha256, 0, tx.vout[0].nValue))
self.utxo.append(UTXO(tx.sha256, 0, tx.vout[0].nValue.getAmount()))
@subtest
def test_block_relay(self):
@ -482,6 +487,7 @@ class SegWitTest(BitcoinTestFramework):
tx.vin = [CTxIn(COutPoint(self.utxo[0].sha256, self.utxo[0].n), b'')]
tx.vout = [CTxOut(value, script_pubkey), CTxOut(value, p2sh_script_pubkey)]
tx.vout.append(CTxOut(value, CScript([OP_TRUE])))
if self.utxo[0].nValue % 3 > 0: tx.vout.append(CTxOut(self.utxo[0].nValue - 3*value))
tx.rehash()
txid = tx.sha256
@ -612,12 +618,13 @@ class SegWitTest(BitcoinTestFramework):
tx = CTransaction()
tx.vin.append(CTxIn(COutPoint(self.utxo[0].sha256, self.utxo[0].n), b""))
tx.vout.append(CTxOut(self.utxo[0].nValue - 1000, CScript([OP_TRUE, OP_DROP] * 15 + [OP_TRUE])))
tx.vout.append(CTxOut(1000)) # fee
tx.wit.vtxinwit.append(CTxInWitness())
tx.wit.vtxinwit[0].scriptWitness.stack = [b'a']
tx.rehash()
tx_hash = tx.sha256
tx_value = tx.vout[0].nValue
tx_value = tx.vout[0].nValue.getAmount()
# Verify that if a peer doesn't set nServices to include NODE_WITNESS,
# the getdata is just for the non-witness portion.
@ -663,6 +670,7 @@ class SegWitTest(BitcoinTestFramework):
p2sh_tx = CTransaction()
p2sh_tx.vin = [CTxIn(COutPoint(self.utxo[0].sha256, self.utxo[0].n), b"")]
p2sh_tx.vout = [CTxOut(self.utxo[0].nValue - 1000, p2sh_script_pubkey)]
p2sh_tx.vout.append(CTxOut(1000)) # fee
p2sh_tx.rehash()
# Mine it on test_node to create the confirmed output.
@ -674,8 +682,9 @@ class SegWitTest(BitcoinTestFramework):
# Start by creating a transaction with two outputs.
tx = CTransaction()
tx.vin = [CTxIn(COutPoint(p2sh_tx.sha256, 0), CScript([witness_program]))]
tx.vout = [CTxOut(p2sh_tx.vout[0].nValue - 10000, script_pubkey)]
tx.vout = [CTxOut(p2sh_tx.vout[0].nValue.getAmount() - 10000, script_pubkey)]
tx.vout.append(CTxOut(8000, script_pubkey)) # Might burn this later
tx.vout.append(CTxOut(2000)) # fee
tx.vin[0].nSequence = BIP125_SEQUENCE_NUMBER # Just to have the option to bump this tx from the mempool
tx.rehash()
@ -689,6 +698,7 @@ class SegWitTest(BitcoinTestFramework):
# tx was accepted, so we spend the second output.
tx2.vin = [CTxIn(COutPoint(tx.sha256, 1), b"")]
tx2.vout = [CTxOut(7000, script_pubkey)]
tx2.vout.append(CTxOut(1000)) # fee
tx2.wit.vtxinwit.append(CTxInWitness())
tx2.wit.vtxinwit[0].scriptWitness.stack = [witness_program]
tx2.rehash()
@ -701,7 +711,8 @@ class SegWitTest(BitcoinTestFramework):
# P2PKH output; just send tx's first output back to an anyone-can-spend.
sync_mempools([self.nodes[0], self.nodes[1]])
tx3.vin = [CTxIn(COutPoint(tx.sha256, 0), b"")]
tx3.vout = [CTxOut(tx.vout[0].nValue - 1000, CScript([OP_TRUE, OP_DROP] * 15 + [OP_TRUE]))]
tx3.vout = [CTxOut(tx.vout[0].nValue.getAmount() - 1000, CScript([OP_TRUE, OP_DROP] * 15 + [OP_TRUE]))]
tx3.vout.append(CTxOut(1000)) # fee
tx3.wit.vtxinwit.append(CTxInWitness())
tx3.wit.vtxinwit[0].scriptWitness.stack = [witness_program]
tx3.rehash()
@ -713,6 +724,7 @@ class SegWitTest(BitcoinTestFramework):
tx3_out = tx3.vout[0]
tx3 = tx
tx3.vout = [tx3_out]
tx3.vout.append(CTxOut(p2sh_tx.vout[0].nValue.getAmount() - tx3.vout[0].nValue.getAmount())) # fee
tx3.rehash()
assert_equal(self.nodes[0].testmempoolaccept([bytes_to_hex_str(tx3.serialize_with_witness())]), [{'txid': tx3.hash, 'allowed': True}])
test_transaction_acceptance(self.nodes[0], self.test_node, tx3, with_witness=True, accepted=True)
@ -720,7 +732,7 @@ class SegWitTest(BitcoinTestFramework):
self.nodes[0].generate(1)
sync_blocks(self.nodes)
self.utxo.pop(0)
self.utxo.append(UTXO(tx3.sha256, 0, tx3.vout[0].nValue))
self.utxo.append(UTXO(tx3.sha256, 0, tx3.vout[0].nValue.getAmount()))
assert_equal(len(self.nodes[1].getrawmempool()), 0)
@subtest
@ -749,6 +761,7 @@ class SegWitTest(BitcoinTestFramework):
tx = CTransaction()
tx.vin.append(CTxIn(COutPoint(self.utxo[0].sha256, self.utxo[0].n), b""))
tx.vout.append(CTxOut(self.utxo[0].nValue - 1000, script_pubkey))
tx.vout.append(CTxOut(1000)) # fee
tx.rehash()
# Verify mempool acceptance and block validity
@ -761,7 +774,8 @@ class SegWitTest(BitcoinTestFramework):
# Now test attempts to spend the output.
spend_tx = CTransaction()
spend_tx.vin.append(CTxIn(COutPoint(tx.sha256, 0), script_sig))
spend_tx.vout.append(CTxOut(tx.vout[0].nValue - 1000, CScript([OP_TRUE])))
spend_tx.vout.append(CTxOut(tx.vout[0].nValue.getAmount() - 1000, CScript([OP_TRUE])))
spend_tx.vout.append(CTxOut(1000)) # fee
spend_tx.rehash()
# This transaction should not be accepted into the mempool pre- or
@ -796,7 +810,7 @@ class SegWitTest(BitcoinTestFramework):
# Update self.utxo
self.utxo.pop(0)
self.utxo.append(UTXO(spend_tx.sha256, 0, spend_tx.vout[0].nValue))
self.utxo.append(UTXO(spend_tx.sha256, 0, spend_tx.vout[0].nValue.getAmount()))
@subtest
def test_witness_commitments(self):
@ -835,12 +849,14 @@ class SegWitTest(BitcoinTestFramework):
witness_hash = sha256(witness_program)
script_pubkey = CScript([OP_0, witness_hash])
tx.vout.append(CTxOut(self.utxo[0].nValue - 1000, script_pubkey))
tx.vout.append(CTxOut(1000)) # fee
tx.rehash()
# tx2 will spend tx1, and send back to a regular anyone-can-spend address
tx2 = CTransaction()
tx2.vin.append(CTxIn(COutPoint(tx.sha256, 0), b""))
tx2.vout.append(CTxOut(tx.vout[0].nValue - 1000, witness_program))
tx2.vout.append(CTxOut(tx.vout[0].nValue.getAmount() - 1000, witness_program))
tx2.vout.append(CTxOut(1000)) # fee
tx2.wit.vtxinwit.append(CTxInWitness())
tx2.wit.vtxinwit[0].scriptWitness.stack = [witness_program]
tx2.rehash()
@ -863,8 +879,8 @@ class SegWitTest(BitcoinTestFramework):
# This should succeed (nValue shouldn't affect finding the
# witness commitment).
add_witness_commitment(block_3, nonce=0)
block_3.vtx[0].vout[0].nValue -= 1
block_3.vtx[0].vout[-1].nValue += 1
block_3.vtx[0].vout[0].nValue.setToAmount(block_3.vtx[0].vout[0].nValue.getAmount() - 1)
block_3.vtx[0].vout[-1].nValue.setToAmount(block_3.vtx[0].vout[-1].nValue.getAmount() + 1)
block_3.vtx[0].rehash()
block_3.hashMerkleRoot = block_3.calc_merkle_root()
block_3.rehash()
@ -877,7 +893,7 @@ class SegWitTest(BitcoinTestFramework):
block_4 = self.build_next_block()
tx3 = CTransaction()
tx3.vin.append(CTxIn(COutPoint(tx2.sha256, 0), b""))
tx3.vout.append(CTxOut(tx.vout[0].nValue - 1000, witness_program))
tx3.vout.append(CTxOut(tx.vout[0].nValue.getAmount() - 1000, witness_program))
tx3.rehash()
block_4.vtx.append(tx3)
block_4.hashMerkleRoot = block_4.calc_merkle_root()
@ -886,7 +902,7 @@ class SegWitTest(BitcoinTestFramework):
# Update available utxo's for use in later test.
self.utxo.pop(0)
self.utxo.append(UTXO(tx3.sha256, 0, tx3.vout[0].nValue))
self.utxo.append(UTXO(tx3.sha256, 0, tx3.vout[0].nValue.getAmount()))
@subtest
def test_block_malleability(self):
@ -957,14 +973,20 @@ class SegWitTest(BitcoinTestFramework):
child_value = int(value / NUM_OUTPUTS)
for i in range(NUM_OUTPUTS):
parent_tx.vout.append(CTxOut(child_value, script_pubkey))
parent_tx.vout[0].nValue -= 50000
assert(parent_tx.vout[0].nValue > 0)
parent_tx.vout[0].nValue.setToAmount(parent_tx.vout[0].nValue.getAmount() - 50000)
assert(parent_tx.vout[0].nValue.getAmount() > 0)
fee = value - (NUM_OUTPUTS*child_value) + 50000
if fee > 0:
parent_tx.vout.append(CTxOut(fee))
parent_tx.rehash()
child_tx = CTransaction()
total_in = 0
for i in range(NUM_OUTPUTS):
child_tx.vin.append(CTxIn(COutPoint(parent_tx.sha256, i), b""))
total_in += parent_tx.vout[i].nValue.getAmount()
child_tx.vout = [CTxOut(value - 100000, CScript([OP_TRUE]))]
child_tx.vout.append(CTxOut(total_in - (value - 100000))) # fee
for i in range(NUM_OUTPUTS):
child_tx.wit.vtxinwit.append(CTxInWitness())
child_tx.wit.vtxinwit[-1].scriptWitness.stack = [b'a' * 195] * (2 * NUM_DROPS) + [witness_program]
@ -976,9 +998,8 @@ class SegWitTest(BitcoinTestFramework):
i = 0
while additional_bytes > 0:
# Add some more bytes to each input until we hit MAX_BLOCK_BASE_SIZE+1
# ELEMENTS: mysterious off by 1 difference
#extra_bytes = min(additional_bytes + 1, 55)
extra_bytes = min(additional_bytes + 2, 55)
# ELEMENTS: mysterious off by 3 difference
extra_bytes = min(additional_bytes + 4, 55)
block.vtx[-1].wit.vtxinwit[int(i / (2 * NUM_DROPS))].scriptWitness.stack[i % (2 * NUM_DROPS)] = b'a' * (195 + extra_bytes)
additional_bytes -= extra_bytes
i += 1
@ -1000,13 +1021,13 @@ class SegWitTest(BitcoinTestFramework):
block.vtx[0].vout.pop()
add_witness_commitment(block)
block.solve()
assert(get_virtual_size(block) == MAX_BLOCK_BASE_SIZE)
assert_equal(get_virtual_size(block), MAX_BLOCK_BASE_SIZE)
test_witness_block(self.nodes[0], self.test_node, block, accepted=True)
# Update available utxo's
self.utxo.pop(0)
self.utxo.append(UTXO(block.vtx[-1].sha256, 0, block.vtx[-1].vout[0].nValue))
self.utxo.append(UTXO(block.vtx[-1].sha256, 0, block.vtx[-1].vout[0].nValue.getAmount()))
@subtest
def test_submit_block(self):
@ -1059,6 +1080,7 @@ class SegWitTest(BitcoinTestFramework):
tx.vin.append(CTxIn(COutPoint(self.utxo[0].sha256, self.utxo[0].n), b""))
tx.vout.append(CTxOut(self.utxo[0].nValue - 2000, script_pubkey))
tx.vout.append(CTxOut(1000, CScript([OP_TRUE]))) # non-witness output
tx.vout.append(CTxOut(1000)) # fee
tx.wit.vtxinwit.append(CTxInWitness())
tx.wit.vtxinwit[0].scriptWitness.stack = [CScript([])]
tx.rehash()
@ -1081,7 +1103,8 @@ class SegWitTest(BitcoinTestFramework):
tx2 = CTransaction()
tx2.vin.append(CTxIn(COutPoint(tx.sha256, 0), b"")) # witness output
tx2.vin.append(CTxIn(COutPoint(tx.sha256, 1), b"")) # non-witness
tx2.vout.append(CTxOut(tx.vout[0].nValue, CScript([OP_TRUE])))
tx2.vout.append(CTxOut(tx.vout[0].nValue.getAmount(), CScript([OP_TRUE])))
tx2.vout.append(CTxOut(tx.vout[1].nValue.getAmount())) # fee
tx2.wit.vtxinwit.extend([CTxInWitness(), CTxInWitness()])
tx2.wit.vtxinwit[0].scriptWitness.stack = [CScript([CScriptNum(1)]), CScript([CScriptNum(1)]), witness_program]
tx2.wit.vtxinwit[1].scriptWitness.stack = [CScript([OP_TRUE])]
@ -1115,7 +1138,7 @@ class SegWitTest(BitcoinTestFramework):
# Update utxo for later tests
self.utxo.pop(0)
self.utxo.append(UTXO(tx2.sha256, 0, tx2.vout[0].nValue))
self.utxo.append(UTXO(tx2.sha256, 0, tx2.vout[0].nValue.getAmount()))
@subtest
def test_max_witness_push_length(self):
@ -1130,11 +1153,13 @@ class SegWitTest(BitcoinTestFramework):
tx = CTransaction()
tx.vin.append(CTxIn(COutPoint(self.utxo[0].sha256, self.utxo[0].n), b""))
tx.vout.append(CTxOut(self.utxo[0].nValue - 1000, script_pubkey))
tx.vout.append(CTxOut(1000)) # fee
tx.rehash()
tx2 = CTransaction()
tx2.vin.append(CTxIn(COutPoint(tx.sha256, 0), b""))
tx2.vout.append(CTxOut(tx.vout[0].nValue - 1000, CScript([OP_TRUE])))
tx2.vout.append(CTxOut(tx.vout[0].nValue.getAmount() - 1000, CScript([OP_TRUE])))
tx2.vout.append(CTxOut(1000)) # fee
tx2.wit.vtxinwit.append(CTxInWitness())
# First try a 521-byte stack element
tx2.wit.vtxinwit[0].scriptWitness.stack = [b'a' * (MAX_SCRIPT_ELEMENT_SIZE + 1), witness_program]
@ -1152,7 +1177,7 @@ class SegWitTest(BitcoinTestFramework):
# Update the utxo for later tests
self.utxo.pop()
self.utxo.append(UTXO(tx2.sha256, 0, tx2.vout[0].nValue))
self.utxo.append(UTXO(tx2.sha256, 0, tx2.vout[0].nValue.getAmount()))
@subtest
def test_max_witness_program_length(self):
@ -1171,11 +1196,13 @@ class SegWitTest(BitcoinTestFramework):
tx = CTransaction()
tx.vin.append(CTxIn(COutPoint(self.utxo[0].sha256, self.utxo[0].n), b""))
tx.vout.append(CTxOut(self.utxo[0].nValue - 1000, long_script_pubkey))
tx.vout.append(CTxOut(1000)) # fee
tx.rehash()
tx2 = CTransaction()
tx2.vin.append(CTxIn(COutPoint(tx.sha256, 0), b""))
tx2.vout.append(CTxOut(tx.vout[0].nValue - 1000, CScript([OP_TRUE])))
tx2.vout.append(CTxOut(tx.vout[0].nValue.getAmount() - 1000, CScript([OP_TRUE])))
tx2.vout.append(CTxOut(1000)) # fee
tx2.wit.vtxinwit.append(CTxInWitness())
tx2.wit.vtxinwit[0].scriptWitness.stack = [b'a'] * 44 + [long_witness_program]
tx2.rehash()
@ -1190,7 +1217,7 @@ class SegWitTest(BitcoinTestFramework):
witness_hash = sha256(witness_program)
script_pubkey = CScript([OP_0, witness_hash])
tx.vout[0] = CTxOut(tx.vout[0].nValue, script_pubkey)
tx.vout[0] = CTxOut(tx.vout[0].nValue.getAmount(), script_pubkey)
tx.rehash()
tx2.vin[0].prevout.hash = tx.sha256
tx2.wit.vtxinwit[0].scriptWitness.stack = [b'a'] * 43 + [witness_program]
@ -1200,7 +1227,7 @@ class SegWitTest(BitcoinTestFramework):
test_witness_block(self.nodes[0], self.test_node, block, accepted=True)
self.utxo.pop()
self.utxo.append(UTXO(tx2.sha256, 0, tx2.vout[0].nValue))
self.utxo.append(UTXO(tx2.sha256, 0, tx2.vout[0].nValue.getAmount()))
@subtest
def test_witness_input_length(self):
@ -1216,8 +1243,9 @@ class SegWitTest(BitcoinTestFramework):
value = self.utxo[0].nValue
for i in range(10):
tx.vout.append(CTxOut(int(value / 10), script_pubkey))
tx.vout[0].nValue -= 1000
assert(tx.vout[0].nValue >= 0)
tx.vout[0].nValue.setToAmount(tx.vout[0].nValue.getAmount() - 1000)
assert(tx.vout[0].nValue.getAmount() >= 0)
tx.vout.append(CTxOut(1000)) # fee
block = self.build_next_block()
self.update_witness_block_with_transactions(block, [tx])
@ -1242,9 +1270,14 @@ class SegWitTest(BitcoinTestFramework):
return r
tx2 = BrokenCTransaction()
total_in = 0
for i in range(10):
tx2.vin.append(CTxIn(COutPoint(tx.sha256, i), b""))
total_in += tx.vout[i].nValue.getAmount()
tx2.vout.append(CTxOut(value - 3000, CScript([OP_TRUE])))
tx2.vout.append(CTxOut(total_in - (value-3000))) # fee
tx2.wit.vtxoutwit = [CTxOutWitness(), CTxOutWitness()]
tx2.calc_sha256()
# First try using a too long vtxinwit
for i in range(11):
@ -1253,8 +1286,7 @@ class SegWitTest(BitcoinTestFramework):
block = self.build_next_block()
self.update_witness_block_with_transactions(block, [tx2])
# ELEMENTS: different serialization so doesn't make sense
#test_witness_block(self.nodes[0], self.test_node, block, accepted=False)
test_witness_block(self.nodes[0], self.test_node, block, accepted=False)
# Now try using a too short vtxinwit
tx2.wit.vtxinwit.pop()
@ -1280,7 +1312,7 @@ class SegWitTest(BitcoinTestFramework):
test_witness_block(self.nodes[0], self.test_node, block, accepted=True)
self.utxo.pop()
self.utxo.append(UTXO(tx2.sha256, 0, tx2.vout[0].nValue))
self.utxo.append(UTXO(tx2.sha256, 0, tx2.vout[0].nValue.getAmount()))
@subtest
def test_tx_relay_after_segwit_activation(self):
@ -1297,6 +1329,7 @@ class SegWitTest(BitcoinTestFramework):
tx = CTransaction()
tx.vin.append(CTxIn(COutPoint(self.utxo[0].sha256, self.utxo[0].n), b""))
tx.vout.append(CTxOut(self.utxo[0].nValue - 1000, CScript([OP_TRUE, OP_DROP] * 15 + [OP_TRUE])))
tx.vout.append(CTxOut(1000)) # fee
tx.wit.vtxinwit.append(CTxInWitness())
tx.wit.vtxinwit[0].scriptWitness.stack = [b'a']
tx.rehash()
@ -1318,7 +1351,8 @@ class SegWitTest(BitcoinTestFramework):
script_pubkey = CScript([OP_0, witness_hash])
tx2 = CTransaction()
tx2.vin.append(CTxIn(COutPoint(tx_hash, 0), b""))
tx2.vout.append(CTxOut(tx.vout[0].nValue - 1000, script_pubkey))
tx2.vout.append(CTxOut(tx.vout[0].nValue.getAmount() - 1000, script_pubkey))
tx2.vout.append(CTxOut(1000)) # fee
tx2.rehash()
tx3 = CTransaction()
@ -1329,7 +1363,8 @@ class SegWitTest(BitcoinTestFramework):
p2sh_program = CScript([OP_TRUE])
p2sh_pubkey = hash160(p2sh_program)
witness_program2 = CScript([b'a' * 400000])
tx3.vout.append(CTxOut(tx2.vout[0].nValue - 1000, CScript([OP_HASH160, p2sh_pubkey, OP_EQUAL])))
tx3.vout.append(CTxOut(tx2.vout[0].nValue.getAmount() - 1000, CScript([OP_HASH160, p2sh_pubkey, OP_EQUAL])))
tx3.vout.append(CTxOut(1000)) # fee
tx3.wit.vtxinwit[0].scriptWitness.stack = [witness_program2]
tx3.rehash()
@ -1340,7 +1375,7 @@ class SegWitTest(BitcoinTestFramework):
test_transaction_acceptance(self.nodes[1], self.std_node, tx3, True, False, 'tx-size')
# Remove witness stuffing, instead add extra witness push on stack
tx3.vout[0] = CTxOut(tx2.vout[0].nValue - 1000, CScript([OP_TRUE, OP_DROP] * 15 + [OP_TRUE]))
tx3.vout[0] = CTxOut(tx2.vout[0].nValue.getAmount() - 1000, CScript([OP_TRUE, OP_DROP] * 15 + [OP_TRUE]))
tx3.wit.vtxinwit[0].scriptWitness.stack = [CScript([CScriptNum(1)]), witness_program]
tx3.rehash()
@ -1373,7 +1408,7 @@ class SegWitTest(BitcoinTestFramework):
assert_equal(len(self.nodes[0].getrawmempool()), 0)
self.utxo.pop(0)
self.utxo.append(UTXO(tx3.sha256, 0, tx3.vout[0].nValue))
self.utxo.append(UTXO(tx3.sha256, 0, tx3.vout[0].nValue.getAmount()))
@subtest
def test_segwit_versions(self):
@ -1389,6 +1424,7 @@ class SegWitTest(BitcoinTestFramework):
split_value = (self.utxo[0].nValue - 4000) // NUM_SEGWIT_VERSIONS
for i in range(NUM_SEGWIT_VERSIONS):
tx.vout.append(CTxOut(split_value, CScript([OP_TRUE])))
tx.vout.append(CTxOut(self.utxo[0].nValue - NUM_SEGWIT_VERSIONS*split_value)) # fee
tx.rehash()
block = self.build_next_block()
self.update_witness_block_with_transactions(block, [tx])
@ -1408,11 +1444,12 @@ class SegWitTest(BitcoinTestFramework):
script_pubkey = CScript([CScriptOp(version), witness_hash])
tx.vin = [CTxIn(COutPoint(self.utxo[0].sha256, self.utxo[0].n), b"")]
tx.vout = [CTxOut(self.utxo[0].nValue - 1000, script_pubkey)]
tx.vout.append(CTxOut(1000)) # fee
tx.rehash()
test_transaction_acceptance(self.nodes[1], self.std_node, tx, with_witness=True, accepted=False)
test_transaction_acceptance(self.nodes[0], self.test_node, tx, with_witness=True, accepted=True)
self.utxo.pop(0)
temp_utxo.append(UTXO(tx.sha256, 0, tx.vout[0].nValue))
temp_utxo.append(UTXO(tx.sha256, 0, tx.vout[0].nValue.getAmount()))
self.nodes[0].generate(1) # Mine all the transactions
sync_blocks(self.nodes)
@ -1423,7 +1460,8 @@ class SegWitTest(BitcoinTestFramework):
script_pubkey = CScript([CScriptOp(OP_1), witness_hash])
tx2 = CTransaction()
tx2.vin = [CTxIn(COutPoint(tx.sha256, 0), b"")]
tx2.vout = [CTxOut(tx.vout[0].nValue - 1000, script_pubkey)]
tx2.vout = [CTxOut(tx.vout[0].nValue.getAmount() - 1000, script_pubkey)]
tx2.vout.append(CTxOut(1000)) # fee
tx2.wit.vtxinwit.append(CTxInWitness())
tx2.wit.vtxinwit[0].scriptWitness.stack = [witness_program]
tx2.rehash()
@ -1432,7 +1470,7 @@ class SegWitTest(BitcoinTestFramework):
test_transaction_acceptance(self.nodes[0], self.test_node, tx2, with_witness=True, accepted=True)
test_transaction_acceptance(self.nodes[1], self.std_node, tx2, with_witness=True, accepted=False)
temp_utxo.pop() # last entry in temp_utxo was the output we just spent
temp_utxo.append(UTXO(tx2.sha256, 0, tx2.vout[0].nValue))
temp_utxo.append(UTXO(tx2.sha256, 0, tx2.vout[0].nValue.getAmount()))
# Spend everything in temp_utxo back to an OP_TRUE output.
tx3 = CTransaction()
@ -1443,6 +1481,7 @@ class SegWitTest(BitcoinTestFramework):
total_value += i.nValue
tx3.wit.vtxinwit[-1].scriptWitness.stack = [witness_program]
tx3.vout.append(CTxOut(total_value - 1000, CScript([OP_TRUE])))
tx3.vout.append(CTxOut(1000)) # fee
tx3.rehash()
# Spending a higher version witness output is not allowed by policy,
# even with fRequireStandard=false.
@ -1455,7 +1494,7 @@ class SegWitTest(BitcoinTestFramework):
sync_blocks(self.nodes)
# Add utxo to our list
self.utxo.append(UTXO(tx3.sha256, 0, tx3.vout[0].nValue))
self.utxo.append(UTXO(tx3.sha256, 0, tx3.vout[0].nValue.getAmount()))
@subtest
def test_premature_coinbase_witness_spend(self):
@ -1473,7 +1512,7 @@ class SegWitTest(BitcoinTestFramework):
spend_tx = CTransaction()
spend_tx.vin = [CTxIn(COutPoint(block.vtx[0].sha256, 0), b"")]
spend_tx.vout = [CTxOut(block.vtx[0].vout[0].nValue, witness_program)]
spend_tx.vout = [CTxOut(block.vtx[0].vout[0].nValue.getAmount(), witness_program)]
spend_tx.wit.vtxinwit.append(CTxInWitness())
spend_tx.wit.vtxinwit[0].scriptWitness.stack = [witness_program]
spend_tx.rehash()
@ -1516,6 +1555,7 @@ class SegWitTest(BitcoinTestFramework):
tx = CTransaction()
tx.vin.append(CTxIn(COutPoint(utxo.sha256, utxo.n), b""))
tx.vout.append(CTxOut(utxo.nValue - 1000, script_pkh))
tx.vout.append(CTxOut(1000)) # fee
tx.rehash()
# Confirm it in a block.
@ -1531,7 +1571,8 @@ class SegWitTest(BitcoinTestFramework):
tx2 = CTransaction()
tx2.vin.append(CTxIn(COutPoint(tx.sha256, 0), b""))
tx2.vout.append(CTxOut(tx.vout[0].nValue - 1000, script_wsh))
tx2.vout.append(CTxOut(tx.vout[0].nValue.getAmount() - 1000, script_wsh))
tx2.vout.append(CTxOut(1000)) # fee
script = get_p2pkh_script(pubkeyhash)
sig_hash = SegwitVersion1SignatureHash(script, tx2, 0, SIGHASH_ALL, tx.vout[0].nValue)
signature = key.sign(sig_hash) + b'\x01' # 0x1 is SIGHASH_ALL
@ -1555,9 +1596,10 @@ class SegWitTest(BitcoinTestFramework):
tx3 = CTransaction()
tx3.vin.append(CTxIn(COutPoint(tx2.sha256, 0), b""))
tx3.vout.append(CTxOut(tx2.vout[0].nValue - 1000, script_p2sh))
tx3.vout.append(CTxOut(tx2.vout[0].nValue.getAmount() - 1000, script_p2sh))
tx3.vout.append(CTxOut(1000)) # fee
tx3.wit.vtxinwit.append(CTxInWitness())
sign_p2pk_witness_input(witness_program, tx3, 0, SIGHASH_ALL, tx2.vout[0].nValue, key)
sign_p2pk_witness_input(witness_program, tx3, 0, SIGHASH_ALL, tx2.vout[0].nValue.getAmount(), key)
# Should fail policy test.
test_transaction_acceptance(self.nodes[0], self.test_node, tx3, True, False, 'non-mandatory-script-verify-flag (Using non-compressed keys in segwit)')
@ -1572,9 +1614,10 @@ class SegWitTest(BitcoinTestFramework):
script_pubkey = get_p2pkh_script(pubkeyhash)
tx4 = CTransaction()
tx4.vin.append(CTxIn(COutPoint(tx3.sha256, 0), script_sig))
tx4.vout.append(CTxOut(tx3.vout[0].nValue - 1000, script_pubkey))
tx4.vout.append(CTxOut(tx3.vout[0].nValue.getAmount() - 1000, script_pubkey))
tx4.vout.append(CTxOut(1000)) # fee
tx4.wit.vtxinwit.append(CTxInWitness())
sign_p2pk_witness_input(witness_program, tx4, 0, SIGHASH_ALL, tx3.vout[0].nValue, key)
sign_p2pk_witness_input(witness_program, tx4, 0, SIGHASH_ALL, tx3.vout[0].nValue.getAmount(), key)
# Should fail policy test.
test_transaction_acceptance(self.nodes[0], self.test_node, tx4, True, False, 'non-mandatory-script-verify-flag (Using non-compressed keys in segwit)')
@ -1586,7 +1629,8 @@ class SegWitTest(BitcoinTestFramework):
# transactions.
tx5 = CTransaction()
tx5.vin.append(CTxIn(COutPoint(tx4.sha256, 0), b""))
tx5.vout.append(CTxOut(tx4.vout[0].nValue - 1000, CScript([OP_TRUE])))
tx5.vout.append(CTxOut(tx4.vout[0].nValue.getAmount() - 1000, CScript([OP_TRUE])))
tx5.vout.append(CTxOut(1000)) # fee
(sig_hash, err) = SignatureHash(script_pubkey, tx5, 0, SIGHASH_ALL)
signature = key.sign(sig_hash) + b'\x01' # 0x1 is SIGHASH_ALL
tx5.vin[0].scriptSig = CScript([signature, pubkey])
@ -1596,7 +1640,7 @@ class SegWitTest(BitcoinTestFramework):
block = self.build_next_block()
self.update_witness_block_with_transactions(block, [tx5])
test_witness_block(self.nodes[0], self.test_node, block, accepted=True)
self.utxo.append(UTXO(tx5.sha256, 0, tx5.vout[0].nValue))
self.utxo.append(UTXO(tx5.sha256, 0, tx5.vout[0].nValue.getAmount()))
@subtest
def test_signature_version_1(self):
@ -1613,6 +1657,7 @@ class SegWitTest(BitcoinTestFramework):
tx = CTransaction()
tx.vin.append(CTxIn(COutPoint(self.utxo[0].sha256, self.utxo[0].n), b""))
tx.vout.append(CTxOut(self.utxo[0].nValue - 1000, script_pubkey))
tx.vout.append(CTxOut(1000)) # fee
tx.rehash()
test_transaction_acceptance(self.nodes[0], self.test_node, tx, with_witness=True, accepted=True)
@ -1624,7 +1669,7 @@ class SegWitTest(BitcoinTestFramework):
self.utxo.pop(0)
# Test each hashtype
prev_utxo = UTXO(tx.sha256, 0, tx.vout[0].nValue)
prev_utxo = UTXO(tx.sha256, 0, tx.vout[0].nValue.getAmount())
for sigflag in [0, SIGHASH_ANYONECANPAY]:
for hashtype in [SIGHASH_ALL, SIGHASH_NONE, SIGHASH_SINGLE]:
hashtype |= sigflag
@ -1632,6 +1677,7 @@ class SegWitTest(BitcoinTestFramework):
tx = CTransaction()
tx.vin.append(CTxIn(COutPoint(prev_utxo.sha256, prev_utxo.n), b""))
tx.vout.append(CTxOut(prev_utxo.nValue - 1000, script_pubkey))
tx.vout.append(CTxOut(1000)) # fee
tx.wit.vtxinwit.append(CTxInWitness())
# Too-large input value
sign_p2pk_witness_input(witness_program, tx, 0, hashtype, prev_utxo.nValue + 1, key)
@ -1650,7 +1696,7 @@ class SegWitTest(BitcoinTestFramework):
self.update_witness_block_with_transactions(block, [tx])
test_witness_block(self.nodes[0], self.test_node, block, accepted=True)
prev_utxo = UTXO(tx.sha256, 0, tx.vout[0].nValue)
prev_utxo = UTXO(tx.sha256, 0, tx.vout[0].nValue.getAmount())
# Test combinations of signature hashes.
# Split the utxo into a lot of outputs.
@ -1665,6 +1711,7 @@ class SegWitTest(BitcoinTestFramework):
split_value = prev_utxo.nValue // NUM_SIGHASH_TESTS
for i in range(NUM_SIGHASH_TESTS):
tx.vout.append(CTxOut(split_value, script_pubkey))
tx.vout.append(CTxOut(prev_utxo.nValue - NUM_SIGHASH_TESTS*split_value)) # fee
tx.wit.vtxinwit.append(CTxInWitness())
sign_p2pk_witness_input(witness_program, tx, 0, SIGHASH_ALL, prev_utxo.nValue, key)
for i in range(NUM_SIGHASH_TESTS):
@ -1695,6 +1742,7 @@ class SegWitTest(BitcoinTestFramework):
split_value = total_value // num_outputs
for i in range(num_outputs):
tx.vout.append(CTxOut(split_value, script_pubkey))
if total_value % num_outputs > 0: tx.vout.append(CTxOut(total_value - num_outputs*split_value)) # fee
for i in range(num_inputs):
# Now try to sign each input, using a random hashtype.
anyonecanpay = 0
@ -1734,7 +1782,7 @@ class SegWitTest(BitcoinTestFramework):
sign_p2pk_witness_input(witness_program, tx, 0, SIGHASH_ALL, temp_utxos[0].nValue, key)
tx2 = CTransaction()
tx2.vin.append(CTxIn(COutPoint(tx.sha256, 0), b""))
tx2.vout.append(CTxOut(tx.vout[0].nValue, CScript([OP_TRUE])))
tx2.vout.append(CTxOut(tx.vout[0].nValue.getAmount(), CScript([OP_TRUE])))
script = get_p2pkh_script(pubkeyhash)
sig_hash = SegwitVersion1SignatureHash(script, tx2, 0, SIGHASH_ALL, tx.vout[0].nValue)
@ -1766,6 +1814,8 @@ class SegWitTest(BitcoinTestFramework):
index = 0
# Just spend to our usual anyone-can-spend output
tx.vout = [CTxOut(output_value, CScript([OP_TRUE]))] * 2
total_in = sum(i.nValue for i in temp_utxos)
if total_in - 2*output_value > 0: tx.vout.append(CTxOut(total_in - 2*output_value)) # fee
for i in temp_utxos:
# Use SIGHASH_ALL|SIGHASH_ANYONECANPAY so we can build up
# the signatures as we go.
@ -1778,7 +1828,9 @@ class SegWitTest(BitcoinTestFramework):
test_witness_block(self.nodes[0], self.test_node, block, accepted=True)
for i in range(len(tx.vout)):
self.utxo.append(UTXO(tx.sha256, i, tx.vout[i].nValue))
if tx.vout[i].is_fee():
continue
self.utxo.append(UTXO(tx.sha256, i, tx.vout[i].nValue.getAmount()))
@subtest
def test_non_standard_witness_blinding(self):
@ -1796,6 +1848,7 @@ class SegWitTest(BitcoinTestFramework):
tx = CTransaction()
tx.vin.append(CTxIn(COutPoint(self.utxo[0].sha256, self.utxo[0].n), b""))
tx.vout.append(CTxOut(self.utxo[0].nValue - 1000, script_pubkey))
tx.vout.append(CTxOut(1000)) # fee
tx.rehash()
test_transaction_acceptance(self.nodes[0], self.test_node, tx, False, True)
self.nodes[0].generate(1)
@ -1808,7 +1861,8 @@ class SegWitTest(BitcoinTestFramework):
# to the rejection cache.
tx2 = CTransaction()
tx2.vin.append(CTxIn(COutPoint(tx.sha256, 0), CScript([p2sh_program])))
tx2.vout.append(CTxOut(tx.vout[0].nValue - 1000, script_pubkey))
tx2.vout.append(CTxOut(tx.vout[0].nValue.getAmount() - 1000, script_pubkey))
tx2.vout.append(CTxOut(1000)) # fee
tx2.wit.vtxinwit.append(CTxInWitness())
tx2.wit.vtxinwit[0].scriptWitness.stack = [b'a' * 400]
tx2.rehash()
@ -1822,7 +1876,8 @@ class SegWitTest(BitcoinTestFramework):
# Now create a new anyone-can-spend utxo for the next test.
tx3 = CTransaction()
tx3.vin.append(CTxIn(COutPoint(tx2.sha256, 0), CScript([p2sh_program])))
tx3.vout.append(CTxOut(tx2.vout[0].nValue - 1000, CScript([OP_TRUE, OP_DROP] * 15 + [OP_TRUE])))
tx3.vout.append(CTxOut(tx2.vout[0].nValue.getAmount() - 1000, CScript([OP_TRUE, OP_DROP] * 15 + [OP_TRUE])))
tx3.vout.append(CTxOut(1000)) # fee
tx3.rehash()
test_transaction_acceptance(self.nodes[0], self.test_node, tx2, False, True)
test_transaction_acceptance(self.nodes[0], self.test_node, tx3, False, True)
@ -1832,7 +1887,7 @@ class SegWitTest(BitcoinTestFramework):
# Update our utxo list; we spent the first entry.
self.utxo.pop(0)
self.utxo.append(UTXO(tx3.sha256, 0, tx3.vout[0].nValue))
self.utxo.append(UTXO(tx3.sha256, 0, tx3.vout[0].nValue.getAmount()))
@subtest
def test_non_standard_witness(self):
@ -1859,6 +1914,7 @@ class SegWitTest(BitcoinTestFramework):
p2wsh_scripts.append(p2wsh)
tx.vout.append(CTxOut(outputvalue, p2wsh))
tx.vout.append(CTxOut(outputvalue, CScript([OP_HASH160, p2sh, OP_EQUAL])))
tx.vout.append(CTxOut(self.utxo[0].nValue - 2*len(scripts)*outputvalue)) # fee
tx.rehash()
txid = tx.sha256
test_transaction_acceptance(self.nodes[0], self.test_node, tx, with_witness=False, accepted=True)
@ -1873,12 +1929,14 @@ class SegWitTest(BitcoinTestFramework):
p2wsh_tx = CTransaction()
p2wsh_tx.vin.append(CTxIn(COutPoint(txid, i * 2)))
p2wsh_tx.vout.append(CTxOut(outputvalue - 5000, CScript([OP_0, hash160(hex_str_to_bytes(""))])))
p2wsh_tx.vout.append(CTxOut(5000)) # fee
p2wsh_tx.wit.vtxinwit.append(CTxInWitness())
p2wsh_tx.rehash()
p2wsh_txs.append(p2wsh_tx)
p2sh_tx = CTransaction()
p2sh_tx.vin.append(CTxIn(COutPoint(txid, i * 2 + 1), CScript([p2wsh_scripts[i]])))
p2sh_tx.vout.append(CTxOut(outputvalue - 5000, CScript([OP_0, hash160(hex_str_to_bytes(""))])))
p2sh_tx.vout.append(CTxOut(5000)) # fee
p2sh_tx.wit.vtxinwit.append(CTxInWitness())
p2sh_tx.rehash()
p2sh_txs.append(p2sh_tx)
@ -1996,6 +2054,7 @@ class SegWitTest(BitcoinTestFramework):
tx.vout.append(CTxOut(split_value, script_pubkey))
tx.vout[-2].scriptPubKey = script_pubkey_toomany
tx.vout[-1].scriptPubKey = script_pubkey_justright
if self.utxo[0].nValue % outputs > 0: tx.vout.append(CTxOut(self.utxo[0].nValue - outputs*split_value)) # fee
tx.rehash()
block_1 = self.build_next_block()
@ -2010,7 +2069,7 @@ class SegWitTest(BitcoinTestFramework):
tx2.vin.append(CTxIn(COutPoint(tx.sha256, i), b""))
tx2.wit.vtxinwit.append(CTxInWitness())
tx2.wit.vtxinwit[-1].scriptWitness.stack = [witness_program]
total_value += tx.vout[i].nValue
total_value += tx.vout[i].nValue.getAmount()
tx2.wit.vtxinwit[-1].scriptWitness.stack = [witness_program_toomany]
tx2.vout.append(CTxOut(total_value, CScript([OP_TRUE])))
tx2.rehash()
@ -2023,10 +2082,12 @@ class SegWitTest(BitcoinTestFramework):
# too many sigops (contributing to legacy sigop count).
checksig_count = (extra_sigops_available // 4) + 1
script_pubkey_checksigs = CScript([OP_CHECKSIG] * checksig_count)
tx2.vout.append(CTxOut(0, script_pubkey_checksigs))
# ELEMENTS: no 0-value transactions allowed for non-OP_RETURN outputs
tx2.vout.append(CTxOut(1, script_pubkey_checksigs))
tx2.vout[0].nValue.setToAmount(tx2.vout[0].nValue.getAmount() - 1)
tx2.vin.pop()
tx2.wit.vtxinwit.pop()
tx2.vout[0].nValue -= tx.vout[-2].nValue
tx2.vout[0].nValue.setToAmount(tx2.vout[0].nValue.getAmount() - tx.vout[-2].nValue.getAmount())
tx2.rehash()
block_3 = self.build_next_block()
self.update_witness_block_with_transactions(block_3, [tx2])
@ -2047,8 +2108,12 @@ class SegWitTest(BitcoinTestFramework):
# Try replacing the last input of tx2 to be spending the last
# output of tx
block_5 = self.build_next_block()
# ELEMENTS: need to replace extra value with fee
to_replace = tx2.vout[-1].nValue.getAmount()
tx2.vout.pop()
tx2.vin.append(CTxIn(COutPoint(tx.sha256, outputs - 1), b""))
to_replace += tx.vout[outputs-1].nValue.getAmount()
tx2.vout.append(CTxOut(to_replace)) # fee
tx2.wit.vtxinwit.append(CTxInWitness())
tx2.wit.vtxinwit[-1].scriptWitness.stack = [witness_program_justright]
tx2.rehash()

View file

@ -85,7 +85,7 @@ class RpcCreateMultiSigTest(BitcoinTestFramework):
node0.generate(1)
outval = value - decimal.Decimal("0.00001000")
rawtx = node2.createrawtransaction([{"txid": txid, "vout": vout}], [{self.final: outval}])
rawtx = node2.createrawtransaction([{"txid": txid, "vout": vout}], [{self.final: outval}, {"fee": "0.00001"}])
rawtx2 = node2.signrawtransactionwithkey(rawtx, self.priv[0:self.nsigs-1], prevtxs)
rawtx3 = node2.signrawtransactionwithkey(rawtx2["hex"], [self.priv[-1]], prevtxs)

View file

@ -166,16 +166,16 @@ class DecodeScriptTest(BitcoinTestFramework):
"""
# this test case uses a random plain vanilla mainnet transaction with a single P2PKH input and output
tx = '010000000001696a20784a2c70143f634e95227dbdfdf0ecd51647052e70854512235f5986ca010000008a47304402207174775824bec6c2700023309a168231ec80b82c6069282f5133e6f11cbb04460220570edc55c7c5da2ca687ebd0372d3546ebc3f810516a002350cac72dfe192dfb014104d3f898e6487787910a690410b7a917ef198905c27fb9d3b0a42da12aceae0544fc7088d239d9a48f2828a15a09e84043001f27cc80d162cb95404e1210161536ffffffff0100e1f505000000001976a914eb6c6e0cdb2d256a32d97b8df1fc75d1920d9bca88ac11000000'
tx = '010000000001696a20784a2c70143f634e95227dbdfdf0ecd51647052e70854512235f5986ca010000008a47304402207174775824bec6c2700023309a168231ec80b82c6069282f5133e6f11cbb04460220570edc55c7c5da2ca687ebd0372d3546ebc3f810516a002350cac72dfe192dfb014104d3f898e6487787910a690410b7a917ef198905c27fb9d3b0a42da12aceae0544fc7088d239d9a48f2828a15a09e84043001f27cc80d162cb95404e1210161536ffffffff0101ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000066a047465737400000000'
rpc_result = self.nodes[0].decoderawtransaction(tx)
assert_equal('304402207174775824bec6c2700023309a168231ec80b82c6069282f5133e6f11cbb04460220570edc55c7c5da2ca687ebd0372d3546ebc3f810516a002350cac72dfe192dfb[ALL] 04d3f898e6487787910a690410b7a917ef198905c27fb9d3b0a42da12aceae0544fc7088d239d9a48f2828a15a09e84043001f27cc80d162cb95404e1210161536', rpc_result['vin'][0]['scriptSig']['asm'])
# this test case uses a mainnet transaction that has a P2SH input and both P2PKH and P2SH outputs.
# it's from James D'Angelo's awesome introductory videos about multisig: https://www.youtube.com/watch?v=zIbUSaZBJgU and https://www.youtube.com/watch?v=OSA1pwlaypc
# verify that we have not altered scriptPubKey decoding.
tx = '0100000000018d1f5635abd06e2c7e2ddf58dc85b3de111e4ad6e0ab51bb0dcf5e84126d927300000000fdfe0000483045022100ae3b4e589dfc9d48cb82d41008dc5fa6a86f94d5c54f9935531924602730ab8002202f88cf464414c4ed9fa11b773c5ee944f66e9b05cc1e51d97abc22ce098937ea01483045022100b44883be035600e9328a01b66c7d8439b74db64187e76b99a68f7893b701d5380220225bf286493e4c4adcf928c40f785422572eb232f84a0b83b0dea823c3a19c75014c695221020743d44be989540d27b1b4bbbcfd17721c337cb6bc9af20eb8a32520b393532f2102c0120a1dda9e51a938d39ddd9fe0ebc45ea97e1d27a7cbd671d5431416d3dd87210213820eb3d5f509d7438c9eeecb4157b2f595105e7cd564b3cdbb9ead3da41eed53aeffffffff02611e0000000000001976a914dc863734a218bfe83ef770ee9d41a27f824a6e5688acee2a02000000000017a9142a5edea39971049a540474c6a99edf0aa4074c588700000000'
tx = '0100000000018d1f5635abd06e2c7e2ddf58dc85b3de111e4ad6e0ab51bb0dcf5e84126d927300000000fdfe0000483045022100ae3b4e589dfc9d48cb82d41008dc5fa6a86f94d5c54f9935531924602730ab8002202f88cf464414c4ed9fa11b773c5ee944f66e9b05cc1e51d97abc22ce098937ea01483045022100b44883be035600e9328a01b66c7d8439b74db64187e76b99a68f7893b701d5380220225bf286493e4c4adcf928c40f785422572eb232f84a0b83b0dea823c3a19c75014c695221020743d44be989540d27b1b4bbbcfd17721c337cb6bc9af20eb8a32520b393532f2102c0120a1dda9e51a938d39ddd9fe0ebc45ea97e1d27a7cbd671d5431416d3dd87210213820eb3d5f509d7438c9eeecb4157b2f595105e7cd564b3cdbb9ead3da41eed53aeffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe0010000000000001e61001976a914dc863734a218bfe83ef770ee9d41a27f824a6e5688ac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe0010000000000022aee0017a9142a5edea39971049a540474c6a99edf0aa4074c588700000000'
rpc_result = self.nodes[0].decoderawtransaction(tx)
assert_equal('b7c7a18df6441582674acb436f70a91b0ea03651c79d58d49f7bb987e477ee24', rpc_result['txid'])
assert_equal('0640baa19c5df568c1fef1685cf251c33efe2cda37193f3dc2e6b5115774f30a', rpc_result['txid'])
assert_equal('0 3045022100ae3b4e589dfc9d48cb82d41008dc5fa6a86f94d5c54f9935531924602730ab8002202f88cf464414c4ed9fa11b773c5ee944f66e9b05cc1e51d97abc22ce098937ea[ALL] 3045022100b44883be035600e9328a01b66c7d8439b74db64187e76b99a68f7893b701d5380220225bf286493e4c4adcf928c40f785422572eb232f84a0b83b0dea823c3a19c75[ALL] 5221020743d44be989540d27b1b4bbbcfd17721c337cb6bc9af20eb8a32520b393532f2102c0120a1dda9e51a938d39ddd9fe0ebc45ea97e1d27a7cbd671d5431416d3dd87210213820eb3d5f509d7438c9eeecb4157b2f595105e7cd564b3cdbb9ead3da41eed53ae', rpc_result['vin'][0]['scriptSig']['asm'])
assert_equal('OP_DUP OP_HASH160 dc863734a218bfe83ef770ee9d41a27f824a6e56 OP_EQUALVERIFY OP_CHECKSIG', rpc_result['vout'][0]['scriptPubKey']['asm'])
assert_equal('OP_HASH160 2a5edea39971049a540474c6a99edf0aa4074c58 OP_EQUAL', rpc_result['vout'][1]['scriptPubKey']['asm'])
@ -183,12 +183,12 @@ class DecodeScriptTest(BitcoinTestFramework):
txSave.deserialize(BytesIO(hex_str_to_bytes(tx)))
# make sure that a specifically crafted op_return value will not pass all the IsDERSignature checks and then get decoded as a sighash type
tx = '0100000000015ded05872fdbda629c7d3d02b194763ce3b9b1535ea884e3c8e765d42e316724020000006b48304502204c10d4064885c42638cbff3585915b322de33762598321145ba033fc796971e2022100bb153ad3baa8b757e30a2175bd32852d2e1cb9080f84d7e32fcdfd667934ef1b012103163c0ff73511ea1743fb5b98384a2ff09dd06949488028fd819f4d83f56264efffffffff0200000000000000000b6a0930060201000201000180380100000000001976a9141cabd296e753837c086da7a45a6c2fe0d49d7b7b88ac00000000'
tx = '0100000000015ded05872fdbda629c7d3d02b194763ce3b9b1535ea884e3c8e765d42e316724020000006b48304502204c10d4064885c42638cbff3585915b322de33762598321145ba033fc796971e2022100bb153ad3baa8b757e30a2175bd32852d2e1cb9080f84d7e32fcdfd667934ef1b012103163c0ff73511ea1743fb5b98384a2ff09dd06949488028fd819f4d83f56264efffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe0010000000000000000000b6a0930060201000201000101ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe0010000000000013880001976a9141cabd296e753837c086da7a45a6c2fe0d49d7b7b88ac00000000'
rpc_result = self.nodes[0].decoderawtransaction(tx)
assert_equal('OP_RETURN 300602010002010001', rpc_result['vout'][0]['scriptPubKey']['asm'])
# verify that we have not altered scriptPubKey processing even of a specially crafted P2PKH pubkeyhash and P2SH redeem script hash that is made to pass the der signature checks
tx = '0100000000018d1f5635abd06e2c7e2ddf58dc85b3de111e4ad6e0ab51bb0dcf5e84126d927300000000fdfe0000483045022100ae3b4e589dfc9d48cb82d41008dc5fa6a86f94d5c54f9935531924602730ab8002202f88cf464414c4ed9fa11b773c5ee944f66e9b05cc1e51d97abc22ce098937ea01483045022100b44883be035600e9328a01b66c7d8439b74db64187e76b99a68f7893b701d5380220225bf286493e4c4adcf928c40f785422572eb232f84a0b83b0dea823c3a19c75014c695221020743d44be989540d27b1b4bbbcfd17721c337cb6bc9af20eb8a32520b393532f2102c0120a1dda9e51a938d39ddd9fe0ebc45ea97e1d27a7cbd671d5431416d3dd87210213820eb3d5f509d7438c9eeecb4157b2f595105e7cd564b3cdbb9ead3da41eed53aeffffffff02611e0000000000001976a914301102070101010101010102060101010101010188acee2a02000000000017a91430110207010101010101010206010101010101018700000000'
tx = '0100000000018d1f5635abd06e2c7e2ddf58dc85b3de111e4ad6e0ab51bb0dcf5e84126d927300000000fdfe0000483045022100ae3b4e589dfc9d48cb82d41008dc5fa6a86f94d5c54f9935531924602730ab8002202f88cf464414c4ed9fa11b773c5ee944f66e9b05cc1e51d97abc22ce098937ea01483045022100b44883be035600e9328a01b66c7d8439b74db64187e76b99a68f7893b701d5380220225bf286493e4c4adcf928c40f785422572eb232f84a0b83b0dea823c3a19c75014c695221020743d44be989540d27b1b4bbbcfd17721c337cb6bc9af20eb8a32520b393532f2102c0120a1dda9e51a938d39ddd9fe0ebc45ea97e1d27a7cbd671d5431416d3dd87210213820eb3d5f509d7438c9eeecb4157b2f595105e7cd564b3cdbb9ead3da41eed53aeffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe0010000000000001e61001976a914301102070101010101010102060101010101010188ac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe0010000000000022aee0017a91430110207010101010101010206010101010101018700000000'
rpc_result = self.nodes[0].decoderawtransaction(tx)
assert_equal('OP_DUP OP_HASH160 3011020701010101010101020601010101010101 OP_EQUALVERIFY OP_CHECKSIG', rpc_result['vout'][0]['scriptPubKey']['asm'])
assert_equal('OP_HASH160 3011020701010101010101020601010101010101 OP_EQUAL', rpc_result['vout'][1]['scriptPubKey']['asm'])

View file

@ -28,6 +28,7 @@ def get_unspent(listunspent, amount):
class RawTransactionsTest(BitcoinTestFramework):
def set_test_params(self):
self.num_nodes = 4
self.extra_args = [["-blindedaddresses=1"]] * self.num_nodes
self.setup_clean_chain = True
def skip_test_if_missing_module(self):
@ -55,6 +56,7 @@ class RawTransactionsTest(BitcoinTestFramework):
# = 2 bytes * minRelayTxFeePerByte
feeTolerance = 2 * min_relay_tx_fee/1000
# ELEMENTS NOTE: fee deltas will be negative due to blinding and no blinding in rawtransaction
self.nodes[2].generate(1)
self.sync_all()
@ -68,8 +70,10 @@ class RawTransactionsTest(BitcoinTestFramework):
watchonly_address = self.nodes[0].getnewaddress()
watchonly_pubkey = self.nodes[0].getaddressinfo(watchonly_address)["pubkey"]
watchonly_blindingkey = self.nodes[0].dumpblindingkey(watchonly_address)
watchonly_amount = Decimal(200)
self.nodes[3].importpubkey(watchonly_pubkey, "", True)
self.nodes[3].importblindingkey(watchonly_address, watchonly_blindingkey)
watchonly_txid = self.nodes[0].sendtoaddress(watchonly_address, watchonly_amount)
# Lock UTXO so nodes[0] doesn't accidentally spend it
@ -160,6 +164,8 @@ class RawTransactionsTest(BitcoinTestFramework):
dec_tx = self.nodes[2].decoderawtransaction(rawtxfund['hex'])
totalOut = 0
for out in dec_tx['vout']:
if out["scriptPubKey"]["type"] == "fee":
continue
totalOut += out['value']
assert_equal(fee + totalOut, utx['amount']) #compare vin total and totalout+fee
@ -181,6 +187,8 @@ class RawTransactionsTest(BitcoinTestFramework):
dec_tx = self.nodes[2].decoderawtransaction(rawtxfund['hex'])
totalOut = 0
for out in dec_tx['vout']:
if out["scriptPubKey"]["type"] == "fee":
continue
totalOut += out['value']
assert_equal(rawtxfund['changepos'], -1)
@ -228,6 +236,7 @@ class RawTransactionsTest(BitcoinTestFramework):
assert_equal(utx['txid'], dec_tx['vin'][0]['txid'])
change = self.nodes[2].getnewaddress()
change = self.nodes[2].getaddressinfo(change)["unconfidential"]
assert_raises_rpc_error(-8, "changePosition out of bounds", self.nodes[2].fundrawtransaction, rawtx, {'changeAddress':change, 'changePosition':2})
rawtxfund = self.nodes[2].fundrawtransaction(rawtx, {'changeAddress': change, 'changePosition': 0})
dec_tx = self.nodes[2].decoderawtransaction(rawtxfund['hex'])
@ -255,6 +264,7 @@ class RawTransactionsTest(BitcoinTestFramework):
inputs = [ {'txid' : utx['txid'], 'vout' : utx['vout']}]
outputs = { self.nodes[0].getnewaddress() : 1.0 }
output_addrs = [ self.nodes[0].getaddressinfo(addr)["unconfidential"] for addr in outputs.keys() ]
rawtx = self.nodes[2].createrawtransaction(inputs, outputs)
# 4-byte version + 1-byte vin count + 36-byte prevout then script_len
@ -270,8 +280,10 @@ class RawTransactionsTest(BitcoinTestFramework):
totalOut = 0
matchingOuts = 0
for i, out in enumerate(dec_tx['vout']):
if out["scriptPubKey"]["type"] == "fee":
continue
totalOut += out['value']
if out['scriptPubKey']['addresses'][0] in outputs:
if out['scriptPubKey']['addresses'][0] in output_addrs:
matchingOuts+=1
else:
assert_equal(i, rawtxfund['changepos'])
@ -280,7 +292,7 @@ class RawTransactionsTest(BitcoinTestFramework):
assert_equal("00", dec_tx['vin'][0]['scriptSig']['hex'])
assert_equal(matchingOuts, 1)
assert_equal(len(dec_tx['vout']), 2)
assert_equal(len(dec_tx['vout']), 3)
###########################################
@ -291,6 +303,7 @@ class RawTransactionsTest(BitcoinTestFramework):
inputs = [ {'txid' : utx['txid'], 'vout' : utx['vout']},{'txid' : utx2['txid'], 'vout' : utx2['vout']} ]
outputs = { self.nodes[0].getnewaddress() : 6.0 }
output_addrs = [ self.nodes[0].getaddressinfo(addr)["unconfidential"] for addr in outputs.keys() ]
rawtx = self.nodes[2].createrawtransaction(inputs, outputs)
dec_tx = self.nodes[2].decoderawtransaction(rawtx)
assert_equal(utx['txid'], dec_tx['vin'][0]['txid'])
@ -301,12 +314,14 @@ class RawTransactionsTest(BitcoinTestFramework):
totalOut = 0
matchingOuts = 0
for out in dec_tx['vout']:
if out["scriptPubKey"]["type"] == "fee":
continue
totalOut += out['value']
if out['scriptPubKey']['addresses'][0] in outputs:
if out['scriptPubKey']['addresses'][0] in output_addrs:
matchingOuts+=1
assert_equal(matchingOuts, 1)
assert_equal(len(dec_tx['vout']), 2)
assert_equal(len(dec_tx['vout']), 3)
matchingIns = 0
for vinOut in dec_tx['vin']:
@ -324,6 +339,7 @@ class RawTransactionsTest(BitcoinTestFramework):
inputs = [ {'txid' : utx['txid'], 'vout' : utx['vout']},{'txid' : utx2['txid'], 'vout' : utx2['vout']} ]
outputs = { self.nodes[0].getnewaddress() : 6.0, self.nodes[0].getnewaddress() : 1.0 }
output_addrs = [ self.nodes[0].getaddressinfo(addr)["unconfidential"] for addr in outputs.keys() ]
rawtx = self.nodes[2].createrawtransaction(inputs, outputs)
dec_tx = self.nodes[2].decoderawtransaction(rawtx)
assert_equal(utx['txid'], dec_tx['vin'][0]['txid'])
@ -334,12 +350,14 @@ class RawTransactionsTest(BitcoinTestFramework):
totalOut = 0
matchingOuts = 0
for out in dec_tx['vout']:
if out["scriptPubKey"]["type"] == "fee":
continue
totalOut += out['value']
if out['scriptPubKey']['addresses'][0] in outputs:
if out['scriptPubKey']['addresses'][0] in output_addrs:
matchingOuts+=1
assert_equal(matchingOuts, 2)
assert_equal(len(dec_tx['vout']), 3)
assert_equal(len(dec_tx['vout']), 4)
##############################################
# test a fundrawtransaction with invalid vin #
@ -364,7 +382,7 @@ class RawTransactionsTest(BitcoinTestFramework):
#compare fee
feeDelta = Decimal(fundedTx['fee']) - Decimal(signedFee)
assert(feeDelta >= 0 and feeDelta <= feeTolerance)
assert(feeDelta <= feeTolerance)
############################################################
############################################################
@ -379,7 +397,7 @@ class RawTransactionsTest(BitcoinTestFramework):
#compare fee
feeDelta = Decimal(fundedTx['fee']) - Decimal(signedFee)
assert(feeDelta >= 0 and feeDelta <= feeTolerance)
assert(feeDelta <= feeTolerance)
############################################################
@ -406,7 +424,7 @@ class RawTransactionsTest(BitcoinTestFramework):
#compare fee
feeDelta = Decimal(fundedTx['fee']) - Decimal(signedFee)
assert(feeDelta >= 0 and feeDelta <= feeTolerance)
assert(feeDelta <= feeTolerance)
############################################################
@ -439,7 +457,7 @@ class RawTransactionsTest(BitcoinTestFramework):
#compare fee
feeDelta = Decimal(fundedTx['fee']) - Decimal(signedFee)
assert(feeDelta >= 0 and feeDelta <= feeTolerance)
assert(feeDelta <= feeTolerance)
############################################################
@ -520,10 +538,11 @@ class RawTransactionsTest(BitcoinTestFramework):
outputs = {self.nodes[0].getnewaddress():1.1}
rawtx = self.nodes[1].createrawtransaction(inputs, outputs)
fundedTx = self.nodes[1].fundrawtransaction(rawtx)
blindedTx = self.nodes[1].blindrawtransaction(fundedTx['hex'])
#now we need to unlock
self.nodes[1].walletpassphrase("test", 600)
signedTx = self.nodes[1].signrawtransactionwithwallet(fundedTx['hex'])
signedTx = self.nodes[1].signrawtransactionwithwallet(blindedTx)
txId = self.nodes[1].sendrawtransaction(signedTx['hex'])
self.nodes[1].generate(1)
self.sync_all()
@ -552,6 +571,7 @@ class RawTransactionsTest(BitcoinTestFramework):
outputs = {self.nodes[0].getnewaddress():0.15,self.nodes[0].getnewaddress():0.04}
rawtx = self.nodes[1].createrawtransaction(inputs, outputs)
fundedTx = self.nodes[1].fundrawtransaction(rawtx)
blindedTx = self.nodes[1].blindrawtransaction(fundedTx['hex'])
#create same transaction over sendtoaddress
txId = self.nodes[1].sendmany("", outputs)
@ -559,7 +579,7 @@ class RawTransactionsTest(BitcoinTestFramework):
#compare fee
feeDelta = Decimal(fundedTx['fee']) - Decimal(signedFee)
assert(feeDelta >= 0 and feeDelta <= feeTolerance*19) #~19 inputs
assert(feeDelta <= feeTolerance*19) #~19 inputs
#############################################
@ -584,7 +604,8 @@ class RawTransactionsTest(BitcoinTestFramework):
outputs = {self.nodes[0].getnewaddress():0.15,self.nodes[0].getnewaddress():0.04}
rawtx = self.nodes[1].createrawtransaction(inputs, outputs)
fundedTx = self.nodes[1].fundrawtransaction(rawtx)
fundedAndSignedTx = self.nodes[1].signrawtransactionwithwallet(fundedTx['hex'])
blindedTx = self.nodes[1].blindrawtransaction(fundedTx['hex'])
fundedAndSignedTx = self.nodes[1].signrawtransactionwithwallet(blindedTx)
txId = self.nodes[1].sendrawtransaction(fundedAndSignedTx['hex'])
self.sync_all()
self.nodes[0].generate(1)
@ -597,7 +618,7 @@ class RawTransactionsTest(BitcoinTestFramework):
# pre-segwit
#rawtx = "0100000000010000000000000000066a047465737400000000"
rawtx = "010000000000010000000000000000066a047465737400000000"
rawtx = "0100000000000101ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000000000000066a047465737400000000"
dec_tx = self.nodes[2].decoderawtransaction(rawtx)
assert_equal(len(dec_tx['vin']), 0)
@ -607,7 +628,7 @@ class RawTransactionsTest(BitcoinTestFramework):
dec_tx = self.nodes[2].decoderawtransaction(rawtxfund['hex'])
assert_greater_than(len(dec_tx['vin']), 0) # at least one vin
assert_equal(len(dec_tx['vout']), 2) # one change output added
assert_equal(len(dec_tx['vout']), 3) # one change output added
##################################################
@ -636,7 +657,10 @@ class RawTransactionsTest(BitcoinTestFramework):
# Backward compatibility test (2nd param is includeWatching)
result = self.nodes[3].fundrawtransaction(rawtx, True)
res_dec = self.nodes[0].decoderawtransaction(result["hex"])
blinded_result = self.nodes[3].blindrawtransaction(result['hex'])
unblinded_result = self.nodes[3].unblindrawtransaction(blinded_result)
#res_dec = self.nodes[0].decoderawtransaction(blinded_result)
res_dec = self.nodes[0].decoderawtransaction(unblinded_result['hex'])
assert_equal(len(res_dec["vin"]), 2)
assert(res_dec["vin"][0]["txid"] == watchonly_txid or res_dec["vin"][1]["txid"] == watchonly_txid)
@ -644,7 +668,7 @@ class RawTransactionsTest(BitcoinTestFramework):
assert_greater_than(result["changepos"], -1)
assert_equal(result["fee"] + res_dec["vout"][result["changepos"]]["value"], watchonly_amount / 10)
signedtx = self.nodes[3].signrawtransactionwithwallet(result["hex"])
signedtx = self.nodes[3].signrawtransactionwithwallet(blinded_result)
assert(not signedtx["complete"])
signedtx = self.nodes[0].signrawtransactionwithwallet(signedtx["hex"])
assert(signedtx["complete"])

View file

@ -74,7 +74,8 @@ class RawTransactionsTest(BitcoinTestFramework):
assert_raises_rpc_error(-1, "createrawtransaction", self.nodes[0].createrawtransaction, [])
# Test `createrawtransaction` invalid extra parameters
assert_raises_rpc_error(-1, "createrawtransaction", self.nodes[0].createrawtransaction, [], {}, 0, False, 'foo')
# ELEMENTS: we have extra elements arguments
assert_raises_rpc_error(-1, "createrawtransaction", self.nodes[0].createrawtransaction, [], {}, 0, False, [], 'foo')
# Test `createrawtransaction` invalid `inputs`
txid = '1d1d4e24ed99057e84c3f80fd8fbec79ed9e1acee37da269356ecea000000000'
@ -297,6 +298,7 @@ class RawTransactionsTest(BitcoinTestFramework):
bal = self.nodes[0].getbalance()['bitcoin']
inputs = [{ "txid" : txId, "vout" : vout['n'], "scriptPubKey" : vout['scriptPubKey']['hex'], "amount" : vout['value']}]
outputs = { self.nodes[0].getnewaddress() : 2.19 }
outputs["fee"] = vout["value"] - Decimal('2.19')
rawTx = self.nodes[2].createrawtransaction(inputs, outputs)
rawTxPartialSigned = self.nodes[1].signrawtransactionwithwallet(rawTx, inputs)
assert_equal(rawTxPartialSigned['complete'], False) #node1 only has one key, can't comp. sign the tx
@ -342,6 +344,7 @@ class RawTransactionsTest(BitcoinTestFramework):
bal = self.nodes[0].getbalance()['bitcoin']
inputs = [{ "txid" : txId, "vout" : vout['n'], "scriptPubKey" : vout['scriptPubKey']['hex'], "redeemScript" : mSigObjValid['hex'], "amount" : vout['value']}]
outputs = { self.nodes[0].getnewaddress() : 2.19 }
outputs["fee"] = vout["value"] - Decimal('2.19')
rawTx2 = self.nodes[2].createrawtransaction(inputs, outputs)
rawTxPartialSigned1 = self.nodes[1].signrawtransactionwithwallet(rawTx2, inputs)
self.log.debug(rawTxPartialSigned1)
@ -363,7 +366,7 @@ class RawTransactionsTest(BitcoinTestFramework):
# witness transaction
# new in core:
#encrawtx = "010000000001010000000000000072c1a6a246ae63f74f931e8365e15a089c68d61900000000000000000000ffffffff0100e1f50500000000000102616100000000"
encrawtx = "0100000000010000000000000072c1a6a246ae63f74f931e8365e15a089c68d61900000000000000000000ffffffff0100e1f505000000000000000000"
encrawtx = "0100000001010000000000000072c1a6a246ae63f74f931e8365e15a089c68d61900000000000000000000ffffffff0101ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe0010000000005f5e100000000000000000001026161000000"
decrawtx = self.nodes[0].decoderawtransaction(encrawtx, True) # decode as witness transaction
assert_equal(decrawtx['vout'][0]['value'], Decimal('1.00000000'))

View file

@ -57,39 +57,39 @@ class ScantxoutsetTest(BitcoinTestFramework):
self.restart_node(0, ['-nowallet'])
self.log.info("Test if we have found the non HD unspent outputs.")
assert_equal(self.nodes[0].scantxoutset("start", [ "pkh(" + pubk1 + ")", "pkh(" + pubk2 + ")", "pkh(" + pubk3 + ")"])['total_amount'], Decimal("0.002"))
assert_equal(self.nodes[0].scantxoutset("start", [ "wpkh(" + pubk1 + ")", "wpkh(" + pubk2 + ")", "wpkh(" + pubk3 + ")"])['total_amount'], Decimal("0.004"))
assert_equal(self.nodes[0].scantxoutset("start", [ "sh(wpkh(" + pubk1 + "))", "sh(wpkh(" + pubk2 + "))", "sh(wpkh(" + pubk3 + "))"])['total_amount'], Decimal("0.001"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(" + pubk1 + ")", "combo(" + pubk2 + ")", "combo(" + pubk3 + ")"])['total_amount'], Decimal("0.007"))
assert_equal(self.nodes[0].scantxoutset("start", [ "addr(" + addr_P2SH_SEGWIT + ")", "addr(" + addr_LEGACY + ")", "addr(" + addr_BECH32 + ")"])['total_amount'], Decimal("0.007"))
assert_equal(self.nodes[0].scantxoutset("start", [ "addr(" + addr_P2SH_SEGWIT + ")", "addr(" + addr_LEGACY + ")", "combo(" + pubk3 + ")"])['total_amount'], Decimal("0.007"))
assert_equal(self.nodes[0].scantxoutset("start", [ "pkh(" + pubk1 + ")", "pkh(" + pubk2 + ")", "pkh(" + pubk3 + ")"])['total_unblinded_bitcoin_amount'], Decimal("0.002"))
assert_equal(self.nodes[0].scantxoutset("start", [ "wpkh(" + pubk1 + ")", "wpkh(" + pubk2 + ")", "wpkh(" + pubk3 + ")"])['total_unblinded_bitcoin_amount'], Decimal("0.004"))
assert_equal(self.nodes[0].scantxoutset("start", [ "sh(wpkh(" + pubk1 + "))", "sh(wpkh(" + pubk2 + "))", "sh(wpkh(" + pubk3 + "))"])['total_unblinded_bitcoin_amount'], Decimal("0.001"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(" + pubk1 + ")", "combo(" + pubk2 + ")", "combo(" + pubk3 + ")"])['total_unblinded_bitcoin_amount'], Decimal("0.007"))
assert_equal(self.nodes[0].scantxoutset("start", [ "addr(" + addr_P2SH_SEGWIT + ")", "addr(" + addr_LEGACY + ")", "addr(" + addr_BECH32 + ")"])['total_unblinded_bitcoin_amount'], Decimal("0.007"))
assert_equal(self.nodes[0].scantxoutset("start", [ "addr(" + addr_P2SH_SEGWIT + ")", "addr(" + addr_LEGACY + ")", "combo(" + pubk3 + ")"])['total_unblinded_bitcoin_amount'], Decimal("0.007"))
self.log.info("Test extended key derivation.")
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0'/0h/0h)"])['total_amount'], Decimal("0.008"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0'/0'/1h)"])['total_amount'], Decimal("0.016"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0h/0'/1500')"])['total_amount'], Decimal("0.032"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0h/0h/0)"])['total_amount'], Decimal("0.064"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0'/0h/1)"])['total_amount'], Decimal("0.128"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0h/0'/1500)"])['total_amount'], Decimal("0.256"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0'/0h/*h)", "range": 1499}])['total_amount'], Decimal("0.024"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0'/0'/*h)", "range": 1500}])['total_amount'], Decimal("0.056"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0h/0'/*)", "range": 1499}])['total_amount'], Decimal("0.192"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0'/0h/*)", "range": 1500}])['total_amount'], Decimal("0.448"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/0')"])['total_amount'], Decimal("0.512"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/1')"])['total_amount'], Decimal("1.024"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/1500h)"])['total_amount'], Decimal("2.048"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/0)"])['total_amount'], Decimal("4.096"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/1)"])['total_amount'], Decimal("8.192"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/1500)"])['total_amount'], Decimal("16.384"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tpubD6NzVbkrYhZ4WaWSyoBvQwbpLkojyoTZPRsgXELWz3Popb3qkjcJyJUGLnL4qHHoQvao8ESaAstxYSnhyswJ76uZPStJRJCTKvosUCJZL5B/1/1/0)"])['total_amount'], Decimal("4.096"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tpubD6NzVbkrYhZ4WaWSyoBvQwbpLkojyoTZPRsgXELWz3Popb3qkjcJyJUGLnL4qHHoQvao8ESaAstxYSnhyswJ76uZPStJRJCTKvosUCJZL5B/1/1/1)"])['total_amount'], Decimal("8.192"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tpubD6NzVbkrYhZ4WaWSyoBvQwbpLkojyoTZPRsgXELWz3Popb3qkjcJyJUGLnL4qHHoQvao8ESaAstxYSnhyswJ76uZPStJRJCTKvosUCJZL5B/1/1/1500)"])['total_amount'], Decimal("16.384"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/*')", "range": 1499}])['total_amount'], Decimal("1.536"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/*')", "range": 1500}])['total_amount'], Decimal("3.584"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/*)", "range": 1499}])['total_amount'], Decimal("12.288"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/*)", "range": 1500}])['total_amount'], Decimal("28.672"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tpubD6NzVbkrYhZ4WaWSyoBvQwbpLkojyoTZPRsgXELWz3Popb3qkjcJyJUGLnL4qHHoQvao8ESaAstxYSnhyswJ76uZPStJRJCTKvosUCJZL5B/1/1/*)", "range": 1499}])['total_amount'], Decimal("12.288"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tpubD6NzVbkrYhZ4WaWSyoBvQwbpLkojyoTZPRsgXELWz3Popb3qkjcJyJUGLnL4qHHoQvao8ESaAstxYSnhyswJ76uZPStJRJCTKvosUCJZL5B/1/1/*)", "range": 1500}])['total_amount'], Decimal("28.672"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0'/0h/0h)"])['total_unblinded_bitcoin_amount'], Decimal("0.008"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0'/0'/1h)"])['total_unblinded_bitcoin_amount'], Decimal("0.016"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0h/0'/1500')"])['total_unblinded_bitcoin_amount'], Decimal("0.032"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0h/0h/0)"])['total_unblinded_bitcoin_amount'], Decimal("0.064"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0'/0h/1)"])['total_unblinded_bitcoin_amount'], Decimal("0.128"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0h/0'/1500)"])['total_unblinded_bitcoin_amount'], Decimal("0.256"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0'/0h/*h)", "range": 1499}])['total_unblinded_bitcoin_amount'], Decimal("0.024"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0'/0'/*h)", "range": 1500}])['total_unblinded_bitcoin_amount'], Decimal("0.056"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0h/0'/*)", "range": 1499}])['total_unblinded_bitcoin_amount'], Decimal("0.192"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/0'/0h/*)", "range": 1500}])['total_unblinded_bitcoin_amount'], Decimal("0.448"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/0')"])['total_unblinded_bitcoin_amount'], Decimal("0.512"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/1')"])['total_unblinded_bitcoin_amount'], Decimal("1.024"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/1500h)"])['total_unblinded_bitcoin_amount'], Decimal("2.048"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/0)"])['total_unblinded_bitcoin_amount'], Decimal("4.096"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/1)"])['total_unblinded_bitcoin_amount'], Decimal("8.192"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/1500)"])['total_unblinded_bitcoin_amount'], Decimal("16.384"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tpubD6NzVbkrYhZ4WaWSyoBvQwbpLkojyoTZPRsgXELWz3Popb3qkjcJyJUGLnL4qHHoQvao8ESaAstxYSnhyswJ76uZPStJRJCTKvosUCJZL5B/1/1/0)"])['total_unblinded_bitcoin_amount'], Decimal("4.096"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tpubD6NzVbkrYhZ4WaWSyoBvQwbpLkojyoTZPRsgXELWz3Popb3qkjcJyJUGLnL4qHHoQvao8ESaAstxYSnhyswJ76uZPStJRJCTKvosUCJZL5B/1/1/1)"])['total_unblinded_bitcoin_amount'], Decimal("8.192"))
assert_equal(self.nodes[0].scantxoutset("start", [ "combo(tpubD6NzVbkrYhZ4WaWSyoBvQwbpLkojyoTZPRsgXELWz3Popb3qkjcJyJUGLnL4qHHoQvao8ESaAstxYSnhyswJ76uZPStJRJCTKvosUCJZL5B/1/1/1500)"])['total_unblinded_bitcoin_amount'], Decimal("16.384"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/*')", "range": 1499}])['total_unblinded_bitcoin_amount'], Decimal("1.536"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/*')", "range": 1500}])['total_unblinded_bitcoin_amount'], Decimal("3.584"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/*)", "range": 1499}])['total_unblinded_bitcoin_amount'], Decimal("12.288"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK/1/1/*)", "range": 1500}])['total_unblinded_bitcoin_amount'], Decimal("28.672"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tpubD6NzVbkrYhZ4WaWSyoBvQwbpLkojyoTZPRsgXELWz3Popb3qkjcJyJUGLnL4qHHoQvao8ESaAstxYSnhyswJ76uZPStJRJCTKvosUCJZL5B/1/1/*)", "range": 1499}])['total_unblinded_bitcoin_amount'], Decimal("12.288"))
assert_equal(self.nodes[0].scantxoutset("start", [ {"desc": "combo(tpubD6NzVbkrYhZ4WaWSyoBvQwbpLkojyoTZPRsgXELWz3Popb3qkjcJyJUGLnL4qHHoQvao8ESaAstxYSnhyswJ76uZPStJRJCTKvosUCJZL5B/1/1/*)", "range": 1500}])['total_unblinded_bitcoin_amount'], Decimal("28.672"))
if __name__ == '__main__':
ScantxoutsetTest().main()

View file

@ -112,7 +112,7 @@ class SignRawTransactionsTest(BitcoinTestFramework):
assert not rawTxSigned['errors'][0]['witness']
# Now test signing failure for transaction with input witnesses
p2wpkh_raw_tx = "010000000102fff7f7881a8099afa6940d42d1e7f6362bec38171ea3edf433541db4e4ad969f00000000494830450221008b9d1dc26ba6a9cb62127b02742fa9d754cd3bebf337f7a55d114c8e5cdd30be022040529b194ba3f9281a99f2b1c0a19c0489bc22ede944ccf4ecbab4cc618ef3ed01eeffffffef51e1b804cc89d182d279655c3aa89e815b1b309fe287d9b2b55d57b90ec68a0100000000ffffffff02202cb206000000001976a9148280b37df378db99f66f85c95a783a76ac7a6d5988ac9093510d000000001976a9143bde42dbee7e4dbe6a21b2d50ce2f0167faa815988ac1100000000000247304402203609e17b84f6a7d30c80bfa610b5b4542f32a8a0d5447a12fb1366d7f01cc44a0220573a954c4518331561406f90300e8f3358f51928d43c212a8caed02de67eebee0121025476c2e83188368da1ff3e292e7acafcdb3566bb0ad253f62fc70f07aeee635700"
p2wpkh_raw_tx = "010000000102fff7f7881a8099afa6940d42d1e7f6362bec38171ea3edf433541db4e4ad969f00000000494830450221008b9d1dc26ba6a9cb62127b02742fa9d754cd3bebf337f7a55d114c8e5cdd30be022040529b194ba3f9281a99f2b1c0a19c0489bc22ede944ccf4ecbab4cc618ef3ed01eeffffffef51e1b804cc89d182d279655c3aa89e815b1b309fe287d9b2b55d57b90ec68a0100000000ffffffff0201ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe0010000000006b22c20001976a9148280b37df378db99f66f85c95a783a76ac7a6d5988ac01ac2e6a47e85fdc2a5a27334544440f2f5135553a7476f4f5e3b9792da6a58fe001000000000d519390001976a9143bde42dbee7e4dbe6a21b2d50ce2f0167faa815988ac110000000000000000000247304402203609e17b84f6a7d30c80bfa610b5b4542f32a8a0d5447a12fb1366d7f01cc44a0220573a954c4518331561406f90300e8f3358f51928d43c212a8caed02de67eebee0121025476c2e83188368da1ff3e292e7acafcdb3566bb0ad253f62fc70f07aeee63570000000000"
rawTxSigned = self.nodes[0].signrawtransactionwithwallet(p2wpkh_raw_tx)

View file

@ -18,6 +18,8 @@ from .messages import (
CTxIn,
CTxInWitness,
CTxOut,
CTxOutAsset,
CTxOutValue,
FromHex,
ToHex,
bytes_to_hex_str,
@ -28,6 +30,7 @@ from .messages import (
sha256,
uint256_from_str,
CProof,
BITCOIN_ASSET_OUT,
)
from .script import (
CScript,
@ -80,13 +83,20 @@ def add_witness_commitment(block, nonce=0):
# First calculate the merkle root of the block's
# transactions, with witnesses.
witness_nonce = nonce
witness_root = block.calc_witness_merkle_root()
# ELEMENTS: add empty txout to end of coinbase tx
block.vtx[0].vout.append(CTxOut())
# block.vtx[0].vout[-1].nAsset.setNull() # TODO find out why this breaks stuff
# unless you directly put back in a valid .vchCommitment
witness_root_hex = block.calc_witness_merkle_root()
witness_root = uint256_from_str(hex_str_to_bytes(witness_root_hex)[::-1])
# witness_nonce should go to coinbase witness.
block.vtx[0].wit.vtxinwit = [CTxInWitness()]
block.vtx[0].wit.vtxinwit[0].scriptWitness.stack = [ser_uint256(witness_nonce)]
# witness commitment is the last OP_RETURN output in coinbase
block.vtx[0].vout.append(CTxOut(0, get_witness_script(witness_root, witness_nonce)))
block.vtx[0].vout[-1] = CTxOut(0, get_witness_script(witness_root, witness_nonce))
block.vtx[0].rehash()
block.hashMerkleRoot = block.calc_merkle_root()
block.rehash()
@ -115,9 +125,10 @@ def create_coinbase(height, pubkey=None):
coinbase.vin.append(CTxIn(COutPoint(0, 0xffffffff),
ser_string(serialize_script_num(height)), 0xffffffff))
coinbaseoutput = CTxOut()
coinbaseoutput.nValue = 50 * COIN
value = 50 * COIN
halvings = int(height / 150) # regtest
coinbaseoutput.nValue >>= halvings
value >>= halvings
coinbaseoutput.nValue = CTxOutValue(value)
if (pubkey is not None):
coinbaseoutput.scriptPubKey = CScript([pubkey, OP_CHECKSIG])
else:
@ -126,7 +137,7 @@ def create_coinbase(height, pubkey=None):
coinbase.calc_sha256()
return coinbase
def create_tx_with_script(prevtx, n, script_sig=b"", *, amount, script_pub_key=CScript()):
def create_tx_with_script(prevtx, n, script_sig=b"", *, amount, fee=0, script_pub_key=CScript()):
"""Return one-input, one-output transaction object
spending the prevtx's n-th output with the given amount.
@ -136,27 +147,29 @@ def create_tx_with_script(prevtx, n, script_sig=b"", *, amount, script_pub_key=C
assert(n < len(prevtx.vout))
tx.vin.append(CTxIn(COutPoint(prevtx.sha256, n), script_sig, 0xffffffff))
tx.vout.append(CTxOut(amount, script_pub_key))
if fee > 0:
tx.vout.append(CTxOut(fee))
tx.calc_sha256()
return tx
def create_transaction(node, txid, to_address, *, amount):
def create_transaction(node, txid, to_address, *, amount, fee):
""" Return signed transaction spending the first output of the
input txid. Note that the node must be able to sign for the
output that is being spent, and the node must not be running
multiple wallets.
"""
raw_tx = create_raw_transaction(node, txid, to_address, amount=amount)
raw_tx = create_raw_transaction(node, txid, to_address, amount=amount, fee=fee)
tx = CTransaction()
tx.deserialize(BytesIO(hex_str_to_bytes(raw_tx)))
return tx
def create_raw_transaction(node, txid, to_address, *, amount):
def create_raw_transaction(node, txid, to_address, *, amount, fee):
""" Return raw signed transaction spending the first output of the
input txid. Note that the node must be able to sign for the
output that is being spent, and the node must not be running
multiple wallets.
"""
rawtx = node.createrawtransaction(inputs=[{"txid": txid, "vout": 0}], outputs={to_address: amount})
rawtx = node.createrawtransaction(inputs=[{"txid": txid, "vout": 0}], outputs={to_address: amount, "fee": fee})
signresult = node.signrawtransactionwithwallet(rawtx)
assert_equal(signresult["complete"], True)
return signresult['hex']
@ -170,7 +183,7 @@ def get_legacy_sigopcount_block(block, accurate=True):
def get_legacy_sigopcount_tx(tx, accurate=True):
count = 0
for i in tx.vout:
count += i.scriptPubKey.GetSigOpCount(accurate)
count += CScript(i.scriptPubKey).GetSigOpCount(accurate)
for j in tx.vin:
# scriptSig might be of type bytes, so convert to CScript for the moment
count += CScript(j.scriptSig).GetSigOpCount(accurate)

View file

@ -269,6 +269,9 @@ class COutPoint():
self.hash = hash
self.n = n
def isNull(self):
return self.hash == 0 and self.n == 4294967295
def deserialize(self, f):
self.hash = deser_uint256(f)
self.n = struct.unpack("<I", f.read(4))[0]
@ -310,29 +313,139 @@ class CTxIn():
% (repr(self.prevout), bytes_to_hex_str(self.scriptSig),
self.nSequence)
class CTxOutAsset(object):
def __init__(self, vchCommitment=b"\x00"):
self.vchCommitment = vchCommitment
def setNull(self):
self.vchCommitment = b'\x00'
def deserialize(self, f):
version = ord(f.read(1))
if version == 0: self.vchCommitment = b'\x00'
elif version == 1: self.vchCommitment = b'\x01' + f.read(32)
elif version == 0xff: self.vchCommitment = b'\xff' + f.read(32)
elif version == 10 or version == 11: self.vchCommitment = bytes([version]) + f.read(32)
else: raise 'invalid CTxOutAsset in deserialize'
def serialize(self):
r = b""
r += self.vchCommitment
return r
def setToAsset(self, val):
if len(val) != 32:
raise 'invalid asset hash (expected 32 bytes got %d)' % len(val)
self.vchCommitment = b'\x01' + val
def __repr__(self):
return "CTxOutAsset(vchCommitment=%s)" % self.vchCommitment
class CTxOutValue(object):
def __init__(self, value=None):
self.setNull()
if value is not None:
self.setToAmount(value)
def setNull(self):
self.vchCommitment = b'\x00'
def deserialize(self, f):
version = ord(f.read(1))
if version == 0: self.vchCommitment = b'\x00'
elif version == 1: self.vchCommitment = b'\x01' + f.read(8)
elif version == 0xff: self.vchCommitment = b'\xff' + f.read(8)
elif version == 8 or version == 9: self.vchCommitment = bytes([version]) + f.read(32)
else: raise Exception('invalid CTxOutValue in deserialize. version %d' % version)
def serialize(self):
r = b""
if len(self.vchCommitment) < 1: raise ValueError('invalid commitment')
r += self.vchCommitment
return r
def setToAmount(self, amount):
commit = [1]*9
for i in range(8): #8 bytes
commit[8-i] = ((amount >> (i*8)) & 0xff)
self.vchCommitment = bytes(commit)
def getAmount(self):
if self.vchCommitment[0] != 1:
raise ValueError('getAmount() called on non-explicit CTxOutValue')
ret = 0
for i in range(8): #8 bytes
ret <<= 8
ret |= self.vchCommitment[i+1]
return ret
def __repr__(self):
return "CTxOutValue(vchCommitment=%s)" % self.vchCommitment
class CTxOutNonce(object):
def __init__(self, vchCommitment=b"\x00"):
self.vchCommitment = vchCommitment
def setNull(self):
self.vchCommitment = b'\x00'
def deserialize(self, f):
version = ord(f.read(1))
if version == 0: self.vchCommitment = b'\x00'
elif version == 1: self.vchCommitment = b'\x01' + f.read(32)
elif version == 0xff: self.vchCommitment = b'\xff' + f.read(32)
elif version == 2 or version == 3: self.vchCommitment = bytes([version]) + f.read(32)
else: raise ValueError('invalid CTxOutNonce in deserialize')
def serialize(self):
r = b""
r += self.vchCommitment
return r
def __repr__(self):
return "CTxOutNonce(vchCommitment=%s)" % self.vchCommitment
class CTxOut():
def __init__(self, nValue=0, scriptPubKey=b""):
self.nValue = nValue
def __init__(self, nValue=CTxOutValue(), scriptPubKey=b'', nAsset=CTxOutAsset(BITCOIN_ASSET_OUT), nNonce=CTxOutNonce()):
self.nAsset = nAsset
if type(nValue) is int:
self.nValue = CTxOutValue(nValue)
else:
self.nValue = nValue
self.nNonce = nNonce
self.scriptPubKey = scriptPubKey
def setNull(self):
self.nAsset.setNull()
self.nValue.setNull()
self.nNonce.setNull()
self.scriptPubKey = b''
def is_fee(self):
return len(self.scriptPubKey) == 0
def deserialize(self, f):
self.nValue = struct.unpack("<q", f.read(8))[0]
self.nAsset = CTxOutAsset()
self.nAsset.deserialize(f)
self.nValue = CTxOutValue()
self.nValue.deserialize(f)
self.nNonce = CTxOutNonce()
self.nNonce.deserialize(f)
self.scriptPubKey = deser_string(f)
def serialize(self):
r = b""
r += struct.pack("<q", self.nValue)
r += self.nAsset.serialize()
r += self.nValue.serialize()
r += self.nNonce.serialize()
r += ser_string(self.scriptPubKey)
return r
def __repr__(self):
return "CTxOut(nValue=%i.%08i scriptPubKey=%s)" \
% (self.nValue // COIN, self.nValue % COIN,
bytes_to_hex_str(self.scriptPubKey))
return "CTxOut(nAsset=%s nValue=%s nNonce=%s scriptPubKey=%s)" \
% (self.nAsset, self.nValue, self.nNonce, bytes_to_hex_str(self.scriptPubKey))
class CScriptWitness():
@ -358,23 +471,23 @@ class CTxInWitness(object):
self.peginWitness = CScriptWitness()
def deserialize(self, f):
#TODO(rebase) CA/CT
#self.vchIssuanceAmountRangeproof = deser_string(f)
#self.vchInflationKeysRangeproof = deser_string(f)
self.vchIssuanceAmountRangeproof = deser_string(f)
self.vchInflationKeysRangeproof = deser_string(f)
self.scriptWitness.stack = deser_string_vector(f)
self.peginWitness.stack = deser_string_vector(f)
def serialize(self):
r = b''
#TODO(rebase) CA/CT
#r += ser_string(self.vchIssuanceAmountRangeproof)
#r += ser_string(self.vchInflationKeysRangeproof)
r += ser_string(self.vchIssuanceAmountRangeproof)
r += ser_string(self.vchInflationKeysRangeproof)
r += ser_string_vector(self.scriptWitness.stack)
r += ser_string_vector(self.peginWitness.stack)
return r
def calc_witness_hash(self):
leaves = [
encode(hash256(ser_string(self.vchIssuanceAmountRangeproof))[::-1], 'hex_codec').decode('ascii'),
encode(hash256(ser_string(self.vchInflationKeysRangeproof))[::-1], 'hex_codec').decode('ascii'),
encode(hash256(ser_string_vector(self.scriptWitness.stack))[::-1], 'hex_codec').decode('ascii'),
encode(hash256(ser_string_vector(self.peginWitness.stack))[::-1], 'hex_codec').decode('ascii')
]
@ -386,8 +499,8 @@ class CTxInWitness(object):
def is_null(self):
return len(self.vchIssuanceAmountRangeproof) == 0 \
and len(self.vchInflationKeysRangeproof) == 0 \
and self.scriptWitness.is_null()
and len(self.vchInflationKeysRangeproof) == 0 \
and self.scriptWitness.is_null()
class CTxOutWitness(object):
@ -428,9 +541,8 @@ class CTxWitness(object):
def deserialize(self, f):
for i in range(len(self.vtxinwit)):
self.vtxinwit[i].deserialize(f)
#TODO(rebase) CA/CT
#for i in range(len(self.vtxoutwit)):
# self.vtxoutwit[i].deserialize(f)
for i in range(len(self.vtxoutwit)):
self.vtxoutwit[i].deserialize(f)
def serialize(self):
r = b""
@ -439,6 +551,8 @@ class CTxWitness(object):
# the same length as the transaction's vin vector.
for x in self.vtxinwit:
r += x.serialize()
for x in self.vtxoutwit:
r += x.serialize()
return r
def __repr__(self):
@ -513,14 +627,16 @@ class CTransaction(object):
r += ser_vector(self.vout)
r += struct.pack("<I", self.nLockTime)
if flags & 1:
if (len(self.wit.vtxinwit) != len(self.vin)):
if len(self.wit.vtxinwit) != len(self.vin):
# vtxinwit must have the same length as vin
self.wit.vtxinwit = self.wit.vtxinwit[:len(self.vin)]
for i in range(len(self.wit.vtxinwit), len(self.vin)):
self.wit.vtxinwit.append(CTxInWitness())
if len(self.wit.vtxoutwit) != len(self.vout):
# vtxoutwit must have the same length as vout
self.wit.vtxoutwit = self.wit.vtxoutwit[:len(self.vout)]
for i in range(len(self.wit.vtxoutwit), len(self.vout)):
self.wit.vtxoutwit.append(CTxInWitness())
self.wit.vtxoutwit.append(CTxOutWitness())
r += self.wit.serialize()
return r
@ -546,7 +662,10 @@ class CTransaction(object):
def calc_witness_hash(self):
leaves = []
for i in range(len(self.vin)):
wit = self.wit.vtxinwit[i] if i < len(self.wit.vtxinwit) else CTxInWitness()
if i >= len(self.wit.vtxinwit) or self.vin[i].prevout.isNull():
wit = CTxInWitness()
else:
wit = self.wit.vtxinwit[i]
leaves.append(wit.calc_witness_hash())
inwitroot = calcfastmerkleroot(leaves)
@ -556,7 +675,8 @@ class CTransaction(object):
leaves.append(wit.calc_witness_hash())
outwitroot = calcfastmerkleroot(leaves)
return uint256_from_str(hex_str_to_bytes(calcfastmerkleroot([inwitroot, outwitroot]))[::-1])
# returns bitcoin hash print style string
return calcfastmerkleroot([inwitroot, outwitroot])
def is_valid(self):
self.calc_sha256()
@ -704,15 +824,13 @@ class CBlock(CBlockHeader):
return self.get_merkle_root(hashes)
def calc_witness_merkle_root(self):
# For witness root purposes, the hash of the
# coinbase, with witness, is defined to be 0...0
hashes = [ser_uint256(0)]
for tx in self.vtx[1:]:
hashes = []
for tx in self.vtx:
# Calculate the hashes with witness data
hashes.append(ser_uint256(tx.calc_witness_hash()))
hashes.append(tx.calc_witness_hash())
return self.get_merkle_root(hashes)
# returns bitcoin hash print order hex string
return calcfastmerkleroot(hashes)
def is_valid(self):
self.calc_sha256()

View file

@ -671,6 +671,7 @@ def SegwitVersion1SignatureHash(script, txTo, inIdx, hashtype, amount):
hashPrevouts = 0
hashSequence = 0
hashIssuance = 0
hashOutputs = 0
if not (hashtype & SIGHASH_ANYONECANPAY):
@ -685,6 +686,13 @@ def SegwitVersion1SignatureHash(script, txTo, inIdx, hashtype, amount):
serialize_sequence += struct.pack("<I", i.nSequence)
hashSequence = uint256_from_str(hash256(serialize_sequence))
if not (hashtype & SIGHASH_ANYONECANPAY):
serialize_issuance = bytes()
# TODO actually serialize issuances
for _ in txTo.vin:
serialize_issuance += b'\x00'
hashIssuance = uint256_from_str(hash256(serialize_issuance))
if ((hashtype & 0x1f) != SIGHASH_SINGLE and (hashtype & 0x1f) != SIGHASH_NONE):
serialize_outputs = bytes()
for o in txTo.vout:
@ -698,9 +706,10 @@ def SegwitVersion1SignatureHash(script, txTo, inIdx, hashtype, amount):
ss += struct.pack("<i", txTo.nVersion)
ss += ser_uint256(hashPrevouts)
ss += ser_uint256(hashSequence)
ss += ser_uint256(hashIssuance)
ss += txTo.vin[inIdx].prevout.serialize()
ss += ser_string(script)
ss += struct.pack("<q", amount)
ss += amount.serialize()
ss += struct.pack("<I", txTo.vin[inIdx].nSequence)
ss += ser_uint256(hashOutputs)
ss += struct.pack("<i", txTo.nLockTime)

View file

@ -319,6 +319,7 @@ def initialize_datadir(dirname, n, chain):
f.write("listenonion=0\n")
f.write("printtoconsole=0\n")
# Elements:
f.write("con_parent_pegged_asset=" + BITCOIN_ASSET + "\n")
f.write("con_blocksubsidy=5000000000\n")
f.write("con_connect_coinbase=0\n")
f.write("anyonecanspendaremine=0\n")
@ -327,6 +328,7 @@ def initialize_datadir(dirname, n, chain):
f.write("con_bip65height=1351\n")
f.write("con_bip66height=1251\n")
f.write("con_csv_deploy_start=0\n") # Enhance tests if removing this line
f.write("blindedaddresses=0\n") # Set to minimize broken tests in favor of custom
os.makedirs(os.path.join(datadir, 'stderr'), exist_ok=True)
os.makedirs(os.path.join(datadir, 'stdout'), exist_ok=True)
return datadir
@ -543,7 +545,7 @@ def gen_return_txouts():
from .messages import CTxOut, CTxOutValue
for k in range(128):
txout = CTxOut()
txout.nValue = 0
txout.nValue = CTxOutValue(0)
txout.scriptPubKey = hex_str_to_bytes(script_pubkey)
txouts.append(txout)
return txouts
@ -591,7 +593,10 @@ def find_vout_for_address(node, txid, addr):
given address. Raises runtime error exception if not found.
"""
tx = node.getrawtransaction(txid, True)
unblind_addr = node.validateaddress(addr)["unconfidential"]
for i in range(len(tx["vout"])):
if any([addr == a for a in tx["vout"][i]["scriptPubKey"]["addresses"]]):
if tx["vout"][i]["scriptPubKey"]["type"] == "fee":
continue
if any([unblind_addr == a for a in tx["vout"][i]["scriptPubKey"]["addresses"]]):
return i
raise RuntimeError("Vout not found for address: txid=%s, addr=%s" % (txid, addr))

View file

@ -68,7 +68,11 @@ BASE_SCRIPTS = [
'rpc_calcfastmerkleroot.py',
'feature_txwitness.py',
'rpc_tweakfedpeg.py',
'feature_issuance.py',
'feature_confidential_transactions.py',
'feature_default_asset_name.py',
'feature_assetsdir.py',
'feature_initial_reissuance_token.py',
# Longest test should go first, to favor running tests in parallel
'feature_fee_estimation.py',
'wallet_hd.py',

View file

@ -59,6 +59,7 @@ class AbandonConflictTest(BitcoinTestFramework):
outputs[self.nodes[0].getnewaddress()] = Decimal("14.99998")
outputs[self.nodes[1].getnewaddress()] = Decimal("5")
outputs["fee"] = 2 * Decimal('10') - Decimal('14.99998') - Decimal('5')
signed = self.nodes[0].signrawtransactionwithwallet(self.nodes[0].createrawtransaction(inputs, outputs))
txAB1 = self.nodes[0].sendrawtransaction(signed["hex"])
@ -71,6 +72,7 @@ class AbandonConflictTest(BitcoinTestFramework):
inputs.append({"txid":txC, "vout":nC})
outputs = {}
outputs[self.nodes[0].getnewaddress()] = Decimal("24.9996")
outputs["fee"] = Decimal('14.99998') + Decimal('10') - Decimal('24.9996')
signed2 = self.nodes[0].signrawtransactionwithwallet(self.nodes[0].createrawtransaction(inputs, outputs))
txABC2 = self.nodes[0].sendrawtransaction(signed2["hex"])
@ -78,6 +80,7 @@ class AbandonConflictTest(BitcoinTestFramework):
signed3_change = Decimal("24.999")
inputs = [ {"txid":txABC2, "vout":0} ]
outputs = { self.nodes[0].getnewaddress(): signed3_change }
outputs["fee"] = Decimal('24.9996') - signed3_change
signed3 = self.nodes[0].signrawtransactionwithwallet(self.nodes[0].createrawtransaction(inputs, outputs))
# note tx is never directly referenced, only abandoned as a child of the above
self.nodes[0].sendrawtransaction(signed3["hex"])
@ -149,6 +152,7 @@ class AbandonConflictTest(BitcoinTestFramework):
inputs.append({"txid":txA, "vout":nA})
outputs = {}
outputs[self.nodes[1].getnewaddress()] = Decimal("9.9999")
outputs["fee"] = Decimal('10') - Decimal('9.9999')
tx = self.nodes[0].createrawtransaction(inputs, outputs)
signed = self.nodes[0].signrawtransactionwithwallet(tx)
self.nodes[1].sendrawtransaction(signed["hex"])

View file

@ -153,11 +153,12 @@ class AddressTypeTest(BitcoinTestFramework):
tx = self.nodes[node_sender].decoderawtransaction(raw_tx)
# Make sure the transaction has change:
assert_equal(len(tx["vout"]), len(destinations) + 1)
assert_equal(len(tx["vout"]), len(destinations) + 2)
# Make sure the destinations are included, and remove them:
output_addresses = [vout['scriptPubKey']['addresses'][0] for vout in tx["vout"]]
change_addresses = [d for d in output_addresses if d not in destinations]
output_addresses = [vout['scriptPubKey']['addresses'][0] for vout in tx["vout"] if vout["scriptPubKey"]["type"] != "fee"]
unconfidential_destinations = [self.nodes[node_sender].getaddressinfo(addr)["unconfidential"] for addr in destinations]
change_addresses = [d for d in output_addresses if d not in unconfidential_destinations]
assert_equal(len(change_addresses), 1)
self.log.debug("Check if change address " + change_addresses[0] + " is " + expected_type)

View file

@ -173,6 +173,7 @@ class WalletTest(BitcoinTestFramework):
outputs = {}
inputs.append({"txid": utxo["txid"], "vout": utxo["vout"]})
outputs[self.nodes[2].getnewaddress()] = utxo["amount"] - 3
outputs["fee"] = 3
raw_tx = self.nodes[0].createrawtransaction(inputs, outputs)
txns_to_send.append(self.nodes[0].signrawtransactionwithwallet(raw_tx))
@ -260,7 +261,8 @@ class WalletTest(BitcoinTestFramework):
signed_raw_tx = self.nodes[1].signrawtransactionwithwallet(raw_tx)
decoded_raw_tx = self.nodes[1].decoderawtransaction(signed_raw_tx['hex'])
zero_value_txid = decoded_raw_tx['txid']
self.nodes[1].sendrawtransaction(signed_raw_tx['hex'])
# ELEMENTS: this test doesn't make sense
#self.nodes[1].sendrawtransaction(signed_raw_tx['hex'])
self.sync_all()
self.nodes[1].generate(1) # mine a block
@ -272,7 +274,8 @@ class WalletTest(BitcoinTestFramework):
if uTx['txid'] == zero_value_txid:
found = True
assert_equal(uTx['amount'], Decimal('0'))
assert(found)
# ELEMENTS: this test doesn't make sense
#assert(found)
# do some -walletbroadcast tests
self.stop_nodes()
@ -340,7 +343,7 @@ class WalletTest(BitcoinTestFramework):
# Import address and private key to check correct behavior of spendable unspents
# 1. Send some coins to generate new UTXO
address_to_import = self.nodes[2].getnewaddress()
address_to_import = self.nodes[2].getaddressinfo(self.nodes[2].getnewaddress())["confidential"]
txid = self.nodes[0].sendtoaddress(address_to_import, 1)
self.nodes[0].generate(1)
self.sync_all([self.nodes[0:3]])
@ -349,11 +352,14 @@ class WalletTest(BitcoinTestFramework):
self.nodes[1].importaddress(address_to_import)
# 3. Validate that the imported address is watch-only on node1
# ELEMENTS: not watching without blinding key, watchonly with blinding key
assert(not self.nodes[1].getaddressinfo(address_to_import)["iswatchonly"])
self.nodes[1].importblindingkey(address_to_import, self.nodes[2].dumpblindingkey(address_to_import))
assert(self.nodes[1].getaddressinfo(address_to_import)["iswatchonly"])
# 4. Check that the unspents after import are not spendable
assert_array_result(self.nodes[1].listunspent(),
{"address": address_to_import},
{"address": self.nodes[1].getaddressinfo(address_to_import)["unconfidential"]},
{"spendable": False})
# 5. Import private key of the previously imported address on node1
@ -362,7 +368,7 @@ class WalletTest(BitcoinTestFramework):
# 6. Check that the unspents are now spendable on node1
assert_array_result(self.nodes[1].listunspent(),
{"address": address_to_import},
{"address": self.nodes[1].getaddressinfo(address_to_import)["unconfidential"]},
{"spendable": True})
# Mine a block from node0 to an address from node1

View file

@ -89,7 +89,7 @@ def test_simple_bumpfee_succeeds(rbf_node, peer_node, dest_address):
assert rbfid in rbf_node.getrawmempool() and rbfid in peer_node.getrawmempool()
bumped_tx = rbf_node.bumpfee(rbfid)
assert_equal(bumped_tx["errors"], [])
assert bumped_tx["fee"] - abs(rbftx["fee"]) > 0
assert bumped_tx["fee"] - abs(rbftx["fee"]['bitcoin']) > 0
# check that bumped_tx propagates, original tx was evicted and has a wallet conflict
sync_mempools((rbf_node, peer_node))
assert bumped_tx["txid"] in rbf_node.getrawmempool()
@ -125,7 +125,8 @@ def test_segwit_bumpfee_succeeds(rbf_node, dest_address):
'vout': 0,
"sequence": BIP125_SEQUENCE_NUMBER
}], {dest_address: Decimal("0.0005"),
rbf_node.getrawchangeaddress(): Decimal("0.0003")})
rbf_node.getrawchangeaddress(): Decimal("0.0003"),
"fee": "0.0001"})
rbfsigned = rbf_node.signrawtransactionwithwallet(rbfraw)
rbfid = rbf_node.sendrawtransaction(rbfsigned["hex"])
assert rbfid in rbf_node.getrawmempool()
@ -154,7 +155,7 @@ def test_notmine_bumpfee_fails(rbf_node, peer_node, dest_address):
"sequence": BIP125_SEQUENCE_NUMBER
} for utxo in utxos]
output_val = sum(utxo["amount"] for utxo in utxos) - Decimal("0.001")
rawtx = rbf_node.createrawtransaction(inputs, {dest_address: output_val})
rawtx = rbf_node.createrawtransaction(inputs, {dest_address: output_val, "fee": "0.001"})
signedtx = rbf_node.signrawtransactionwithwallet(rawtx)
signedtx = peer_node.signrawtransactionwithwallet(signedtx["hex"])
rbfid = rbf_node.sendrawtransaction(signedtx["hex"])
@ -166,7 +167,8 @@ def test_bumpfee_with_descendant_fails(rbf_node, rbf_node_address, dest_address)
# cannot bump fee if the transaction has a descendant
# parent is send-to-self, so we don't have to check which output is change when creating the child tx
parent_id = spend_one_input(rbf_node, rbf_node_address)
tx = rbf_node.createrawtransaction([{"txid": parent_id, "vout": 0}], {dest_address: 0.00020000})
input_val = rbf_node.getrawtransaction(parent_id, 1)["vout"][0]["value"]
tx = rbf_node.createrawtransaction([{"txid": parent_id, "vout": 0}], {dest_address: "0.0002", "fee": input_val-Decimal("0.0002")})
tx = rbf_node.signrawtransactionwithwallet(tx)
rbf_node.sendrawtransaction(tx["hex"])
assert_raises_rpc_error(-8, "Transaction has descendants in the wallet", rbf_node.bumpfee, parent_id)
@ -192,8 +194,8 @@ def test_dust_to_fee(rbf_node, dest_address):
bumped_tx = rbf_node.bumpfee(rbfid, {"totalFee": 50000-1800})
full_bumped_tx = rbf_node.getrawtransaction(bumped_tx["txid"], 1)
assert_equal(bumped_tx["fee"], Decimal("0.00050000"))
assert_equal(len(fulltx["vout"]), 2)
assert_equal(len(full_bumped_tx["vout"]), 1) #change output is eliminated
assert_equal(len(fulltx["vout"]), 3)
assert_equal(len(full_bumped_tx["vout"]), 2) #change output is eliminated
def test_settxfee(rbf_node, dest_address):
@ -261,13 +263,16 @@ def test_unconfirmed_not_spendable(rbf_node, rbf_node_address):
# check that the main output from the rbf tx is spendable after confirmed
rbf_node.generate(1)
rbf_node_address_unconfidential = rbf_node.getaddressinfo(rbf_node_address)["unconfidential"]
assert_equal(
sum(1 for t in rbf_node.listunspent(minconf=0, include_unsafe=False)
if t["txid"] == rbfid and t["address"] == rbf_node_address and t["spendable"]), 1)
if t["txid"] == rbfid and t["address"] == rbf_node_address_unconfidential and t["spendable"]), 1)
def test_bumpfee_metadata(rbf_node, dest_address):
rbfid = rbf_node.sendtoaddress(dest_address, Decimal("0.00100000"), "comment value", "to value")
assert(rbf_node.getbalance()["bitcoin"] < 49)
rbf_node.generatetoaddress(101, rbf_node.getnewaddress())
rbfid = rbf_node.sendtoaddress(dest_address, 49, "comment value", "to value")
bumped_tx = rbf_node.bumpfee(rbfid)
bumped_wtx = rbf_node.gettransaction(bumped_tx["txid"])
assert_equal(bumped_wtx["comment"], "comment value")
@ -286,7 +291,8 @@ def spend_one_input(node, dest_address):
sequence=BIP125_SEQUENCE_NUMBER, **next(u for u in node.listunspent() if u["amount"] == Decimal("0.00100000")))
rawtx = node.createrawtransaction(
[tx_input], {dest_address: Decimal("0.00050000"),
node.getrawchangeaddress(): Decimal("0.00049000")})
node.getrawchangeaddress(): Decimal("0.00049000"),
"fee": Decimal("0.00001")})
signedtx = node.signrawtransactionwithwallet(rawtx)
txid = node.sendrawtransaction(signedtx["hex"])
return txid

View file

@ -59,13 +59,13 @@ def read_dump(file_name, addrs, script_addrs, hd_master_addr_old):
# count key types
for addrObj in addrs:
if addrObj['address'] == addr.split(",")[0] and addrObj['hdkeypath'] == keypath and keytype == "label=":
if addrObj['unconfidential'] == addr.split(",")[0] and addrObj['hdkeypath'] == keypath and keytype == "label=":
# a labeled entry in the wallet should contain both a native address
# and the p2sh-p2wpkh address that was added at wallet setup
if len(addr.split(",")) == 2:
addr_list = addr.split(",")
# the entry should be of the first key in the wallet
assert_equal(addrs[0]['address'], addr_list[0])
assert_equal(addrs[0]['unconfidential'], addr_list[0])
witness_addr_ret = addr_list[1]
found_addr += 1
break

View file

@ -51,9 +51,9 @@ class WalletGroupTest(BitcoinTestFramework):
tx1 = self.nodes[1].getrawtransaction(txid1, True)
# txid1 should have 1 input and 2 outputs
assert_equal(1, len(tx1["vin"]))
assert_equal(2, len(tx1["vout"]))
assert_equal(2+1, len(tx1["vout"]))
# one output should be 0.2, the other should be ~0.3
v = [vout["value"] for vout in tx1["vout"]]
v = [vout["value"] for vout in tx1["vout"] if vout["scriptPubKey"]["type"] != "fee"]
v.sort()
assert_approx(v[0], 0.2)
assert_approx(v[1], 0.3, 0.0001)
@ -62,9 +62,9 @@ class WalletGroupTest(BitcoinTestFramework):
tx2 = self.nodes[2].getrawtransaction(txid2, True)
# txid2 should have 2 inputs and 2 outputs
assert_equal(2, len(tx2["vin"]))
assert_equal(2, len(tx2["vout"]))
assert_equal(2+1, len(tx2["vout"]))
# one output should be 0.2, the other should be ~1.3
v = [vout["value"] for vout in tx2["vout"]]
v = [vout["value"] for vout in tx2["vout"] if vout["scriptPubKey"]["type"] != "fee"]
v.sort()
assert_approx(v[0], 0.2)
assert_approx(v[1], 1.3, 0.0001)
@ -77,10 +77,11 @@ class WalletGroupTest(BitcoinTestFramework):
# Fill node2's wallet with 10000 outputs corresponding to the same
# scriptPubKey
for i in range(5):
raw_tx = self.nodes[0].createrawtransaction([{"txid":"0"*64, "vout":0}], [{addr2[0]: 0.05}])
raw_tx = self.nodes[0].createrawtransaction([{"txid":"0"*64, "vout":0}], [{addr2[0]: 0.10}])
tx = FromHex(CTransaction(), raw_tx)
tx.vin = []
tx.vout = [tx.vout[0]] * 2000
# ELEMENTS: lower number because outputs are bigger (otherwise tx gets too large)
tx.vout = [tx.vout[0]] * 1000
funded_tx = self.nodes[0].fundrawtransaction(ToHex(tx))
signed_tx = self.nodes[0].signrawtransactionwithwallet(funded_tx['hex'])
self.nodes[0].sendrawtransaction(signed_tx['hex'])

View file

@ -123,6 +123,8 @@ class WalletHDTest(BitcoinTestFramework):
outs = self.nodes[1].decoderawtransaction(self.nodes[1].gettransaction(txid)['hex'])['vout']
keypath = ""
for out in outs:
if out["scriptPubKey"]["type"] == "fee":
continue
if out['value'] != 1:
keypath = self.nodes[1].getaddressinfo(out['scriptPubKey']['addresses'][0])['hdkeypath']

View file

@ -72,10 +72,11 @@ class Variant(collections.namedtuple("Variant", "call data rescan prune")):
if self.expected_txs:
assert_equal(len(addresses[0]["txids"]), self.expected_txs)
unconfidential_address = self.node.getaddressinfo(self.address["address"])["unconfidential"]
if txid is not None:
address, = [ad for ad in addresses if txid in ad["txids"]]
assert_equal(address["address"], self.address["address"])
assert_equal(address["amount"], self.expected_balance)
assert(address["address"] == self.address["address"] or address["address"] == unconfidential_address)
assert_equal(address["amount"], {"bitcoin": self.expected_balance})
assert_equal(address["confirmations"], confirmations)
# Verify the transaction is correctly marked watchonly depending on
# whether the transaction pays to an imported public key or

View file

@ -56,6 +56,8 @@ class ImportMultiTest(BitcoinTestFramework):
"address": address['address']
},
"timestamp": "now",
# ELEMENTS: Also import blinding key
"blinding_privkey": self.nodes[0].dumpblindingkey(address["confidential"]),
}])
assert_equal(result[0]['success'], True)
address_assert = self.nodes[1].getaddressinfo(address['address'])
@ -82,7 +84,9 @@ class ImportMultiTest(BitcoinTestFramework):
result = self.nodes[1].importmulti([{
"scriptPubKey": address['scriptPubKey'],
"timestamp": "now",
"internal": True
"internal": True,
# ELEMENTS: Also import blinding key
"blinding_privkey": self.nodes[0].dumpblindingkey(address["confidential"]),
}])
assert_equal(result[0]['success'], True)
address_assert = self.nodes[1].getaddressinfo(address['address'])
@ -97,6 +101,8 @@ class ImportMultiTest(BitcoinTestFramework):
result = self.nodes[1].importmulti([{
"scriptPubKey": nonstandardScriptPubKey,
"timestamp": "now",
# ELEMENTS: Also import blinding key
"blinding_privkey": self.nodes[0].dumpblindingkey(address["confidential"]),
}])
assert_equal(result[0]['success'], False)
assert_equal(result[0]['error']['code'], -8)
@ -115,7 +121,9 @@ class ImportMultiTest(BitcoinTestFramework):
"address": address['address']
},
"timestamp": "now",
"pubkeys": [ address['pubkey'] ]
"pubkeys": [ address['pubkey'] ],
# ELEMENTS: Also import blinding key
"blinding_privkey": self.nodes[0].dumpblindingkey(address["confidential"]),
}])
assert_equal(result[0]['success'], True)
address_assert = self.nodes[1].getaddressinfo(address['address'])
@ -131,7 +139,9 @@ class ImportMultiTest(BitcoinTestFramework):
"scriptPubKey": address['scriptPubKey'],
"timestamp": "now",
"pubkeys": [ address['pubkey'] ],
"internal": True
"internal": True,
# ELEMENTS: Also import blinding key
"blinding_privkey": self.nodes[0].dumpblindingkey(address["confidential"]),
}]
result = self.nodes[1].importmulti(request)
assert_equal(result[0]['success'], True)
@ -165,7 +175,9 @@ class ImportMultiTest(BitcoinTestFramework):
"address": address['address']
},
"timestamp": "now",
"keys": [ self.nodes[0].dumpprivkey(address['address']) ]
"keys": [ self.nodes[0].dumpprivkey(address['address']) ],
# ELEMENTS: Also import blinding key
"blinding_privkey": self.nodes[0].dumpblindingkey(address["confidential"]),
}])
assert_equal(result[0]['success'], True)
address_assert = self.nodes[1].getaddressinfo(address['address'])
@ -179,7 +191,9 @@ class ImportMultiTest(BitcoinTestFramework):
"address": address['address']
},
"timestamp": "now",
"keys": [ self.nodes[0].dumpprivkey(address['address']) ]
"keys": [ self.nodes[0].dumpprivkey(address['address']) ],
# ELEMENTS: Also import blinding key
"blinding_privkey": self.nodes[0].dumpblindingkey(address["confidential"]),
}])
assert_equal(result[0]['success'], False)
assert_equal(result[0]['error']['code'], -4)
@ -194,7 +208,9 @@ class ImportMultiTest(BitcoinTestFramework):
},
"timestamp": "now",
"keys": [ self.nodes[0].dumpprivkey(address['address']) ],
"watchonly": True
"watchonly": True,
# ELEMENTS: Also import blinding key
"blinding_privkey": self.nodes[0].dumpblindingkey(address["confidential"]),
}])
assert_equal(result[0]['success'], False)
assert_equal(result[0]['error']['code'], -8)
@ -211,7 +227,9 @@ class ImportMultiTest(BitcoinTestFramework):
"scriptPubKey": address['scriptPubKey'],
"timestamp": "now",
"keys": [ self.nodes[0].dumpprivkey(address['address']) ],
"internal": True
"internal": True,
# ELEMENTS: Also import blinding key
"blinding_privkey": self.nodes[0].dumpblindingkey(address["confidential"]),
}])
assert_equal(result[0]['success'], True)
address_assert = self.nodes[1].getaddressinfo(address['address'])

View file

@ -16,6 +16,7 @@ class ImportPrunedFundsTest(BitcoinTestFramework):
def set_test_params(self):
self.setup_clean_chain = True
self.num_nodes = 2
self.extra_args = [["-blindedaddresses=1"]] * self.num_nodes
def skip_test_if_missing_module(self):
self.skip_if_no_wallet()
@ -30,8 +31,10 @@ class ImportPrunedFundsTest(BitcoinTestFramework):
address1 = self.nodes[0].getnewaddress()
# pubkey
address2 = self.nodes[0].getnewaddress()
address2_blindingkey = self.nodes[0].dumpblindingkey(address2)
# privkey
address3 = self.nodes[0].getnewaddress()
address3_blindingkey = self.nodes[0].dumpblindingkey(address3)
address3_privkey = self.nodes[0].dumpprivkey(address3) # Using privkey
# Check only one address
@ -82,11 +85,13 @@ class ImportPrunedFundsTest(BitcoinTestFramework):
# Import with affiliated address with no rescan
self.nodes[1].importaddress(address=address2, rescan=False)
self.nodes[1].importblindingkey(address2, address2_blindingkey)
self.nodes[1].importprunedfunds(rawtxn2, proof2)
assert [tx for tx in self.nodes[1].listtransactions(include_watchonly=True) if tx['txid'] == txnid2]
# Import with private key with no rescan
self.nodes[1].importprivkey(privkey=address3_privkey, rescan=False)
self.nodes[1].importblindingkey(address3, address3_blindingkey)
self.nodes[1].importprunedfunds(rawtxn3, proof3)
assert [tx for tx in self.nodes[1].listtransactions() if tx['txid'] == txnid3]
balance3 = self.nodes[1].getbalance()['bitcoin']

View file

@ -88,8 +88,8 @@ class WalletLabelsTest(BitcoinTestFramework):
node.generate(1)
for label in labels:
assert_equal(
node.getreceivedbyaddress(label.addresses[0]), amount_to_send)
assert_equal(node.getreceivedbylabel(label.name), amount_to_send)
node.getreceivedbyaddress(label.addresses[0])['bitcoin'], amount_to_send)
assert_equal(node.getreceivedbylabel(label.name)['bitcoin'], amount_to_send)
for i, label in enumerate(labels):
to_label = labels[(i + 1) % len(labels)]
@ -99,7 +99,7 @@ class WalletLabelsTest(BitcoinTestFramework):
address = node.getnewaddress(label.name)
label.add_receive_address(address)
label.verify(node)
assert_equal(node.getreceivedbylabel(label.name), 2)
assert_equal(node.getreceivedbylabel(label.name)['bitcoin'], 2)
label.verify(node)
node.generate(101)

View file

@ -48,11 +48,11 @@ class ReceivedByTest(BitcoinTestFramework):
self.sync_all()
assert_array_result(self.nodes[1].listreceivedbyaddress(),
{"address": addr},
{"address": addr, "label": "", "amount": Decimal("0.1"), "confirmations": 10, "txids": [txid, ]})
{"address": addr, "label": "", "amount": {"bitcoin": Decimal("0.1")}, "confirmations": 10, "txids": [txid, ]})
# With min confidence < 10
assert_array_result(self.nodes[1].listreceivedbyaddress(5),
{"address": addr},
{"address": addr, "label": "", "amount": Decimal("0.1"), "confirmations": 10, "txids": [txid, ]})
{"address": addr, "label": "", "amount": {"bitcoin": Decimal("0.1")}, "confirmations": 10, "txids": [txid, ]})
# With min confidence > 10, should not find Tx
assert_array_result(self.nodes[1].listreceivedbyaddress(11), {"address": addr}, {}, True)
@ -60,11 +60,11 @@ class ReceivedByTest(BitcoinTestFramework):
empty_addr = self.nodes[1].getnewaddress()
assert_array_result(self.nodes[1].listreceivedbyaddress(0, True),
{"address": empty_addr},
{"address": empty_addr, "label": "", "amount": 0, "confirmations": 0, "txids": []})
{"address": empty_addr, "label": "", "amount": {"bitcoin": 0}, "confirmations": 0, "txids": []})
# Test Address filtering
# Only on addr
expected = {"address": addr, "label": "", "amount": Decimal("0.1"), "confirmations": 10, "txids": [txid, ]}
expected = {"address": addr, "label": "", "amount": {"bitcoin": Decimal("0.1")}, "confirmations": 10, "txids": [txid, ]}
res = self.nodes[1].listreceivedbyaddress(minconf=0, include_empty=True, include_watchonly=True, address_filter=addr)
assert_array_result(res, {"address": addr}, expected)
assert_equal(len(res), 1)
@ -78,12 +78,12 @@ class ReceivedByTest(BitcoinTestFramework):
self.nodes[0].generate(1)
self.sync_all()
# Same test as above should still pass
expected = {"address": addr, "label": "", "amount": Decimal("0.1"), "confirmations": 11, "txids": [txid, ]}
expected = {"address": addr, "label": "", "amount": {"bitcoin": Decimal("0.1")}, "confirmations": 11, "txids": [txid, ]}
res = self.nodes[1].listreceivedbyaddress(0, True, True, addr)
assert_array_result(res, {"address": addr}, expected)
assert_equal(len(res), 1)
# Same test as above but with other_addr should still pass
expected = {"address": other_addr, "label": "", "amount": Decimal("0.1"), "confirmations": 1, "txids": [txid2, ]}
expected = {"address": other_addr, "label": "", "amount": {"bitcoin": Decimal("0.1")}, "confirmations": 1, "txids": [txid2, ]}
res = self.nodes[1].listreceivedbyaddress(0, True, True, other_addr)
assert_array_result(res, {"address": other_addr}, expected)
assert_equal(len(res), 1)
@ -105,17 +105,17 @@ class ReceivedByTest(BitcoinTestFramework):
# Check balance is 0 because of 0 confirmations
balance = self.nodes[1].getreceivedbyaddress(addr)
assert_equal(balance, Decimal("0.0"))
assert_equal(balance, {"bitcoin": Decimal("0.0")})
# Check balance is 0.1
balance = self.nodes[1].getreceivedbyaddress(addr, 0)
assert_equal(balance, Decimal("0.1"))
assert_equal(balance, {"bitcoin": Decimal("0.1")})
# Bury Tx under 10 block so it will be returned by the default getreceivedbyaddress
self.nodes[1].generate(10)
self.sync_all()
balance = self.nodes[1].getreceivedbyaddress(addr)
assert_equal(balance, Decimal("0.1"))
assert_equal(balance, {"bitcoin": Decimal("0.1")})
# Trying to getreceivedby for an address the wallet doesn't own should return an error
assert_raises_rpc_error(-4, "Address not found in wallet", self.nodes[0].getreceivedbyaddress, addr)
@ -146,11 +146,11 @@ class ReceivedByTest(BitcoinTestFramework):
# listreceivedbylabel should return updated received list
assert_array_result(self.nodes[1].listreceivedbylabel(),
{"label": label},
{"label": received_by_label_json["label"], "amount": (received_by_label_json["amount"] + Decimal("0.1"))})
{"label": received_by_label_json["label"], "amount": {"bitcoin": (received_by_label_json["amount"]['bitcoin'] + Decimal("0.1"))}})
# getreceivedbylabel should return updated receive total
balance = self.nodes[1].getreceivedbylabel(label)
assert_equal(balance, balance_by_label + Decimal("0.1"))
assert_equal(balance, {"bitcoin": balance_by_label['bitcoin'] + Decimal("0.1")})
# Create a new label named "mynewlabel" that has a 0 balance
address = self.nodes[1].getnewaddress()
@ -158,11 +158,11 @@ class ReceivedByTest(BitcoinTestFramework):
received_by_label_json = [r for r in self.nodes[1].listreceivedbylabel(0, True) if r["label"] == "mynewlabel"][0]
# Test includeempty of listreceivedbylabel
assert_equal(received_by_label_json["amount"], Decimal("0.0"))
assert_equal(received_by_label_json["amount"], {"bitcoin": Decimal("0.0")})
# Test getreceivedbylabel for 0 amount labels
balance = self.nodes[1].getreceivedbylabel("mynewlabel")
assert_equal(balance, Decimal("0.0"))
assert_equal(balance, {"bitcoin": Decimal("0.0")})
if __name__ == '__main__':
ReceivedByTest().main()

View file

@ -155,6 +155,7 @@ class ListSinceBlockTest (BitcoinTestFramework):
recipient_dict = {
self.nodes[0].getnewaddress(): 1,
self.nodes[1].getnewaddress(): change,
"fee": "0.0003",
}
utxo_dicts = [{
'txid': utxo['txid'],
@ -168,6 +169,7 @@ class ListSinceBlockTest (BitcoinTestFramework):
recipient_dict2 = {
self.nodes[3].getnewaddress(): 1,
self.nodes[2].getnewaddress(): change,
"fee": "0.0003",
}
self.nodes[2].sendrawtransaction(
self.nodes[2].signrawtransactionwithwallet(
@ -230,6 +232,7 @@ class ListSinceBlockTest (BitcoinTestFramework):
recipient_dict = {
self.nodes[0].getnewaddress(): 1,
self.nodes[2].getnewaddress(): change,
"fee": "0.0003"
}
utxo_dicts = [{
'txid': utxo['txid'],

View file

@ -139,6 +139,7 @@ class ListTransactionsTest(BitcoinTestFramework):
# Create tx2 using createrawtransaction
inputs = [{"txid": utxo_to_use["txid"], "vout": utxo_to_use["vout"]}]
outputs = {self.nodes[0].getnewaddress(): 0.999}
outputs["fee"] = utxo_to_use["amount"] - Decimal('0.999')
tx2 = self.nodes[1].createrawtransaction(inputs, outputs)
tx2_signed = self.nodes[1].signrawtransactionwithwallet(tx2)["hex"]
txid_2 = self.nodes[1].sendrawtransaction(tx2_signed)
@ -153,6 +154,7 @@ class ListTransactionsTest(BitcoinTestFramework):
utxo_to_use = get_unconfirmed_utxo_entry(self.nodes[0], txid_2)
inputs = [{"txid": txid_2, "vout": utxo_to_use["vout"]}]
outputs = {self.nodes[1].getnewaddress(): 0.998}
outputs["fee"] = utxo_to_use["amount"] - Decimal('0.998')
tx3 = self.nodes[0].createrawtransaction(inputs, outputs)
tx3_modified = tx_from_hex(tx3)
tx3_modified.vin[0].nSequence = 0
@ -170,6 +172,7 @@ class ListTransactionsTest(BitcoinTestFramework):
utxo_to_use = get_unconfirmed_utxo_entry(self.nodes[1], txid_3)
inputs = [{"txid": txid_3, "vout": utxo_to_use["vout"]}]
outputs = {self.nodes[0].getnewaddress(): 0.997}
outputs["fee"] = utxo_to_use["amount"] - Decimal('0.997')
tx4 = self.nodes[1].createrawtransaction(inputs, outputs)
tx4_signed = self.nodes[1].signrawtransactionwithwallet(tx4)["hex"]
txid_4 = self.nodes[1].sendrawtransaction(tx4_signed)
@ -181,7 +184,8 @@ class ListTransactionsTest(BitcoinTestFramework):
# Replace tx3, and check that tx4 becomes unknown
tx3_b = tx3_modified
tx3_b.vout[0].nValue -= int(Decimal("0.004") * COIN) # bump the fee
tx3_b.vout[0].nValue.setToAmount(tx3_b.vout[0].nValue.getAmount() - int(0.004*COIN)) # bump the fee
tx3_b.vout[1].nValue.setToAmount(tx3_b.vout[1].nValue.getAmount() + int(0.004*COIN)) # bump the fee
tx3_b = bytes_to_hex_str(tx3_b.serialize())
tx3_b_signed = self.nodes[0].signrawtransactionwithwallet(tx3_b)['hex']
txid_3b = self.nodes[0].sendrawtransaction(tx3_b_signed, True)

View file

@ -130,7 +130,7 @@ class MultiWalletTest(BitcoinTestFramework):
assert_equal(set(node.listwallets()), {"w4", "w5"})
w5 = wallet("w5")
w5_info = w5.getwalletinfo()
assert_equal(w5_info['immature_balance'], 50)
assert_equal(w5_info['immature_balance'], {"bitcoin": 50})
competing_wallet_dir = os.path.join(self.options.tmpdir, 'competing_walletdir')
os.mkdir(competing_wallet_dir)
@ -147,7 +147,7 @@ class MultiWalletTest(BitcoinTestFramework):
wallets[0].generate(1)
for wallet_name, wallet in zip(wallet_names, wallets):
info = wallet.getwalletinfo()
assert_equal(info['immature_balance'], 50 if wallet is wallets[0] else 0)
assert_equal(info['immature_balance']['bitcoin'], 50 if wallet is wallets[0] else 0)
assert_equal(info['walletname'], wallet_name)
# accessing invalid wallet fails

View file

@ -71,15 +71,15 @@ class TxnMallTest(BitcoinTestFramework):
clone_inputs = [{"txid": rawtx1["vin"][0]["txid"], "vout": rawtx1["vin"][0]["vout"]}]
clone_outputs = {rawtx1["vout"][0]["scriptPubKey"]["addresses"][0]: rawtx1["vout"][0]["value"],
rawtx1["vout"][1]["scriptPubKey"]["addresses"][0]: rawtx1["vout"][1]["value"]}
clone_valuein = self.nodes[0].getrawtransaction(rawtx1["vin"][0]["txid"], 1)["vout"][rawtx1["vin"][0]["vout"]]["value"]
clone_outputs["fee"] = clone_valuein - rawtx1["vout"][0]["value"] - rawtx1["vout"][1]["value"]
assert_equal(rawtx1["vout"][2]["scriptPubKey"]["type"], "fee")
clone_outputs["fee"] = rawtx1["vout"][2]["value"]
clone_locktime = rawtx1["locktime"]
clone_raw = self.nodes[0].createrawtransaction(clone_inputs, clone_outputs, clone_locktime)
# createrawtransaction randomizes the order of its outputs, so swap them if necessary.
clone_tx = CTransaction()
clone_tx.deserialize(io.BytesIO(bytes.fromhex(clone_raw)))
if (rawtx1["vout"][0]["value"] == 40 and clone_tx.vout[0].nValue != 40*COIN or rawtx1["vout"][0]["value"] != 40 and clone_tx.vout[0].nValue == 40*COIN):
if (rawtx1["vout"][0]["value"] == 40 and clone_tx.vout[0].nValue.getAmount() != 40*COIN or rawtx1["vout"][0]["value"] != 40 and clone_tx.vout[0].nValue.getAmount() == 40*COIN):
(clone_tx.vout[0], clone_tx.vout[1]) = (clone_tx.vout[1], clone_tx.vout[0])
# Use a different signature hash type to sign. This creates an equivalent but malleated clone.

View file

@ -36,7 +36,7 @@ class TxnMallTest(BitcoinTestFramework):
# All nodes should start with 1,250 BTC:
starting_balance = 1250
for i in range(4):
assert_equal(self.nodes[i].getbalance()['bitcoin'], starting_balance)
assert_equal(self.nodes[i].getbalance(), {"bitcoin": starting_balance})
self.nodes[i].getnewaddress("") # bug workaround, coins generated assigned to first getnewaddress!
# Assign coins to foo and bar addresses:
@ -48,8 +48,8 @@ class TxnMallTest(BitcoinTestFramework):
fund_bar_txid = self.nodes[0].sendtoaddress(node0_address_bar, 29)
fund_bar_tx = self.nodes[0].gettransaction(fund_bar_txid)
assert_equal(self.nodes[0].getbalance()['bitcoin'],
starting_balance + fund_foo_tx["fee"] + fund_bar_tx["fee"])
assert_equal(self.nodes[0].getbalance(),
{"bitcoin": starting_balance + fund_foo_tx["fee"]['bitcoin'] + fund_bar_tx["fee"]['bitcoin']})
# Coins are sent to node1_address
node1_address = self.nodes[1].getnewaddress()
@ -68,6 +68,7 @@ class TxnMallTest(BitcoinTestFramework):
outputs = {}
outputs[node1_address] = 1240
outputs[change_address] = 1248 - 1240 + doublespend_fee
outputs["fee"] = (1219+29) - (1240+1248 - 1240 + doublespend_fee)
rawtx = self.nodes[0].createrawtransaction(inputs, outputs)
doublespend = self.nodes[0].signrawtransactionwithwallet(rawtx)
assert_equal(doublespend["complete"], True)
@ -86,18 +87,18 @@ class TxnMallTest(BitcoinTestFramework):
# Node0's balance should be starting balance, plus 50BTC for another
# matured block, minus 40, minus 20, and minus transaction fees:
expected = starting_balance + fund_foo_tx["fee"] + fund_bar_tx["fee"]
expected = starting_balance + fund_foo_tx["fee"]['bitcoin'] + fund_bar_tx["fee"]['bitcoin']
if self.options.mine_block:
expected += 50
expected += tx1["amount"] + tx1["fee"]
expected += tx2["amount"] + tx2["fee"]
assert_equal(self.nodes[0].getbalance()['bitcoin'], expected)
expected += tx1["amount"]['bitcoin'] + tx1["fee"]['bitcoin']
expected += tx2["amount"]['bitcoin'] + tx2["fee"]['bitcoin']
assert_equal(self.nodes[0].getbalance(), {"bitcoin": expected})
if self.options.mine_block:
assert_equal(tx1["confirmations"], 1)
assert_equal(tx2["confirmations"], 1)
# Node1's balance should be both transaction amounts:
assert_equal(self.nodes[1].getbalance()['bitcoin'], starting_balance - tx1["amount"] - tx2["amount"])
assert_equal(self.nodes[1].getbalance(), {"bitcoin": starting_balance - tx1["amount"]['bitcoin'] - tx2["amount"]['bitcoin']})
else:
assert_equal(tx1["confirmations"], 0)
assert_equal(tx2["confirmations"], 0)
@ -126,7 +127,7 @@ class TxnMallTest(BitcoinTestFramework):
# Node0's total balance should be starting balance, plus 100BTC for
# two more matured blocks, minus 1240 for the double-spend, plus fees (which are
# negative):
expected = starting_balance + 100 - 1240 + fund_foo_tx["fee"] + fund_bar_tx["fee"] + doublespend_fee
expected = starting_balance + 100 - 1240 + fund_foo_tx["fee"]['bitcoin'] + fund_bar_tx["fee"]['bitcoin'] + doublespend_fee
assert_equal(self.nodes[0].getbalance()['bitcoin'], expected)
# Node1's balance should be its initial balance (1250 for 25 block rewards) plus the doublespend: