MinimalForwarder forward request to a payable function from another contract

Hello everyone,

I am working with the MinimalForwarder and everything was looking fine... until I tried to call a payable function from another contract.
Indeed I have a contract that has a sendWithFee method which role is to split the amount of BNB ( or Ether or whatever native token of an EVM blockchain) he received and send it to transfer it to different addresses.
The thing is it looks like the forwarder contract is not even reaching the contract.

And what it should do: (called without the relayer)

It has an internal tx sending BNB to the Null address.

Do you know why ? We agree that the minimal forwarder can forward request to payable functions right ?


Edit: It has been flagged and hidden by the community, I don't know why

Yes, this should work.

I can't tell what went wrong here.

Can you verify the MinimalForwarder on bscscan?

See this contract on testnet 0x4270f22E0A7D5d2Ce64afb1d393fF214c6c8432f, the code is verified
I can't post a link apparently...

And I saw this

What function is the transaction supposed to be calling?

It doesn't seem to be sendWithFee.

It is supposed to be sendWithFee actually

Here is the inner transaction

const sendWithFee = contract.methods.sendWithFee(

    const tx = {
      from: fromAccount.address,
      to: this.apiConfigService.bscConfig.transferBnbWithFeeSc,
      value: amountBNB,
      gas: await this.bscService.estimateGas(sendWithFee, {
        from: fromAccount.address,
        value: amountBNB,
      data: sendWithFee.encodeABI(),

I retried to do the tx, here is the result

The signature is not valid.

It isn't sending any BNB and it isn't the null address, it's a call to 0x00...01, the ECRECOVER precompile.

You can see a trace for the latest transaction you shared on Tenderly where it is clear that it's throwing an error during signature validation.

Indeed, I didn't know about tenderly, I'll add the tool to my toolbox !
Indeed signature problem... that is weird, I'll check that.
The thing is it works for all my other methods except this one...

I just tried to do the same but setting the value to 0
Here is what I get

A working tx

I retried with BNB

From what we see, there is no error but still no BNB is sent
But from this forum, apparently we can't send BNB or ether via a relayer

Oh, right. That seems obvious now. There is nowhere the ETH or BNB would be taken from... The relayer isn't going to contribute their own coins, and the signer doesn't have a way to pay those back.

In theory a Forwarder contract could add this feature though.