These functions sort transaction inputs and outputs according to BIP LI01
(https://github.com/kristovatlas/rfc/blob/master/bips/bip-li01.mediawiki)
This is useful to standardize transactions for faster multi-party
agreement as well as preventing information leaks in a single-party
use case.