TheHive4py
TheHive4py copied to clipboard
Error when using API to generate case from email and include attachments
Request Type
Bug
Work Environment
| OS version (server) | CentOS 7 |Hive version | 3.5.1 | TheHive4py version / git hash | 1.8.1
Problem Description
Attempting to use API (imap2thehive) to create a case from email and include attachments as files. Error is below
Traceback (most recent call last):
File "./imap2thehive.py", line 555, in
Any help would be greatly appreciated
Having same issue with Ews2Case, downgrading to thehive4py 1.8.0 fixes the issue I am having below:
Traceback (most recent call last):
File "/opt/Synapse/workflows/Ews2Case.py", line 139, in connectEws
theHiveConnector.addFileObservable(esCaseId, tmpFilepath, comment)
File "/opt/Synapse/workflows/objects/TheHiveConnector.py", line 232, in addFileObservable
message=comment
File "/usr/local/lib/python3.7/site-packages/thehive4py/models.py", line 591, in __init__
file_object = open(filename, 'rb')
TypeError: expected str, bytes or os.PathLike object, not list
Request Type
Bug
Work Environment
| OS version (server) | CentOS 7 |Hive version | 3.5.1 | TheHive4py version / git hash | 1.8.1
Problem Description
Attempting to use API (imap2thehive) to create a case from email and include attachments as files. Error is below
Traceback (most recent call last): File "./imap2thehive.py", line 555, in main() File "./imap2thehive.py", line 551, in main readMail(mailConnect()) File "./imap2thehive.py", line 424, in readMail if submitTheHive(message) == True: File "./imap2thehive.py", line 363, in submitTheHive message = 'Found as email attachment' File "/usr/local/lib/python3.6/site-packages/thehive4py/models.py", line 591, in init file_object = open(filename, 'rb') TypeError: expected str, bytes or os.PathLike object, not list
Any help would be greatly appreciated @glwallum Hi, Did you found the answer for the problem? I am currently stuck and got the exact same issue as your. can you help me out here? thank in advance