Ivan Socolsky
9ef45b4409
use SIGHASH_FORKID for cash txs
7 years ago
Ivan Socolsky
58cb560b79
select appropriate Bitcore when building/signing tx proposal
7 years ago
Ivan Socolsky
06b63e0311
all methods working with coin
7 years ago
Ivan Socolsky
daad0367d7
add coin argument to wallet
7 years ago
Ivan Socolsky
558c6fbc38
derive() -> deriveChild()
8 years ago
Ivan Socolsky
04b8d2afa2
persist feeLevel as part of txp
8 years ago
Ivan Socolsky
827bb03d0c
restore legacy txproposal model
9 years ago
Ivan Socolsky
bc9354bf1f
remove tx legacy code
9 years ago
Ivan Socolsky
49929942e7
accept id as arg for tx creation
9 years ago
Ivan Socolsky
f455b53971
always add changeaddress if specified
9 years ago
Kosta Korenkov
11b32f4ee5
Optionally disable outputs shuffling for createTx
9 years ago
Ivan Socolsky
4d25161098
assert inputs & outputs are consistent
9 years ago
Kosta Korenkov
2e1cc88c56
fix: wrong output value calculation in _buildTx
9 years ago
Kosta Korenkov
0d9dc85030
fix: do not remove scripts from outputs
9 years ago
Ivan Socolsky
bdff2cbc35
sendMax option on createTx
9 years ago
Ivan Socolsky
8d25f23849
get send max info
9 years ago
Ivan Socolsky
8ce304fd4e
reduce safety margin to 2%
9 years ago
Ivan Socolsky
8865d42ec3
improve fee computation for P2PKH wallets
9 years ago
Ivan Socolsky
ee7d3bad7f
allow absolute fee when specifying inputs
9 years ago
Ivan Socolsky
c01d1568bb
adapt fee to avoid change below dust
9 years ago
Ivan Socolsky
dbba3acfa8
new input selection algorithm
9 years ago
Ivan Socolsky
f878594d40
rm feeLevel
9 years ago
Ivan Socolsky
446f35426f
remove explicit final fee for tx creation
9 years ago
Ivan Socolsky
37f87e4793
accept feeLevel on createTx
9 years ago
Ivan Socolsky
23cddbe47f
fix broadcasting new proposals
9 years ago
Ivan Socolsky
6f196aa1b9
allow fee to be specified on proposal creation
9 years ago
Ivan Socolsky
0bb043d034
simplify proposal creation + allow non-validated outputs (external txps)
9 years ago
Ivan Socolsky
5755b965e8
use TxProposal#fromObj as a factory for proposals
9 years ago
Ivan Socolsky
2211847d0c
remove type from txproposal model
9 years ago
Ivan Socolsky
9db456550f
create temporary proposal + test
9 years ago
Ivan Socolsky
6deb9e77f6
txproposalv3 -> txproposal
9 years ago
Ivan Socolsky
63eca6b529
txProposal v3
9 years ago
Ivan Socolsky
1b6980fd1e
call toObject before storing models
10 years ago
Ivan Socolsky
5794883eb0
allow either script or toAddress
9 years ago
Ivan Socolsky
6476de0461
remove unused elements in output order array
9 years ago
Kosta Korenkov
2bdc6cf19d
Make API.createTx accept preselected inputs
Add EXTERNAL tx type
It will allow clients to specify inputs and outputs when creating proposals
Extract _validateOutputs method
Use for-loop to simplify and make it fail-fast.
Do not validate outputs for EXTERNAL tx type
Outputs may be of any kind (e.g. OP_RETURN). It is assumed that outputs are validated by caller.
Move output validation to a single place
Check tx and estimate fees for EXTERNAL proposal
Set amount for external proposals
Use changeAddress to determine network
Do not shuffle outputs for EXTERNAL txp
Fix input selection to respect fees
Add more inputs, if we selected exactly the amount to spend, so we avoid 'Insufficient funds for a fee' error
Properly handle UTXO with 0 satoshis
Minor fixes
ignore invalid utxos
10 years ago
Ivan Socolsky
fa58b5b778
restore derivation strategy on txps
9 years ago
Ivan Socolsky
414b4403c4
remove unused method
9 years ago
Ivan Socolsky
714b95b32c
remove derivationStrategy field from txp
9 years ago
Ivan Socolsky
e55983b151
mv Utils.buildTx -> TxProposal
9 years ago
Ivan Socolsky
795097bf04
refactor constants+defaults+utils -> common
9 years ago
Ivan Socolsky
eb006c3db3
remove bitcore-wallet-utils dependency
9 years ago
Matias Alejo Garcia
95e41050bd
add log
9 years ago
Matias Alejo Garcia
a8607fa11b
better insight error handling
add check to getPending
add check to getPending
add tests
rm log
store TXID upon tx completion
monitor accepted txs
change delay
change _checkTxInBlockchain
change _checkTxInBlockchain
rm useless params, refactor txid param
complete tx at fetch
9 years ago
Ivan Socolsky
595a54322b
correctly build tx proposal on P2PKH
9 years ago
Kosta Korenkov
20af02e24f
Allow arbitrary customData for tx proposals
This way Copay addons may attach related data to proposals
10 years ago
Matias Alejo Garcia
9de8cfcbf2
add raw HEX if tx is "accepted"
9 years ago
Ivan Socolsky
094e19bc31
use constants form BWU
9 years ago
Ivan Socolsky
3ac0bc5e27
switch tests to bip44
9 years ago
Ivan Socolsky
7d9e43fccc
initialize version field from #create method
10 years ago