node.proto 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. syntax = "proto3";
  2. package node.v1;
  3. option go_package = "proto/node/v1;nodev1";
  4. import "google/api/annotations.proto";
  5. // NodePrivileged exposes an administrative API. It runs on a UNIX socket and is authenticated
  6. // using Linux filesystem permissions.
  7. service NodePrivileged {
  8. // SubmitGuardianSetVAA injects a guardian set change VAA into the guardian node.
  9. // The node will inject the VAA into the aggregator and sign/broadcast the VAA signature.
  10. //
  11. // A consensus majority of nodes on the network will have to inject the VAA within the
  12. // VAA timeout window for it to reach consensus.
  13. //
  14. rpc SubmitGuardianSetVAA (SubmitGuardianSetVAARequest) returns (SubmitGuardianSetVAAResponse);
  15. }
  16. // GuardianSet represents a new guardian set to be submitted to and signed by the node.
  17. // During the genesis procedure, this data structure will be assembled using off-chain collaborative tooling
  18. // like GitHub using a human-readable encoding, so readability is a concern.
  19. message GuardianSetUpdate {
  20. // Index of the current guardian set to be replaced.
  21. uint32 current_set_index = 1;
  22. // UNIX timestamp (s) of the VAA to be created. The timestamp is informational and will be part
  23. // of the VAA submitted to the chain. It's part of the VAA digest and has to be identical across nodes.
  24. //
  25. // For lockups, the timestamp identifies the block that the lockup belongs to. For guardian set updates,
  26. // we create the VAA manually. Best practice is to pick a timestamp which roughly matches the expected
  27. // genesis ceremony data.
  28. //
  29. // The actual on-chain guardian set creation timestamp will be set when the VAA is accepted on each chain.
  30. //
  31. // This is a uint32 to match the on-chain timestamp representation. This becomes a problem in 2106 (sorry).
  32. uint32 timestamp = 2;
  33. // List of guardian set members.
  34. message Guardian {
  35. // Guardian key pubkey. Stored as hex string with 0x prefix for human readability -
  36. // this is the canonical Ethereum representation.
  37. string pubkey = 1;
  38. // Optional descriptive name. Not stored on any chain, purely informational.
  39. string name = 2;
  40. };
  41. repeated Guardian guardians = 3;
  42. }
  43. message SubmitGuardianSetVAARequest {
  44. GuardianSetUpdate guardian_set = 1;
  45. }
  46. message SubmitGuardianSetVAAResponse {
  47. // Canonical digest of the submitted VAA.
  48. bytes digest = 1;
  49. }
  50. // GuardianKey specifies the on-disk format for a node's guardian key.
  51. message GuardianKey {
  52. // data is the binary representation of the secp256k1 private key.
  53. bytes data = 1;
  54. }