@@ -1179,6 +1179,8 @@ static struct io_plan *handle_sign_remote_htlc_tx(struct io_conn *conn,
11791179 return req_reply (conn , c , take (towire_hsm_sign_tx_reply (NULL , & sig )));
11801180}
11811181
1182+ // TODO - This goes away when we complete all callers.
1183+ //
11821184/*~ This covers several cases where onchaind is creating a transaction which
11831185 * sends funds to our internal wallet. */
11841186/* FIXME: Derive output address for this client, and check it here! */
@@ -1291,11 +1293,8 @@ static struct io_plan *handle_sign_remote_htlc_to_us(struct io_conn *conn,
12911293 const u8 * msg_in )
12921294{
12931295 struct amount_sat input_sat ;
1294- struct secret channel_seed , htlc_basepoint_secret ;
1295- struct pubkey htlc_basepoint ;
12961296 struct bitcoin_tx * tx ;
12971297 struct pubkey remote_per_commitment_point ;
1298- struct privkey privkey ;
12991298 u8 * wscript ;
13001299
13011300 if (!fromwire_hsm_sign_remote_htlc_to_us (tmpctx , msg_in ,
@@ -1327,27 +1326,9 @@ static struct io_plan *handle_sign_remote_htlc_to_us(struct io_conn *conn,
13271326 return bad_req_fmt (conn , c , msg_in ,
13281327 "proxy_%s error: %s" , __FUNCTION__ ,
13291328 proxy_last_message ());
1330- g_proxy_impl = PROXY_IMPL_MARSHALED ;
1331-
1332- /* FIXME - server-side not implemented yet. Use original code
1333- * below for now */
1334-
1335- get_channel_seed (& c -> id , c -> dbid , & channel_seed );
1336-
1337- if (!derive_htlc_basepoint (& channel_seed , & htlc_basepoint ,
1338- & htlc_basepoint_secret ))
1339- return bad_req_fmt (conn , c , msg_in ,
1340- "Failed derive_htlc_basepoint" );
1341-
1342- if (!derive_simple_privkey (& htlc_basepoint_secret ,
1343- & htlc_basepoint ,
1344- & remote_per_commitment_point ,
1345- & privkey ))
1346- return bad_req_fmt (conn , c , msg_in ,
1347- "Failed deriving htlc privkey" );
1329+ g_proxy_impl = PROXY_IMPL_COMPLETE ;
13481330
1349- return handle_sign_to_us_tx (conn , c , msg_in ,
1350- tx , & privkey , wscript , input_sat );
1331+ return req_reply (conn , c , take (towire_hsm_sign_tx_reply (NULL , & sig )));
13511332}
13521333
13531334/*~ This is used when the remote peer's commitment transaction is revoked;
0 commit comments