Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -713,7 +713,7 @@ script:
- contextPath: ReversingLabs.a1000_upload_from_url_actions
description: Actions for uploading a sample from a URL and fetching the analysis results.
type: Unknown
dockerimage: demisto/reversinglabs-sdk-py3:2.0.0.96712
dockerimage: demisto/reversinglabs-sdk-py3:2.0.0.98754
runonce: false
script: '-'
subtype: python3
Expand Down
2 changes: 1 addition & 1 deletion Packs/ReversingLabs_A1000/ReleaseNotes/2_4_0.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#### Integrations
##### ReversingLabs A1000 v2
- Updated the Docker image to: *demisto/reversinglabs-sdk-py3:2.0.0.96712*.
- Updated the Docker image to: *demisto/reversinglabs-sdk-py3:2.0.0.98754*.

- Added new commands:
- ***reversinglabs-a1000-user-tags***
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ script:
- contextPath: ReversingLabs.yara_id
description: Identifier of the current set of YARA rules on the TitaniumScale Worker instance.
type: Unknown
dockerimage: demisto/reversinglabs-sdk-py3:2.0.0.96712
dockerimage: demisto/reversinglabs-sdk-py3:2.0.0.98754
runonce: false
script: '-'
subtype: python3
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import json
import io
from ReversingLabsTitaniumScale import parse_report_and_return_results, parse_upload_report_and_return_results, format_proxy
from ReversingLabsTitaniumScale import parse_report_and_return_results, parse_upload_report_and_return_results, format_proxy, \
classification_to_score, get_status_from_classification, list_processing_tasks_output, get_yara_id_output


def test_parse_report_and_return_results():
Expand Down Expand Up @@ -29,9 +30,40 @@ def test_format_proxy():
password="pass1"
)

formatted_http = format_proxy(
addr="http://proxy-address.com",
username="user1",
password="pass1"
)

correct_expected = "https://user1:pass1@proxy-address.com"

assert formatted_correctly == correct_expected
assert formatted_http != correct_expected


def test_classification_to_score():
assert classification_to_score("MALICIOUS") == 3
assert classification_to_score("SUSPICIOUS") == 2


def test_get_status_from_classification():
assert get_status_from_classification(3) == "malicious"
assert get_status_from_classification(2) == "suspicious"


def test_list_processing_tasks_output():
test_response = util_load_json("test_data/tiscale_list_processing_response.json")
result = list_processing_tasks_output(resp_json=test_response)

assert result.to_context().get("Contents").get("list_processing_tasks")[0].get("task_id") == 43


def test_get_yara_id_output():
test_response = {"id": "f0a151ce303ae9b9e46b236492ac9196f3f72490"}
result = get_yara_id_output(resp_json=test_response)

assert result.to_context().get("Contents").get("yara_id").get("id") == "f0a151ce303ae9b9e46b236492ac9196f3f72490"


def util_load_json(path):
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[
{"submitted":1718708239,"task_id":43,"processed":null,"worker_ip":["11.22.33.44"],"worker_address":["tiscale-worker01.com"],"worker_hostname":"tiscale-worker01","direct_sender":"1.2.3.4","forwarded_for":[]}
]
7 changes: 6 additions & 1 deletion Packs/ReversingLabs_TitaniumScale/ReleaseNotes/1_2_0.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
#### Integrations
##### ReversingLabs TitaniumScale
- Updated the Docker image to *demisto/reversinglabs-sdk-py3:2.0.0.96712*.
- Updated the Docker image to *demisto/reversinglabs-sdk-py3:2.0.0.98754*.

- Added new commands:
- ***reversinglabs-titaniumscale-list-processing-tasks***
- ***reversinglabs-titaniumscale-get-processing-task-info***
- ***reversinglabs-titaniumscale-delete-processing-task***
- ***reversinglabs-titaniumscale-delete-multiple-tasks***
- ***reversinglabs-titaniumscale-get-yara-id***

- Added the following arguments to the ***reversinglabs-titaniumscale-upload-sample-and-get-results*** and ***reversinglabs-titaniumscale-upload-sample*** commands:
- *custom_token*
- *user_data*
- *custom_data*
Original file line number Diff line number Diff line change
Expand Up @@ -833,7 +833,7 @@ script:
- contextPath: ReversingLabs.customer_usage_yara
description: Number of active YARA rulesets.
type: Unknown
dockerimage: demisto/reversinglabs-sdk-py3:2.0.0.97533
dockerimage: demisto/reversinglabs-sdk-py3:2.0.0.98754
runonce: false
script: "-"
subtype: python3
Expand Down
2 changes: 1 addition & 1 deletion Packs/ReversingLabs_Titanium_Cloud/ReleaseNotes/2_6_0.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#### Integrations
##### ReversingLabs TitaniumCloud v2

- Updated the Docker image to: *demisto/reversinglabs-sdk-py3:2.0.0.96712*.
- Updated the Docker image to: *demisto/reversinglabs-sdk-py3:2.0.0.98754*.

- Added new commands:
- ***reversinglabs-titaniumcloud-customer-usage-data***
Expand Down