Skip to content

Commit

Permalink
fix: [server] Serializing PyMISP objects
Browse files Browse the repository at this point in the history
  • Loading branch information
JakubOnderka committed Jan 9, 2024
1 parent 9446fd2 commit 5b57b8b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion misp_modules/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@
from tornado.ioloop import IOLoop
from tornado.concurrent import run_on_executor
from concurrent.futures import ThreadPoolExecutor
from pymisp import pymisp_json_default

try:
from .modules import * # noqa
Expand Down Expand Up @@ -202,7 +203,7 @@ def run_request(self, module_name, json_payload, dict_payload):
response = module.dict_handler(request=dict_payload)
else:
response = module.handler(q=json_payload)
return json.dumps(response)
return json.dumps(response, default=pymisp_json_default)

@tornado.gen.coroutine
def post(self):
Expand Down

0 comments on commit 5b57b8b

Please sign in to comment.