You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
returnfmt.Errorf("the keyring backend in config must be `test` for automatic signing, got %s", cfg.BabylonConfig.KeyringBackend)
48
+
returnfmt.Errorf("the keyring backend in config must be `test` for automatic signing, got %s. Other keyring backends are not supported as they require manual passphrase entry", cfg.BabylonConfig.KeyringBackend)
Copy file name to clipboardExpand all lines: config/babylon.go
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -12,7 +12,7 @@ type BBNConfig struct {
12
12
RPCAddrstring`long:"rpc-address" description:"address of the rpc server to connect to"`
13
13
GRPCAddrstring`long:"grpc-address" description:"address of the grpc server to connect to"`
14
14
AccountPrefixstring`long:"acc-prefix" description:"account prefix to use for addresses"`
15
-
KeyringBackendstring`long:"keyring-type" description:"type of keyring to use"`
15
+
KeyringBackendstring`long:"keyring-type" description:"type of keyring to use"`// IMPORTANT: Only 'test' backend is supported due to automated signing requirements
16
16
GasAdjustmentfloat64`long:"gas-adjustment" description:"adjustment factor when using gas estimation"`
17
17
GasPricesstring`long:"gas-prices" description:"comma separated minimum gas prices to accept for transactions"`
18
18
KeyDirectorystring`long:"key-dir" description:"directory to store keys in"`
The Covenant Emulator requires the Covenant Signer to be running and
33
+
unlocked before it can start. This is a critical dependency that is enforced
34
+
through a health check during the emulator's startup process.
35
+
36
+
### Required Boot Sequence
37
+
38
+
1. Start the Covenant Signer:
39
+
2. Unlock the Covenant Signer:
40
+
3. Verify the signer is running and accessible:
41
+
4. Start the Covenant Emulator:
42
+
43
+
### Health Check Behavior
44
+
45
+
The emulator performs an automatic health check during startup by attempting
46
+
to fetch the signer's public key. If this check fails, the emulator will:
47
+
- Log an error message indicating the signer is not accessible
48
+
- Provide guidance to ensure the signer is running and unlocked
49
+
- Exit with a non-zero status code
50
+
51
+
### Troubleshooting
52
+
53
+
If the emulator fails to start with a signer-related error:
54
+
1. Verify the signer is running and accessible at the configured URL
55
+
2. Check if the signer is locked and needs to be unlocked
56
+
3. Verify the HMAC key in the emulator's configuration matches the signer's configuration
57
+
4. Check the signer's logs for any errors or issues
58
+
59
+
## 3. Install covenant emulator binary
30
60
31
61
If you haven't already, download [Golang 1.23](https://go.dev/dl).
32
62
@@ -65,9 +95,9 @@ export PATH=$HOME/go/bin:$PATH
65
95
echo'export PATH=$HOME/go/bin:$PATH'>>~/.profile
66
96
```
67
97
68
-
## 3. Setting up the covenant emulator program
98
+
## 4. Setting up the covenant emulator program
69
99
70
-
### 3.1. Initialize directories
100
+
### 4.1. Initialize directories
71
101
72
102
Next, initialize the node and home directory by generating all of the
73
103
necessary files such as `covd.conf`. These files will live in the `<path>`
@@ -85,7 +115,7 @@ $ ls <path>
85
115
├── logs # Covd logs
86
116
```
87
117
88
-
### 3.2. Configure the covenant emulator
118
+
### 4.2. Configure the covenant emulator
89
119
90
120
Use the following parameters to configure the `covd.conf` file.
91
121
@@ -140,11 +170,19 @@ Below are brief explanations of the configuration entries:
140
170
-`GRPCAddr` - gRPC endpoint for connecting to a Babylon node
141
171
-`Key` - Name of the key in the keyring used for transaction signing
142
172
-`KeyringBackend` - Storage backend for the keyring (os, file, kwallet, pass, test, memory)
173
+
174
+
> **IMPORTANT LIMITATION**: The covenant emulator only supports the `test`
175
+
keyring backend. This limitation exists because the emulator requires automated
176
+
signing capabilities and the test backend is the only one that supports this
177
+
feature without manual passphrase entry. Other keyring backends
178
+
(os, file, kwallet, pass, memory) will not work and will
179
+
cause the emulator to fail at startup.
180
+
143
181
-`URL` - Endpoint where the remote signing service is running
144
182
-`Timeout` - Maximum time to wait for remote signer responses
145
183
-`HMACKey` - Secret key for HMAC authentication with the covenant-signer
146
184
147
-
### 3.3. Configure HMAC Authentication (Recommended for Production)
185
+
### 4.3. Configure HMAC Authentication (Recommended for Production)
148
186
149
187
HMAC (Hash-based Message Authentication Code) authentication provides an additional layer of security for the communication between the covenant-emulator and covenant-signer by ensuring that only authenticated requests are processed.
When HMAC authentication is properly configured, all requests between the covenant-emulator and covenant-signer will include an authentication header. If there's a key mismatch or other authentication issues, you'll see error messages in the logs.
175
213
176
214
177
-
## 4. Generate key pairs
215
+
## 5. Generate key pairs
178
216
179
217
The covenant emulator daemon requires the existence of a Babylon keyring that
180
218
signs signatures and interacts with Babylon. Use the following command to generate
@@ -209,7 +247,7 @@ To check your balance, View your account on the
209
247
address.
210
248
211
249
212
-
## 5. Start the emulator daemon
250
+
## 6. Start the emulator daemon
213
251
214
252
You can start the covenant emulator daemon using the following command:
0 commit comments