get_scanner_output
Retrieve scanner output for a specific issue occurrence to analyze security findings and identify vulnerabilities in Intruder.IO scans.
Instructions
Get scanner output for a specific occurrence of an issue.
Args:
issue_id: The ID of the issue
occurrence_id: The ID of the occurrence
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| issue_id | Yes | ||
| occurrence_id | Yes |
Implementation Reference
- intruder_mcp/server.py:123-142 (handler)MCP tool handler for 'get_scanner_output'. Decorated with @mcp.tool(), it calls the API client to fetch all scanner outputs for the given issue and occurrence, formats them with plugin info and output lines, and returns as a string. This is both the handler logic and registration point.@mcp.tool() async def get_scanner_output(issue_id: int, occurrence_id: int) -> str: """ Get scanner output for a specific occurrence of an issue. Args: issue_id: The ID of the issue occurrence_id: The ID of the occurrence """ outputs = api.get_scanner_output_all(issue_id=issue_id, occurrence_id=occurrence_id) formatted = [] for output in outputs: plugin_info = f"Plugin: {output.plugin.name}" if output.plugin.cve: plugin_info += f" (CVEs: {', '.join(output.plugin.cve)})" formatted.append(plugin_info) formatted.append("Output:") formatted.extend(str(line) for line in output.scanner_output) formatted.append("") return "\n".join(formatted)
- intruder_mcp/api_client.py:100-108 (helper)Helper method in IntruderAPI class that fetches all scanner outputs by paginating through the API endpoints using get_scanner_output.def get_scanner_output_all(self, issue_id: int, occurrence_id: int) -> Generator[ScannerOutputList, None, None]: offset = 0 while True: response = self.get_scanner_output(issue_id, occurrence_id, limit=100, offset=offset) for output in response.results: yield output if not response.next: break offset += len(response.results)
- intruder_mcp/api_client.py:91-98 (helper)Core API client method that queries the Intruder API for paginated scanner output data for a specific issue occurrence.def get_scanner_output(self, issue_id: int, occurrence_id: int, limit: Optional[int] = None, offset: Optional[int] = None) -> PaginatedScannerOutputListList: params = {} if limit: params["limit"] = limit if offset: params["offset"] = offset return PaginatedScannerOutputListList(**self.client.get(f"{self.base_url}/issues/{issue_id}/occurrences/{occurrence_id}/scanner_output/", params=params).json())