Skip to content

Commit 32c1ca1

Browse files
fix: hardcode 15s clock drift (#358)
Co-authored-by: Gjermund Garaba <[email protected]>
1 parent 74413db commit 32c1ca1

File tree

2 files changed

+2
-2
lines changed
  • programs/sp1-programs

2 files changed

+2
-2
lines changed

programs/sp1-programs/misbehaviour/src/lib.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ pub fn check_for_misbehaviour(
5555
let options = Options {
5656
trust_threshold: client_state.trustLevel.clone().into(),
5757
trusting_period: Duration::from_secs(client_state.trustingPeriod.into()),
58-
clock_drift: Duration::default(),
58+
clock_drift: Duration::from_secs(15),
5959
};
6060

6161
// Call into ibc-rs verify_misbehaviour function to verify that both headers are valid given their respective trusted consensus states

programs/sp1-programs/update-client/src/lib.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ pub fn update_client(
3131
let options = Options {
3232
trust_threshold: client_state.trustLevel.clone().into(),
3333
trusting_period: Duration::from_secs(client_state.trustingPeriod.into()),
34-
clock_drift: Duration::default(),
34+
clock_drift: Duration::from_secs(15),
3535
};
3636

3737
let mut ctx = types::validation::ClientValidationCtx::new(time);

0 commit comments

Comments
 (0)