Skip to content

Commit e180431

Browse files
authored
Merge pull request #24 from FuzzingLabs/fix/cleanup-and-bugs
fix: resolve live monitoring bug, remove deprecated parameters, and auto-start Python worker
2 parents 1c3c7a8 + 6ca5cf3 commit e180431

File tree

29 files changed

+61
-179
lines changed

29 files changed

+61
-179
lines changed

.github/workflows/test.yml

Lines changed: 49 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -26,30 +26,62 @@ jobs:
2626
with:
2727
fetch-depth: 0 # Fetch all history for proper diff
2828

29-
- name: Check if workers were modified
29+
- name: Check which workers were modified
3030
id: check-workers
3131
run: |
3232
if [ "${{ github.event_name }}" == "pull_request" ]; then
3333
# For PRs, check changed files
3434
CHANGED_FILES=$(git diff --name-only origin/${{ github.base_ref }}...HEAD)
3535
echo "Changed files:"
3636
echo "$CHANGED_FILES"
37-
38-
if echo "$CHANGED_FILES" | grep -q "^workers/\|^docker-compose.yml"; then
39-
echo "workers_modified=true" >> $GITHUB_OUTPUT
40-
echo "✅ Workers or docker-compose.yml modified - will build"
41-
else
42-
echo "workers_modified=false" >> $GITHUB_OUTPUT
43-
echo "⏭️ No worker changes detected - skipping build"
44-
fi
4537
else
4638
# For direct pushes, check last commit
4739
CHANGED_FILES=$(git diff --name-only HEAD~1 HEAD)
48-
if echo "$CHANGED_FILES" | grep -q "^workers/\|^docker-compose.yml"; then
49-
echo "workers_modified=true" >> $GITHUB_OUTPUT
50-
else
51-
echo "workers_modified=false" >> $GITHUB_OUTPUT
52-
fi
40+
fi
41+
42+
# Check if docker-compose.yml changed (build all workers)
43+
if echo "$CHANGED_FILES" | grep -q "^docker-compose.yml"; then
44+
echo "workers_to_build=worker-python worker-secrets worker-rust worker-android worker-ossfuzz" >> $GITHUB_OUTPUT
45+
echo "workers_modified=true" >> $GITHUB_OUTPUT
46+
echo "✅ docker-compose.yml modified - building all workers"
47+
exit 0
48+
fi
49+
50+
# Detect which specific workers changed
51+
WORKERS_TO_BUILD=""
52+
53+
if echo "$CHANGED_FILES" | grep -q "^workers/python/"; then
54+
WORKERS_TO_BUILD="$WORKERS_TO_BUILD worker-python"
55+
echo "✅ Python worker modified"
56+
fi
57+
58+
if echo "$CHANGED_FILES" | grep -q "^workers/secrets/"; then
59+
WORKERS_TO_BUILD="$WORKERS_TO_BUILD worker-secrets"
60+
echo "✅ Secrets worker modified"
61+
fi
62+
63+
if echo "$CHANGED_FILES" | grep -q "^workers/rust/"; then
64+
WORKERS_TO_BUILD="$WORKERS_TO_BUILD worker-rust"
65+
echo "✅ Rust worker modified"
66+
fi
67+
68+
if echo "$CHANGED_FILES" | grep -q "^workers/android/"; then
69+
WORKERS_TO_BUILD="$WORKERS_TO_BUILD worker-android"
70+
echo "✅ Android worker modified"
71+
fi
72+
73+
if echo "$CHANGED_FILES" | grep -q "^workers/ossfuzz/"; then
74+
WORKERS_TO_BUILD="$WORKERS_TO_BUILD worker-ossfuzz"
75+
echo "✅ OSS-Fuzz worker modified"
76+
fi
77+
78+
if [ -z "$WORKERS_TO_BUILD" ]; then
79+
echo "workers_modified=false" >> $GITHUB_OUTPUT
80+
echo "⏭️ No worker changes detected - skipping build"
81+
else
82+
echo "workers_to_build=$WORKERS_TO_BUILD" >> $GITHUB_OUTPUT
83+
echo "workers_modified=true" >> $GITHUB_OUTPUT
84+
echo "Building workers:$WORKERS_TO_BUILD"
5385
fi
5486
5587
- name: Set up Docker Buildx
@@ -59,8 +91,9 @@ jobs:
5991
- name: Build worker images
6092
if: steps.check-workers.outputs.workers_modified == 'true'
6193
run: |
62-
echo "Building worker Docker images..."
63-
docker compose build worker-python worker-secrets worker-rust worker-android worker-ossfuzz --no-cache
94+
WORKERS="${{ steps.check-workers.outputs.workers_to_build }}"
95+
echo "Building worker Docker images: $WORKERS"
96+
docker compose build $WORKERS --no-cache
6497
continue-on-error: false
6598

6699
lint:

CHANGELOG.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
4040

4141
#### Documentation
4242
- Updated README for Temporal + MinIO architecture
43-
- Removed obsolete `volume_mode` references across all documentation
4443
- Added `.env` configuration guide for AI agent API keys
4544
- Fixed worker startup instructions with correct service names
4645
- Updated docker compose commands to modern syntax

