cosmos-validator-watcher icon indicating copy to clipboard operation
cosmos-validator-watcher copied to clipboard

Add support for SECP256k1 pubkeys

Open fabtreb opened this issue 1 year ago • 3 comments

Panic when starting the watcher against a chain that supports SECP256k1 pubkeys:

panic: pubkey is incorrect size
goroutine 1 [running]:
github.com/cosmos/cosmos-sdk/crypto/keys/ed25519.(*PubKey).Address(0xffffde1a0f46?)
	/go/pkg/mod/github.com/cosmos/[email protected]/crypto/keys/ed25519/ed25519.go:167 +0x94

Could you please add support to SECP256k1 pubkeys?

Related code: https://github.com/kilnfi/cosmos-validator-watcher/blob/main/pkg/app/run.go#L321

fabtreb avatar Sep 18 '24 13:09 fabtreb

Hello @fabtreb

Could you share me which chain is it? Is there is public rpc node I could call and eventually an example of pubkey you pass in input?

Thx

MattKetmo avatar Sep 18 '24 15:09 MattKetmo

I try use story monitoring and got same issue. Can't get consensus pub key bech32 format.

Attaching to cosmos-validator-watcher
cosmos-validator-watcher  | {
cosmos-validator-watcher  |   "operator_address": "storyvaloper1htkcu0adnlfqg4l29t2n5cc6l2nywle6qyqdr9",
cosmos-validator-watcher  |   "consensus_pubkey": null,
cosmos-validator-watcher  |   "status": 3,
cosmos-validator-watcher  |   "tokens": "1011020000000000",
cosmos-validator-watcher  |   "delegator_shares": "1011020000000000.000000000000000000",
cosmos-validator-watcher  |   "description": {
cosmos-validator-watcher  |     "moniker": "storyvaloper1htkcu0adnlfqg4l29t2n5cc6l2nywle6qyqdr9"
cosmos-validator-watcher  |   },
cosmos-validator-watcher  |   "unbonding_time": "1970-01-01T00:00:00Z",
cosmos-validator-watcher  |   "commission": {
cosmos-validator-watcher  |     "commission_rates": {
cosmos-validator-watcher  |       "rate": "0.100000000000000000",
cosmos-validator-watcher  |       "max_rate": "0.500000000000000000",
cosmos-validator-watcher  |       "max_change_rate": "0.050000000000000000"
cosmos-validator-watcher  |     },
cosmos-validator-watcher  |     "update_time": "2024-08-28T15:39:28.879893883Z"
cosmos-validator-watcher  |   },
cosmos-validator-watcher  |   "min_self_delegation": "1"
cosmos-validator-watcher  | }

CroutonDigital avatar Oct 03 '24 11:10 CroutonDigital

Hello @fabtreb

Could you share me which chain is it? Is there is public rpc node I could call and eventually an example of pubkey you pass in input?

Thx

hey @MattKetmo thanks, shared via email

fabtreb avatar Oct 10 '24 12:10 fabtreb

Fixed in the v0.13.0 release

MattKetmo avatar Oct 11 '24 10:10 MattKetmo