Flash-Attention Code Injection Vulnerability in Training Script Allowing Arbitrary Code Execution

Vulnerability

A code injection vulnerability has been identified in the flash-attention project, specifically in the training script prior to commit e724e2588cbe754beb97cf7c011b5e7e34119e62. The vulnerability arises because the script registers the Python eval() function as a Hydra configuration resolver, enabling the execution of arbitrary Python code through the ${eval:...} syntax. This flaw can be exploited by providing a malicious configuration file, which would be executed as code when the training script is run with that file.

Impact

Exploitation of this vulnerability allows for arbitrary code execution on the system where the training script is executed.

Added: May 11, 2026, 5:48 PM
Updated: May 11, 2026, 5:48 PM

Vulnerability Rating

Custom Algorithm
spread
0.0
impact
7.5
exploitability
3.6
remediation
0.0
relevance
8.0
threat
0.0
urgency
2.9
incentive
0.0

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.