ai/src/fuzzforge_ai/agent_executor.py

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -831,20 +831,9 @@ async def list_fuzzforge_runs(
831831
async def submit_security_scan_mcp(
832832
workflow_name: str,
833833
target_path: str = "",
834-
volume_mode: str = "",
835834
parameters: Dict[str, Any] | None = None,
836835
tool_context: ToolContext | None = None,
837836
) -> Any:
838-
# Normalise volume mode to supported values
839-
normalised_mode = (volume_mode or "ro").strip().lower().replace("-", "_")
840-
if normalised_mode in {"read_only", "readonly", "ro"}:
841-
normalised_mode = "ro"
842-
elif normalised_mode in {"read_write", "readwrite", "rw"}:
843-
normalised_mode = "rw"
844-
else:
845-
# Fall back to read-only if we can't recognise the input
846-
normalised_mode = "ro"
847-
848837
# Resolve the target path to an absolute path for validation
849838
resolved_path = target_path or "."
850839
try:
@@ -883,7 +872,6 @@ async def submit_security_scan_mcp(
883872
payload = {
884873
"workflow_name": workflow_name,
885874
"target_path": resolved_path,
886-
"volume_mode": normalised_mode,
887875
"parameters": cleaned_parameters,
888876
}
889877
result = await _call_fuzzforge_mcp("submit_security_scan_mcp", payload)

backend/mcp-config.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@
2222
"parameters": {
2323
"workflow_name": "string",
2424
"target_path": "string",
25-
"volume_mode": "string (ro|rw)",
2625
"parameters": "object"
2726
}
2827
},

backend/src/main.py

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -212,14 +212,6 @@ def _lookup_workflow(workflow_name: str):
212212
metadata = info.metadata
213213
defaults = metadata.get("default_parameters", {})
214214
default_target_path = metadata.get("default_target_path") or defaults.get("target_path")
215-
supported_modes = metadata.get("supported_volume_modes") or ["ro", "rw"]
216-
if not isinstance(supported_modes, list) or not supported_modes:
217-
supported_modes = ["ro", "rw"]
218-
default_volume_mode = (
219-
metadata.get("default_volume_mode")
220-
or defaults.get("volume_mode")
221-
or supported_modes[0]
222-
)
223215
return {
224216
"name": workflow_name,
225217
"version": metadata.get("version", "0.6.0"),
@@ -229,9 +221,7 @@ def _lookup_workflow(workflow_name: str):
229221
"parameters": metadata.get("parameters", {}),
230222
"default_parameters": metadata.get("default_parameters", {}),
231223
"required_modules": metadata.get("required_modules", []),
232-
"supported_volume_modes": supported_modes,
233-
"default_target_path": default_target_path,
234-
"default_volume_mode": default_volume_mode
224+
"default_target_path": default_target_path
235225
}
236226

237227

@@ -256,10 +246,6 @@ async def list_workflows_mcp() -> Dict[str, Any]:
256246
"description": metadata.get("description", ""),
257247
"author": metadata.get("author"),
258248
"tags": metadata.get("tags", []),
259-
"supported_volume_modes": metadata.get("supported_volume_modes", ["ro", "rw"]),
260-
"default_volume_mode": metadata.get("default_volume_mode")
261-
or defaults.get("volume_mode")
262-
or "ro",
263249
"default_target_path": metadata.get("default_target_path")
264250
or defaults.get("target_path")
265251
})

backend/src/models/findings.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
# Additional attribution and requirements are provided in the NOTICE file.
1515

1616
from pydantic import BaseModel, Field
17-
from typing import Dict, Any, Optional, Literal, List
17+
from typing import Dict, Any, Optional, List
1818
from datetime import datetime
1919

2020

@@ -73,10 +73,6 @@ class WorkflowMetadata(BaseModel):
7373
default_factory=list,
7474
description="Required module names"
7575
)
76-
supported_volume_modes: List[Literal["ro", "rw"]] = Field(
77-
default=["ro", "rw"],
78-
description="Supported volume mount modes"
79-
)
8076

8177

8278
class WorkflowListItem(BaseModel):

backend/toolbox/workflows/atheris_fuzzing/metadata.yaml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,6 @@ tags:
1616
# - "copy-on-write": Download once, copy for each run (balances performance and isolation)
1717
workspace_isolation: "isolated"
1818

19-
default_parameters:
20-
target_file: null
21-
max_iterations: 1000000
22-
timeout_seconds: 1800
23-
2419
parameters:
2520
type: object
2621
properties:

backend/toolbox/workflows/cargo_fuzzing/metadata.yaml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,6 @@ tags:
1616
# - "copy-on-write": Download once, copy for each run (balances performance and isolation)
1717
workspace_isolation: "isolated"
1818

19-
default_parameters:
20-
target_name: null
21-
max_iterations: 1000000
22-
timeout_seconds: 1800
23-
sanitizer: "address"
24-
2519
parameters:
2620
type: object
2721
properties:

backend/toolbox/workflows/gitleaks_detection/metadata.yaml

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -30,13 +30,5 @@ parameters:
3030
default: false
3131
description: "Scan files without Git context"
3232

33-
default_parameters:
34-
scan_mode: "detect"
35-
redact: true
36-
no_git: false
37-
3833
required_modules:
3934
- "gitleaks"
40-
41-
supported_volume_modes:
42-
- "ro"

backend/toolbox/workflows/llm_analysis/metadata.yaml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,6 @@ tags:
1313
# Workspace isolation mode
1414
workspace_isolation: "shared"
1515

16-
default_parameters:
17-
agent_url: "http://fuzzforge-task-agent:8000/a2a/litellm_agent"
18-
llm_model: "gpt-5-mini"
19-
llm_provider: "openai"
20-
max_files: 5
21-
2216
parameters:
2317
type: object
2418
properties:

0 commit comments

Comments
 (0)