Submitted by 0xAlix2
https://github.com/initia-labs/opinit-bots/blob/640649b97cbfa5782925b7dc8c0b62b8fa5367f6/challenger/child/handler.go#L95
The Challenger is a critical process responsible for monitoring the Executors output proposals and challenging any invalid submissions. It ensures the integrity of the rollups state and prevents malicious actions by the Executor.
The Challenger operates by accumulating emitted events from both the L1 and L2 chains. At the end of every L2 block, a handler is triggered to validate the events and determine if any challenges need to be issued.
When a user deposits tokens into the L2 by sending an InitiateTokenDeposit transaction on the L1, the following event is emitted:  
Event emission in L1:
This event is caught by the host component in the Challenger and saved to the childs database at the end of the L1 block:  
Host event saving:
When the Executor finalizes the deposit on the L2 by sending a FinalizeTokenDeposit message, the following event is emitted:  
Event emission in L2:
The child component of the Challenger catches this event and saves it in the childs database.
At the end of an L2 block, the endBlockHandler is called:
The handler performs the following steps:
However, at 4@, the handler sends only the challenges variable, which is overridden when fetching timeout events. This results in discrepancies being missed, as they are not included in pendingChallenges. 
The SendPendingChallenges function sends these challenges to a channel (c.challengeCh) for asynchronous handling. The challengeHandler function, running in a separate goroutine, processes challenges from this channel, the discrepancy events wont be included in this.
This defeats the purpose of the Challenger bot, allowing malicious Executors to act without detection.
beer-1 (Initia) confirmed and commented:
berndartmueller (warden) commented:
a_kalout (warden) commented:
LSDan (judge) commented:
