Line data Source code
1 : #include "fd_bank_abi.h" 2 : 3 : int 4 : fd_bank_abi_resolve_address_lookup_tables( void const * bank FD_PARAM_UNUSED, 5 : int fixed_root FD_PARAM_UNUSED, 6 : ulong slot FD_PARAM_UNUSED, 7 : fd_txn_t const * txn FD_PARAM_UNUSED, 8 : uchar const * payload FD_PARAM_UNUSED, 9 0 : fd_acct_addr_t * out_lut_accts FD_PARAM_UNUSED) { 10 : 11 : 12 : #if 0 13 : 14 : // reference code to start with 15 : 16 : /* Only resolve for V0 transaction versions */ 17 : if( txn_descriptor->transaction_version == FD_TXN_V0 ) { 18 : fd_txn_acct_addr_lut_t const * addr_luts = fd_txn_get_address_tables_const( txn_descriptor ); 19 : for( ulong i = 0UL; i < txn_descriptor->addr_table_lookup_cnt; i++ ) { 20 : fd_txn_acct_addr_lut_t const * addr_lut = &addr_luts[i]; 21 : 22 : fd_pubkey_t * addr_lut_acc = (fd_pubkey_t *)((uchar *)txn_raw.raw + addr_lut->addr_off); 23 : /* TODO: WRITE OUT RESOLVED PUBKEY */ 24 : } 25 : 26 : /* Look up the pubkeys from the ALTs */ 27 : fd_slot_hashes_global_t const * slot_hashes_global = fd_sysvar_cache_slot_hashes( 28 : ctx->slot_ctx->sysvar_cache, ctx->runtime_public_wksp ); 29 : if( FD_UNLIKELY( !slot_hashes_global ) ) { 30 : FD_LOG_ERR(( "failed to get slot hashes global" )); 31 : } 32 : fd_slot_hash_t * slot_hash = deq_fd_slot_hash_t_join( (uchar *)slot_hashes_global + slot_hashes_global->hashes_offset ); 33 : fd_acct_addr_t * accts_alt = fd_spad_alloc( 34 : ctx->runtime_spad, alignof(fd_acct_addr_t), sizeof(fd_acct_addr_t) * txn_descriptor->addr_table_adtl_cnt ); 35 : int err = fd_runtime_load_txn_address_lookup_tables( txn_descriptor, 36 : txn_raw.raw, 37 : ctx->funk, 38 : ctx->slot_ctx->funk_txn, 39 : ctx->curr_slot, 40 : slot_hash, 41 : accts_alt); 42 : if( FD_UNLIKELY( err != FD_RUNTIME_EXECUTE_SUCCESS ) ) { 43 : FD_LOG_WARNING(( "failed to load txn address lookup tables" )); 44 : } 45 : 46 : for( ulong i = 0UL; i < txn_descriptor->addr_table_lookup_cnt; i++ ) { 47 : fd_pubkey_t * pubkey = fd_type_pun( &accts_alt[i] ); 48 : /* TODO: WRITE OUT RESOLVED PUBKEY */ 49 : } 50 : } 51 : } FD_SPAD_FRAME_END; 52 : 53 : #endif 54 : 55 0 : FD_LOG_ERR(("nope")); 56 0 : return 0; 57 0 : } 58 : 59 0 : void fd_ext_bank_release( void const * bank FD_PARAM_UNUSED) { 60 0 : FD_LOG_ERR(("nope")); 61 0 : } 62 : 63 : int 64 : fd_ext_admin_rpc_set_identity( uchar const * identity_keypair FD_PARAM_UNUSED, 65 0 : int require_tower FD_PARAM_UNUSED) { 66 0 : FD_LOG_ERR(("nope")); 67 0 : return 0; 68 0 : } 69 : 70 : void 71 0 : fd_ext_bank_acquire( void const * bank FD_PARAM_UNUSED) { 72 0 : FD_LOG_ERR(("nope")); 73 0 : } 74 : 75 : int 76 : fd_ext_bank_load_account( void const * bank FD_PARAM_UNUSED, 77 : int fixed_root FD_PARAM_UNUSED, 78 : uchar const * addr FD_PARAM_UNUSED, 79 : uchar * owner FD_PARAM_UNUSED, 80 : uchar * data FD_PARAM_UNUSED, 81 0 : ulong * data_sz FD_PARAM_UNUSED) { 82 0 : FD_LOG_ERR(("nope")); 83 0 : return 0; 84 0 : } 85 : 86 : void 87 0 : fd_ext_poh_register_tick( void const * bank FD_PARAM_UNUSED, uchar const * hash FD_PARAM_UNUSED) { 88 0 : FD_LOG_ERR(("nope")); 89 0 : } 90 : 91 : void 92 0 : fd_ext_poh_signal_leader_change( void * sender FD_PARAM_UNUSED) { 93 0 : FD_LOG_ERR(("nope")); 94 0 : }