Skip to content

Commit

Permalink
check correct fork version in LC sync protocol
Browse files Browse the repository at this point in the history
  • Loading branch information
etan-status committed Mar 8, 2023
1 parent 90640cc commit 467df48
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion beacon_chain/spec/light_client_sync.nim
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,8 @@ proc validate_light_client_update*(
if bit:
participant_pubkeys.add(sync_committee.pubkeys.data[idx])
let
fork_version = cfg.forkVersionAtEpoch(update.signature_slot.epoch)
fork_version_slot = max(update.signature_slot, 1.Slot) - 1
fork_version = cfg.forkVersionAtEpoch(fork_version_slot.epoch)
domain = compute_domain(
DOMAIN_SYNC_COMMITTEE, fork_version, genesis_validators_root)
signing_root = compute_signing_root(update.attested_header.beacon, domain)
Expand Down

0 comments on commit 467df48

Please sign in to comment.