forked from cerc-io/laconicd
a21e9ea387
* Add proto files for onboarding module * Add generated proto bindings * Define onboarding object * Define the participants state in keeper * Update genesis file to initialize and export module state to/from genesis * Add msg to onboard participant * Register command to enroll participant * Add functionality to decode ethereum address from signature * Add comments for messages and fields * Fix lint errors in proto files * Add message validation and events in msg_server * Reuse crypto utils from go-nitro * Sign entire eth_payload object * Use google API for rpc method * Regenerate proto bindings --------- Co-authored-by: Prathamesh Musale <prathamesh.musale0@gmail.com>
36 lines
1.1 KiB
Protocol Buffer
36 lines
1.1 KiB
Protocol Buffer
syntax = "proto3";
|
|
|
|
package cerc.onboarding.v1;
|
|
|
|
import "cosmos/msg/v1/msg.proto";
|
|
import "google/api/annotations.proto";
|
|
import "gogoproto/gogo.proto";
|
|
import "cerc/onboarding/v1/onboarding.proto";
|
|
|
|
option go_package = "git.vdb.to/cerc-io/laconicd/x/onboarding";
|
|
|
|
// Msg defines the onboarding Msg service.
|
|
service Msg {
|
|
option (cosmos.msg.v1.service) = true;
|
|
|
|
// OnboardParticipant defines a method for enrolling a new validator.
|
|
rpc OnboardParticipant(MsgOnboardParticipant)
|
|
returns (MsgOnboardParticipantResponse) {
|
|
option (google.api.http).post = "/cerc/onboarding/v1/onboard_participant";
|
|
};
|
|
}
|
|
|
|
// MsgOnboardParticipant defines a SDK message for enrolling a new validator.
|
|
message MsgOnboardParticipant {
|
|
option (cosmos.msg.v1.signer) = "participant";
|
|
|
|
// Participant is the msg sender
|
|
string participant = 1;
|
|
EthPayload eth_payload = 2 [ (gogoproto.nullable) = false ];
|
|
string eth_signature = 3;
|
|
string message = 4;
|
|
}
|
|
|
|
// MsgOnboardParticipantResponse defines the Msg/OnboardParticipant response type.
|
|
message MsgOnboardParticipantResponse {}
|