#42480 [BC-Medium] Unable to deposit the gas fee into the `governed_gas_pool` when using `deposit_from_fungible_store`
Description
Brief/Intro
Vulnerability Details
public(friend) fun deposit_gas_fee_v2(gas_payer: address, gas_fee: u64) acquires GovernedGasPool {
if (features::operations_default_to_fa_apt_store_enabled()) {
=> deposit_from_fungible_store(gas_payer, gas_fee);
} else {
deposit_from<AptosCoin>(gas_payer, gas_fee);
};
}
fun deposit_from_fungible_store(account: address, amount: u64) acquires GovernedGasPool {
if (amount > 0){
// compute the governed gas pool store address
let governed_gas_pool_address = governed_gas_pool_address();
let governed_gas_pool_store_address = primary_fungible_store_address(governed_gas_pool_address);
// compute the account store address
let account_store_address = primary_fungible_store_address(account);
=> fungible_asset::deposit_internal(
governed_gas_pool_store_address,
fungible_asset::withdraw_internal(
account_store_address,
amount
)
);
}
}
Impact Details
Recommendation
Proof of Concept
Proof of Concept
Previous#42430 [BC-Insight] `add_mempool_transaction()` does not check if the transaction already exist in the mempoolNext#42495 [BC-High] The Tonic Request/Response Size Limit prevents data from being submitted to the da_light_node
Was this helpful?