Commit graph

218 commits

Author SHA1 Message Date
SomberNight
12c5474cf1
stricter tx deserialization: forbid negative output amount values 2018-06-12 14:41:30 +02:00
SomberNight
0b78cb5e6b
stricter tx deserialization: forbid output amount values over 21 million btc 2018-06-12 14:33:22 +02:00
SomberNight
71ce7cce6d
stricter tx deserialization: forbid junk at the end 2018-06-12 10:51:51 +02:00
SomberNight
6b8a563d41
add witness version to our partial format 2018-06-11 19:25:02 +02:00
SomberNight
a0ba5a7962
change partial txn format: add header. only parse inputs and witness for partial txns. 2018-06-11 17:57:29 +02:00
Dev Random
c6fce4b7cc do not actually compute the nested p2wsh-p2sh script if just estimating size (#4412) 2018-06-07 17:44:48 +02:00
SomberNight
16e4827e8c
use libsecp256k1 if available. abstract away ecc stuff. move symmetric crypto and hash functions to crypto.py 2018-05-25 15:43:06 +02:00
SomberNight
e375bf48c4
transaction.py: reserialize scriptSig for incomplete txin
On offline imported privkey + online imported address config, the offline wallet was displaying incorrect tx size.
2018-05-15 18:53:25 +02:00
ghost43
3337af0734
transaction.py: (txin guess) fix some false positive matches of p2sh-segwit (#4336) 2018-05-09 19:16:01 +02:00
SomberNight
cbf1b5d9d5
py3.4 compat: follow-up e13183ea7a 2018-04-29 15:06:19 +02:00
SomberNight
ea55d886b7
follow-up 1d6f000868
I broke multisig..
2018-04-27 21:44:29 +02:00
SomberNight
e13183ea7a
bitcoin.py: SCRIPT-related clean-up. transaction.py: construct_witness 2018-04-27 16:16:27 +02:00
SomberNight
97296432a2
transaction.py: sign_txin. allow override for get_preimage_script. 2018-04-27 16:16:27 +02:00
SomberNight
1d6f000868
transaction.py: shortcut witness/scriptSig serialisation 2018-04-27 16:16:14 +02:00
SomberNight
7b50790584
do not raise BaseException 2018-04-07 17:10:30 +02:00
SomberNight
76e67daadd
changed some asserts to raise-exceptions in lib 2018-04-07 17:01:38 +02:00
SomberNight
4ff3791cb9
fix #4236 2018-04-06 16:43:11 +02:00
ThomasV
05342c5537
Merge pull request #4117 from SomberNight/pay_to_script
fix paying to script
2018-03-23 19:42:04 +01:00
SomberNight
77c8010517 bitcoin.py: parameterise a few address-related methods with network 2018-03-20 17:02:49 +01:00
SomberNight
22061b4555 transaction.get_address_from_output_script now handles witness version > 0 2018-03-18 06:18:48 +01:00
SomberNight
b043c872eb fix paying to script 2018-03-13 06:37:02 +01:00
SomberNight
135c5e805d fix #4046 2018-03-06 12:41:37 +01:00
SomberNight
e5cba92564 transaction serialization: fix segwit coinbase case.
adjust unit tests so that they would have caught it.
2018-03-06 10:34:52 +01:00
SomberNight
063e40bf18 catch IndexError in parse_redeemScript 2018-02-14 16:20:22 +01:00
SomberNight
4b6a3e2e5d fix #3899; and more aggressively catch exceptions in tx.deserialize() 2018-02-14 01:20:38 +01:00
SomberNight
ca19a36478 conflicting transactions 2018-02-06 05:39:40 +01:00
SomberNight
e5f239dd28 follow-up 70aa1f1db9 2018-01-30 17:00:19 +01:00
SomberNight
6faef7efe3 remove comment 2018-01-30 01:47:51 +01:00
SomberNight
889456dc77 follow-up prev commit. better handling of p2sh-segwit. added comment to describe the problem for native segwit. 2018-01-29 22:45:43 +01:00
SomberNight
70aa1f1db9 fix #3788 2018-01-29 02:00:43 +01:00
SomberNight
d8a9c9720a follow-up 65eae139af 2018-01-10 18:39:25 +01:00
SomberNight
aaf5e32207 coinchooser fee calculation now uses tx weights. more precise fee calculation for segwit and mixed-segwit txns. 2017-12-21 01:45:35 +01:00
ThomasV
936ee47d3a
Merge pull request #3496 from SomberNight/coinchooser1
CoinChooser: privacy prefers confirmed and is default
2017-12-12 17:19:19 +01:00
SomberNight
b751e5e7d3 fix: tx size estimation for multisig 2017-12-12 05:43:34 +01:00
SomberNight
2a3c41b24f coinchooser: "privacy" policy now prefers confirmed coins. removed "priority" policy. 2017-12-11 14:49:53 +01:00
SomberNight
0aee9bbbb0 fix spending from multisig (broken by 8be777e882) 2017-12-06 16:02:40 +01:00
SomberNight
8be777e882 tx size estimation: handle uncompressed pubkeys 2017-11-24 04:24:54 +01:00
SomberNight
e373f50596 follow-up prev commit 2017-11-22 01:15:01 +01:00
SomberNight
a2a25e4738 better segwit tx size estimation 2017-11-21 23:02:45 +01:00
Justin Turner Arthur
857eb4ac1d Remove unused imports. Explicitly import a few deep imports. 2017-11-13 02:28:00 -06:00
SomberNight
f8518c78d8 remove Transaction.requires_fee() 2017-11-09 22:15:47 +01:00
ThomasV
bf2c07ff2a fix #3244 2017-11-08 14:48:46 +01:00
SomberNight
b28f8b3ebd make tx deserialization more robust to ill-formed tx 2017-11-06 12:27:47 +01:00
ThomasV
358068a0c1 fix #3197: parse pubkey 2017-11-03 15:31:20 +01:00
SomberNight
32e88495ae fix: transaction.parse_witness() for coinbase 2017-10-26 00:40:08 +02:00
ThomasV
8683d71711 fix: witness serialization 2017-10-22 12:39:36 +02:00
SomberNight
8e007f026d fix: witness for non-segwit txins 2017-10-12 21:44:08 +02:00
ThomasV
c72123d708 fix #3014 2017-10-11 01:04:46 +02:00
ThomasV
b1cc81a6f6 fix #3011 2017-10-09 10:42:43 +02:00
ThomasV
9aa3f2d9e2 add txin_type in add_input_info, remove inefficient search 2017-10-07 12:15:18 +02:00