| 429 | |
| 430 | # Format tools result |
| 431 | class FormatToolsResultCommand(sublime_plugin.TextCommand): |
| 432 | def run(self, edit, tool, mode): |
| 433 | text = get_buffer_text(self.view) |
| 434 | |
| 435 | if tool == 'fscan': |
| 436 | results = classify_fscan_result(text) |
| 437 | for key in results.keys(): |
| 438 | syntax = SYNTAX_FILE if key in ['web-info.txt','weak-password.txt'] else '' |
| 439 | new_view(self.view, edit, results.get(key), syntax=syntax, filename=key) |
| 440 | |
| 441 | return None |
| 442 | |
| 443 | if tool == 'nmap': |
| 444 | try: |
| 445 | text = format_nmap_open_port(text, mode) |
| 446 | except: |
| 447 | text = select_nmap_ports_from_xml(text, mode) |
| 448 | |
| 449 | new_view(self.view, edit, text) |
| 450 | |
| 451 | if tool == 'dirsx': |
| 452 | text = format_dirsx_result(text) |
| 453 | new_view(self.view, edit, text, SYNTAX_FILE) |
| 454 | |
| 455 | |
| 456 | # highlight httpx nulcie result |
nothing calls this directly
no outgoing calls
no test coverage detected