Skip to content

Commit

Permalink
Ignore nitro messages in feed
Browse files Browse the repository at this point in the history
  • Loading branch information
joshuacolvin0 authored and hkalodner committed Aug 21, 2022
1 parent 74bcde8 commit 921771f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/arb-node-core/monitor/inboxReader.go
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,11 @@ func (ir *InboxReader) GetSequencerInboxWatcher() *ethbridge.SequencerInboxWatch
}

func (ir *InboxReader) isValidSignature(ctx context.Context, message broadcaster.BroadcastFeedMessage) bool {
if message.FeedItem.BatchItem.SequencerMessage == nil {
// Nitro feed message, ignore
return false
}

accHash := hashing.SoliditySHA3WithPrefix(hashing.Bytes32(message.FeedItem.BatchItem.Accumulator))
sigPublicKey, err := crypto.SigToPub(accHash.Bytes(), message.Signature)
if err != nil {
Expand Down

0 comments on commit 921771f

Please sign in to comment.