Skip to content

[Feature]: External Control Channel for Medusa #740

@aviggiano

Description

@aviggiano

Feature Description

Description

In some workflows, it would be useful to instruct a running Medusa instance to perform specific actions on demand:

  • Add entries to the corpus
  • Save the current corpus
  • Stop shrinking
  • etc

This is useful when running Medusa in "detached mode" (such as in a cloud environments), where humans or AI can operate in parallel to gather additional insights about the codebase during a long fuzzing session.

Proposal

Enable an external process to send commands to a running Medusa instance. Two possible approaches:

  1. POSIX Signal-Based Actions

Medusa could interpret specific signals as commands:

kill -SIGUSR1   # ACTION_SAVE_CORPUS
kill -SIGUSR2   # ACTION_STOP_SHRINKING
...

On receiving a signal, Medusa would enqueue the corresponding action to be processed safely at the next stable point in its loop.

  1. Alternative IPC

If signals are limiting, we can consider having an RPC/HTTP interface with a more robust API, but I'd estimate this requires considerable more work

Problem / Use Case

Cross post from crytic/echidna#1489

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions