TheHive4py icon indicating copy to clipboard operation
TheHive4py copied to clipboard

[BUG] v3.4.2-1 find_cases returns empty array

Open elissandro13 opened this issue 4 years ago • 0 comments

Request Type

Bug

Work Environment

Question Answer
OS version (server) CentoOS
OS version (client) Win 10
TheHive4py version / git hash The Hive 3.4.2-1

Problem Description

The find_cases function doesn't return data even if the case that matches the description title exists

Steps to Reproduce

  1. Execute the following code
from thehive4py.api import TheHiveApi
from thehive4py.query import Eq
class TheHiveAPI():
    def __init__(self):
        THEHIVE_URL, THEHIVE_API_KEY = '', ''
        self.api = TheHiveApi(THEHIVE_URL, THEHIVE_API_KEY)
    def get_cases(self):
        query = Eq('title', r'Compromise/Beacon\n')
        response = self.api.find_cases(query=query)
        return response
if __name__ == '__main__':
    response = TheHiveAPI().get_cases()
    print(response)
    print(response.json())

  1. Return: image

  2. Proof that the case exists image

elissandro13 avatar Sep 30 '21 19:09 elissandro13