Closed codemaster101 closed 1 year ago
Hmm, got it.
const authInfoBytes = makeAuthInfoBytes(
[{
pubkey: wallet,
sequence: sequenceNumber,
}],
fee.amount /* Total fee amount */,
200000 /* Gas Limit */,
undefined,
undefined,
);
I am supposed to provide a encodePubkey
object here instead of wallet.
I tried submitting the encodeSecp256k1Pubkey
object here, but it was failing.
So from a secp256k1 key => encode into object for secp256k1 tendermint key
=> encodePubkey with TypeUrl
Hi, I am trying to send out a transaction on Cosmos testnet. When I use
client.sendTokens
it works perfectly fine, but when I try to recreate the sendTokens function (because we need signBytes, as we sign outside the SDK on an HSM to get back digital signature), it fails. Currently I am using the soft-signer (which Direct Sign uses in its implementation).The following is my implementation to send out tokens:
This yields the following error:
The signed transaction in hexadecimal is the following:
'0aa3010a8c010a1c2f636f736d6f732e62616e6b2e763162657461312e4d736753656e64126c0a2d636f736d6f73317675716e3570326a6d357666336e393539357434346479647868746a7679676e6e7370663879122d636f736d6f73317675716e3570326a6d357666336e393539357434346479647868746a7679676e6e73706638791a0c0a057561746f6d120331303012124669727374207478206f6e20436f736d6f7312210a080a0012040a02080112150a0f0a057561746f6d120636303637343010c09a0c1a4038625c4c06c4e204c4645a0896abe9f55e4a845111291d2b5d8330896c7af624746ab2c11adf30464169c52c73ce2a1eb43aea95821261468b741bd4e15af7a7'
Any help in this regard would be greatly appreciated. Am I doing something wrong or there is a missing field somewhere?