Skip to content

Prompt Injection Leading to Remote Code Execution (RCE) via Unsanitized User Input URL #3

@bayegaspard

Description

@bayegaspard
Screenshot 2024-09-29 112846 Prompt injection can lead to arbitrary Remote Code Execution (RCE) when user-supplied inputs, such as a URL, are not properly sanitized. In this example (./ffufai.py --max-extensions 5 -u https://hello.com`id`), the command injection occurs because the input (`id`) is being executed as part of the system command. This allows an attacker to run arbitrary commands on the system, like `id` (which displays user identity information), exploiting the input field's vulnerability to execute harmful actions. Proper input sanitization and validation can help prevent such attacks. Check the screenshot for a PoC.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions