Skip to content

Commit dd5d632

Browse files
committed
sign_transaction: do not use address_type to recognize sweep
Single sig has p2pkh address_type so it's no longer appropriate.
1 parent c9f8e09 commit dd5d632

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/ga_auth_handlers.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -570,7 +570,7 @@ namespace sdk {
570570
// and that include sweep outouts
571571
GDK_RUNTIME_ASSERT(!addr_type.empty()); // Must be spendable by us
572572
// TODO: Support mixed/batched sweep transactions with non-sweep inputs
573-
GDK_RUNTIME_ASSERT(addr_type != address_type::p2pkh);
573+
GDK_RUNTIME_ASSERT(!input.contains("private_key"));
574574
}
575575

576576
// FIXME: Do not duplicate the transaction_outputs in required_data
@@ -589,7 +589,7 @@ namespace sdk {
589589
const auto& addr_type = input.at("address_type");
590590
GDK_RUNTIME_ASSERT(!addr_type.empty()); // Must be spendable by us
591591
// TODO: Support mixed/batched sweep transactions with non-sweep inputs
592-
GDK_RUNTIME_ASSERT(addr_type != address_type::p2pkh);
592+
GDK_RUNTIME_ASSERT(!input.contains("private_key"));
593593

594594
// Add host-entropy and host-commitment to each input if using the anti-exfil protocol
595595
if (use_ae_protocol) {

0 commit comments

Comments
 (0)