nmap_service_detection
Identify running services and their versions on network targets to assess security posture and detect vulnerabilities.
Instructions
Perform service and version detection scan
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| targets | Yes | ||
| ports | No | common | |
| intensity | No |
Implementation Reference
- server.py:121-124 (registration)Registration of the 'nmap_service_detection' tool using the @app.tool decorator, specifying name and description.@app.tool( name="nmap_service_detection", description="Perform service and version detection scan" )
- server.py:125-138 (handler)Handler function that executes Nmap service and version detection scan by constructing arguments and calling the shared run_nmap_command helper.async def nmap_service_detection( targets: str, ports: str = "common", intensity: int = 7 ) -> str: """Perform service and version detection scan.""" args = ["-sV", f"--version-intensity={intensity}", "-p", ports, targets] result = run_nmap_command(args) if result["success"]: return f"Service detection scan completed:\n\n{result['stdout']}" else: return f"Service detection scan failed:\n\n{result['stderr']}"