1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-12-22 22:38:08 +00:00

signing segwit change output typo

This commit is contained in:
Tomas Susanka 2017-11-24 12:35:16 +01:00 committed by Pavol Rusnak
parent 723cf295a7
commit cfe8a98c68

View File

@ -552,6 +552,9 @@ static bool signing_check_output(TxOutputType *txoutput) {
}
/*
* only allow segwit change if amount is smaller than what segwit inputs paid.
* this was added during the times segwit was not yet fully activated
* to make sure the user is not tricked to use witness change output
* instead of regular one therefore creating ANYONECANSPEND output
*/
if ((txoutput->script_type == OutputScriptType_PAYTOWITNESS
|| txoutput->script_type == OutputScriptType_PAYTOP2SHWITNESS)