Skip to content

Commit

Permalink
Verdict result fix (demisto#34575)
Browse files Browse the repository at this point in the history
* Add support for "suspicious" verdict in the script

* Update unitest

* Update unitest

* Update script

* update docker image

* RN
  • Loading branch information
tomer-pan authored May 28, 2024
1 parent 7e96aa2 commit 06a2419
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 2 deletions.
7 changes: 7 additions & 0 deletions Packs/CommonScripts/ReleaseNotes/1_15_2.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@

#### Scripts

##### VerdictResult

- Added support for **Suspicious** verdict.
- Updated the Docker image to: *demisto/python3:3.10.14.95956*.
5 changes: 5 additions & 0 deletions Packs/CommonScripts/Scripts/VerdictResult/VerdictResult.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
import demistomock as demisto # noqa: F401
from CommonServerPython import * # noqa: F401

RED_HTML_STYLE = "color:#FF1744;text-align:center;font-size:300%;padding-top:1em>"
GREEN_HTML_STYLE = "color:#00CD33;text-align:center;font-size:300%;padding-top:1em>"
ORANGE_HTML_STYLE = "color:#FF9000;text-align:center;font-size:300%;padding-top:1em>"
GREY_HTML_STYLE = "color:#808080;text-align:center;font-size:300%;padding-top:1em>"


Expand All @@ -11,6 +13,9 @@ def main():
if investigationverdict == 'Malicious':
html = f"<h1 style={RED_HTML_STYLE}Malicious</h1>"

elif investigationverdict == 'Suspicious':
html = f"<h1 style={ORANGE_HTML_STYLE}Suspicious</h1>"

elif investigationverdict == 'Non-Malicious':
html = f"<h1 style={GREEN_HTML_STYLE}Non-Malicious</h1>"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ comment: This widget displays the incident verdict or the alert verdict based on
commonfields:
id: VerdictResult
version: -1
dockerimage: demisto/python3:3.10.13.83255
dockerimage: demisto/python3:3.10.14.95956
enabled: true
engineinfo: {}
name: VerdictResult
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
[
('Malicious', '<h1 style=color:#FF1744;text-align:center;font-size:300%;padding-top:1em>Malicious</h1>'),
('Non-Malicious', '<h1 style=color:#00CD33;text-align:center;font-size:300%;padding-top:1em>Non-Malicious</h1>'),
('Suspicious', '<h1 style=color:#FF9000;text-align:center;font-size:300%;padding-top:1em>Suspicious</h1>'),
('blabla', '<h1 style=color:#808080;text-align:center;font-size:300%;padding-top:1em>Not Determined</h1>')
]
)
Expand Down
2 changes: 1 addition & 1 deletion Packs/CommonScripts/pack_metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "Common Scripts",
"description": "Frequently used scripts pack.",
"support": "xsoar",
"currentVersion": "1.15.1",
"currentVersion": "1.15.2",
"author": "Cortex XSOAR",
"url": "https://www.paloaltonetworks.com/cortex",
"email": "",
Expand Down

0 comments on commit 06a2419

Please sign in to comment.