Skip to content

Commit

Permalink
Merge pull request #22 from datachainlab/add-is-debug-enclave-option
Browse files Browse the repository at this point in the history
Introduce a new option `is_debug_enclave` to allow an enclave created with debug mode

Signed-off-by: Jun Kimura <[email protected]>
  • Loading branch information
bluele authored May 30, 2024
2 parents fece1f1 + bfaefb2 commit 1368293
Show file tree
Hide file tree
Showing 5 changed files with 72 additions and 34 deletions.
1 change: 1 addition & 0 deletions proto/relayer/provers/lcp/config/config.proto
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,5 @@ message ProverConfig {
string elc_client_id = 8;
bool message_aggregation = 9;
uint64 message_aggregation_batch_size = 10;
bool is_debug_enclave = 11;
}
97 changes: 66 additions & 31 deletions relay/config.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion relay/prover.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ func (pr *Prover) GetOriginProver() core.Prover {
func (pr *Prover) Init(homePath string, timeout time.Duration, codec codec.ProtoCodecMarshaler, debug bool) error {
pr.homePath = homePath
pr.codec = codec
if debug {
if pr.config.IsDebugEnclave {
ias.SetAllowDebugEnclaves()
}
if err := pr.originChain.Init(homePath, timeout, codec, debug); err != nil {
Expand Down
3 changes: 2 additions & 1 deletion tests/e2e/cases/tm2tm/configs/templates/ibc-0.json.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
"allowed_quote_statuses": ["GROUP_OUT_OF_DATE"],
"allowed_advisory_ids": ["INTEL-SA-00219","INTEL-SA-00289","INTEL-SA-00334","INTEL-SA-00477","INTEL-SA-00614","INTEL-SA-00615","INTEL-SA-00617"],
"key_expiration": 604800,
"elc_client_id": "07-tendermint-1"
"elc_client_id": "07-tendermint-1",
"is_debug_enclave": true
}
}
3 changes: 2 additions & 1 deletion tests/e2e/cases/tm2tm/configs/templates/ibc-1.json.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
"allowed_quote_statuses": ["GROUP_OUT_OF_DATE"],
"allowed_advisory_ids": ["INTEL-SA-00219","INTEL-SA-00289","INTEL-SA-00334","INTEL-SA-00477","INTEL-SA-00614","INTEL-SA-00615","INTEL-SA-00617"],
"key_expiration": 604800,
"elc_client_id": "07-tendermint-0"
"elc_client_id": "07-tendermint-0",
"is_debug_enclave": true
}
}

0 comments on commit 1368293

Please sign in to comment.