New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ciac 8941/enhancement/cortex xdr flexible close reason mappings mirroring #33140
Merged
barryyosi-panw
merged 70 commits into
master
from
CIAC-8941/Enhancement/Cortex-XDR-Flexible-Close-Reason-Mappings-Mirroring
Mar 6, 2024
Merged
Changes from 67 commits
Commits
Show all changes
70 commits
Select commit
Hold shift + click to select a range
f767be4
Enhancing Cortex XDR IR integration with custom close-reason mapping …
barryyosi-panw 4451db6
XSOAR->XDR custom close-reason mapping support
barryyosi-panw 9949f31
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 73d5057
lint
barryyosi-panw c7ef2d3
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 77282cc
update RN
michal-dagan 712a6dd
update RN
michal-dagan 9a6b821
Updated release notes
barryyosi-panw 2f1b421
Merge
barryyosi-panw 56c546f
Fixes
barryyosi-panw 59817f0
Merge master
barryyosi-panw 3fcb374
Unittests
barryyosi-panw e951714
Documentation
barryyosi-panw cbbeb31
pre-commit fixes
barryyosi-panw 7336431
unittests labeling
barryyosi-panw e856cca
updated RN
barryyosi-panw d12e4f9
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 5a16b8f
autopep8
barryyosi-panw c47ee9c
Merge remote-tracking branch 'origin/CIAC-8941/Enhancement/Cortex-XDR…
barryyosi-panw 61af589
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 8246187
autopep8
barryyosi-panw f0463ea
Merge remote-tracking branch 'origin/CIAC-8941/Enhancement/Cortex-XDR…
barryyosi-panw a30a49f
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 7f44879
Describing `comma_separated_mapping_to_dict()`
barryyosi-panw dbb33f9
Merge remote-tracking branch 'origin/CIAC-8941/Enhancement/Cortex-XDR…
barryyosi-panw 9a3f7f8
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 618e074
Updating RN
barryyosi-panw 780b0ef
Merge remote-tracking branch 'origin/CIAC-8941/Enhancement/Cortex-XDR…
barryyosi-panw 77485db
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 5418183
mypy
barryyosi-panw 78610e6
Merge remote-tracking branch 'origin/CIAC-8941/Enhancement/Cortex-XDR…
barryyosi-panw 56ba40c
mypy
barryyosi-panw c1a4e05
autopep8
barryyosi-panw 7acd01a
merge master
barryyosi-panw ba70e89
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 020b003
Update RN
barryyosi-panw 6b3520b
Merge remote-tracking branch 'origin/CIAC-8941/Enhancement/Cortex-XDR…
barryyosi-panw f668921
yaml update
barryyosi-panw 43dad8a
Merged master into current branch.
1d42de7
Bump pack from version Base to 1.33.38.
dd628d5
Update Packs/CortexXDR/Integrations/CortexXDRIR/CortexXDRIR.yml
barryyosi-panw 70dd0e3
Update Packs/CortexXDR/Integrations/CortexXDRIR/CortexXDRIR.yml
barryyosi-panw 42f87d3
Update Packs/CortexXDR/Integrations/CortexXDRIR/CortexXDRIR.yml
barryyosi-panw 3578650
Update Packs/CortexXDR/Integrations/CortexXDRIR/CortexXDRIR.yml
barryyosi-panw d776479
Update Packs/CortexXDR/Integrations/CortexXDRIR/README.md
barryyosi-panw d78eb7b
Update Packs/ctf01/ReleaseNotes/1_0_10.md
barryyosi-panw 582b4b9
Update Packs/CortexXDR/ReleaseNotes/6_1_18.md
barryyosi-panw 0a94811
Update Packs/CortexXDR/Integrations/CortexXDRIR/README.md
barryyosi-panw 4d168de
Update Packs/CortexXDR/Integrations/CortexXDRIR/README.md
barryyosi-panw 60d2c54
Merged master into current branch.
d8ee592
Bump pack from version Core to 3.0.22.
6c944c9
Bump pack from version CortexXDR to 6.1.19.
4ba41d5
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw e2570eb
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 1820cae
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 180a772
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 112a6bf
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw fb9dc18
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 743dbf9
PR & demo fixes
barryyosi-panw 8ccbacf
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 470be0d
PR fixes
barryyosi-panw b076978
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 7e96659
Testing test module
barryyosi-panw 5296bba
Merge remote-tracking branch 'origin/CIAC-8941/Enhancement/Cortex-XDR…
barryyosi-panw f992023
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 310f990
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw 6bda322
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw e5b6c52
Merged master into current branch.
baa4eea
Bump pack from version CortexXDR to 6.1.20.
9f5ce74
Merge branch 'master' into CIAC-8941/Enhancement/Cortex-XDR-Flexible-…
barryyosi-panw File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
|
||
#### Scripts | ||
|
||
##### CommonServerPython | ||
|
||
Added a utility function `comma_separated_mapping_to_dict` that gets a comma-separated mapping `key1=value1,key2=value2,...` and transforms it into a dictionary object. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11751,6 +11751,47 @@ def data_error_handler(res): | |
demisto.updateModuleHealth({'{data_type}Pulled'.format(data_type=data_type): data_size}) | ||
|
||
|
||
def comma_separated_mapping_to_dict(raw_text): | ||
""" | ||
Transforming a textual comma-separated mapping into a dictionary object. | ||
|
||
:type raw_text: ``str`` | ||
:param raw_text: Comma-separated mapping e.g ('key1=value1', 'key2=value2', ...) | ||
|
||
:rtype: ``dict`` | ||
:return: Validated dictionary of the raw mapping e.g {'key1': 'value1', 'key2': 'value2', ...} | ||
""" | ||
demisto.debug("comma_separated_mapping_to_dict " | ||
">> Resolving comma-separated input mapping: {raw_text}".format(raw_text=raw_text)) | ||
|
||
mapping_dict = {} # type: Dict[str, str] | ||
# If a proper mapping was not provided, return an empty dict. | ||
if not raw_text: | ||
return mapping_dict | ||
|
||
key_value_pairs = raw_text.split(',') | ||
|
||
for pair in key_value_pairs: | ||
# Trimming trailing whitespace | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think this comment is redundant |
||
pair = pair.strip() | ||
|
||
try: | ||
key, value = pair.split('=') | ||
except ValueError: | ||
demisto.error("Error: Invalid mapping was provided. " | ||
"Expected comma-separated mapping of format `key1=value1, key2=value2, ...`") | ||
key = value = '' | ||
|
||
if key in mapping_dict: | ||
demisto.debug( | ||
"comma_separated_mapping_to_dict " | ||
"Warning: duplicate key provided for {key}: using latter value: {value}".format(key=key, value=value) | ||
) | ||
mapping_dict[key] = value | ||
demisto.debug("comma_separated_mapping_to_dict << Resolved mapping: {mapping_dict}".format(mapping_dict=mapping_dict)) | ||
return mapping_dict | ||
|
||
|
||
########################################### | ||
# DO NOT ADD LINES AFTER THIS ONE # | ||
########################################### | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
|
||
#### Integrations | ||
|
||
##### Investigation & Response | ||
|
||
Added support for flexible close-reason mapping in `handle_outgoing_issue_closure` in `CoreIRApiModule`. Does not affect this module. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this comment is redundant