Out of Band Code Evaluation (Python)
Summary#
Invicti identified a Remote Code Evaluation (Python) by capturing a DNS A request, which occurs when input data is run as code.
This is a highly critical issue and should be addressed as soon as possible.
Impact#
An attacker can execute arbitrary Python code on the system. The attacker may also be able to execute arbitrary system commands.
Remediation#
Do not accept input from end users that will be directly interpreted as source code. If this is a business requirement, validate all the input on the application and remove all the data that could be directly interpreted as Python source code.
Required Skills for Successful Exploitation#
This vulnerability is not difficult to leverage. Python is a high level language for which there are vast resources available. Successful exploitation requires knowledge of the programming language, access to the source code or the ability to produce source code for use in such attacks, and minimal attack skills.