# Improper Neutralization of Directives in Dynamically Evaluated Code ('Eval Injection') (CWE-95) The product receives input from an upstream component, but it does not neutralize code syntax before using the input in a dynamic evaluation call. - Prevalence: 高 Shoulder ルールなし - Impact: ハイ OWASP Top 10 #3 - Prevention: MITRE を参照 外部参照 **OWASP:** Injection (A03:2021-Injection) - #3 ## Description When user input is passed to eval() or similar functions without sanitization, attackers can inject arbitrary code that will be executed with the application's privileges. ## Prevention ## Consequences - 未承認コードの実行 - アプリケーションデータの読み取り - アプリケーションデータの変更 ## Mitigations - eval() や同様の動的コード実行関数の使用を避ける - データ解析には JSON.parse() のような、より安全な代替手段を使用する - どうしても eval が必要な場合は、厳密な入力検証とサンドボックス化を行う