commander/commander_eth: remove ETHPubrequest handling
It is now handled in Rust.
#include <stdint.h>
#include <stdio.h>
-#include <apps/eth/eth.h>
#include <apps/eth/eth_sign.h>
#include <apps/eth/eth_sign_msg.h>
-#include <wally_bip32.h> // for BIP32_INITIAL_HARDENED_CHILD
-
-static commander_error_t _api_pub(const ETHPubRequest* request, PubResponse* response)
-{
- app_eth_sign_error_t result = app_eth_address(
- request->coin,
- request->output_type,
- request->keypath,
- request->keypath_count,
- response->pub,
- sizeof(response->pub),
- request->display,
- request->contract_address);
- if (result == APP_ETH_SIGN_ERR_USER_ABORT) {
- return COMMANDER_ERR_USER_ABORT;
- }
- if (result != APP_ETH_SIGN_OK) {
- return COMMANDER_ERR_GENERIC;
- }
- return COMMANDER_OK;
-}
-
static commander_error_t _api_sign(const ETHSignRequest* request, ETHSignResponse* response)
{
app_eth_sign_error_t result = app_eth_sign(request, response);
@@ -72,9 +49,6 @@ static commander_error_t _api_sign_msg(
commander_error_t commander_eth(const ETHRequest* request, ETHResponse* response)
{
switch (request->which_request) {
- case ETHRequest_pub_tag:
- response->which_response = PubResponse_pub_tag;
- return _api_pub(&(request->request.pub), &response->response.pub);
case ETHRequest_sign_tag:
response->which_response = ETHResponse_sign_tag;
return _api_sign(&(request->request.sign), &response->response.sign);
