fireeye / HXTool

HXTool is an extended user interface for the FireEye HX Endpoint product. HXTool can be installed on a dedicated server or on your physical workstation. HXTool provides additional features and capabilities over the standard FireEye HX web user interface. HXTool uses the fully documented REST API that comes with the FireEye HX for communication with the HX environment.
Other
79 stars 49 forks source link

Instructions for setting up with mod_wsgi or gunicorn? #18

Open moshekaplan opened 4 years ago

moshekaplan commented 4 years ago

Would it be possible to provide instructions for setting up hxtool with mod_wsgi or gunicorn?

B0fH commented 4 years ago

Hi @moshekaplan - Unfortunately, due to the way HXTool currently interacts with the scheduler and database objects (via singletons), leveraging gunicorn and mod_wsgi with multiple workers breaks the application. This is due to the overall challenges of IPC in Python - current implementations leverage pickle, and many objects in those classes cannot be pickled. Though you could potentially run HXTool in gunicorn with a single worker, but that wouldn't give you any more benefit than leveraging Flask's internal web server.

That said, I have it on my bucket list to convert both scheduler and the database classes to some form of remoting so that they can run within their own processes. Once this is done, HXTool should run just fine under gunicorn or mod_wsgi.

Thanks, Elazar

moshekaplan commented 4 years ago

No worries. I had been asking for instructions because hxtool.py:616 mentions gunicorn and mod_wsgi support.