(self, handler)
| 294 | handler.end_headers() |
| 295 | |
| 296 | def serve_credentials_data(self, handler): |
| 297 | try: |
| 298 | directory = self.shared_data.crackedpwddir |
| 299 | html_content = self.generate_html_for_csv_files(directory) |
| 300 | handler.send_response(200) |
| 301 | handler.send_header("Content-type", "text/html") |
| 302 | handler.end_headers() |
| 303 | handler.wfile.write(html_content.encode('utf-8')) |
| 304 | except Exception as e: |
| 305 | handler.send_response(500) |
| 306 | handler.send_header("Content-type", "application/json") |
| 307 | handler.end_headers() |
| 308 | handler.wfile.write(json.dumps({"status": "error", "message": str(e)}).encode('utf-8')) |
| 309 | |
| 310 | def generate_html_for_csv_files(self, directory): |
| 311 | html = '<div class="credentials-container">\n' |
nothing calls this directly
no test coverage detected