mirror of
https://github.com/trailofbits/buttercup
synced 2026-06-21 14:11:39 +00:00
e0b898a6b4
* program-model/tree-sitter: refactor classes * program-model/tree-sitter: change how paths are considered This allows to parse also code in oss-fuzz (e.g. injected fuzz targets not in upstream project) * common: change name format for challenge commit * program-model/codequery: make it persistent and nice * program-model: disable janus & co for now * patcher: make use of codequery instead of just tree-sitter * program-model: add integration tests for codequery * program-model/codequery: add support for different languages * patcher: install codequery in patcher's container * ci: fix codequery install * program-model: ensure cqdb storage in /crs_scratch * program-model: ensure the cqdb storage is available only at the end
Buttercup Common utilities
Protobufs
The protos directory contains the protobuf definitions for various messages used by the Buttercup system.
Message Publisher utility
The buttercup-msg-publisher script is a utility for pushing custom messages to a queue.
$ buttercup-msg-publisher list
$ cat /tmp/msg.proto
task {
message_id: "my-message-id"
message_time: 123
task_id: "my-task-id"
task_type: TASK_TYPE_DELTA
sources {
url: "https://github.com/buttercup-project/buttercup"
}
sources {
source_type: SOURCE_TYPE_FUZZ_TOOLING
url: "https://github.com/buttercup-project/fuzz-tooling"
}
sources {
source_type: SOURCE_TYPE_DIFF
url: "https://github.com/buttercup-project/diff"
}
deadline: 123
}
$ buttercup-msg-publisher send tasks_ready_queue /tmp/msg.proto
2025-01-28 13:38:37,674 - buttercup.common.msg_publisher - INFO - Reading TaskReady message from file '/tmp/msg.proto'
2025-01-28 13:38:37,675 - buttercup.common.msg_publisher - INFO - Pushing message to queue 'tasks_ready_queue': task {
message_id: "my-message-id"
message_time: 123
task_id: "my-task-id"
task_type: TASK_TYPE_DELTA
sources {
url: "https://github.com/buttercup-project/buttercup"
}
sources {
source_type: SOURCE_TYPE_FUZZ_TOOLING
url: "https://github.com/buttercup-project/fuzz-tooling"
}
sources {
source_type: SOURCE_TYPE_DIFF
url: "https://github.com/buttercup-project/diff"
}
deadline: 123
}