-
Notifications
You must be signed in to change notification settings - Fork 55
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
Palo Alto Cortex - Get Alerts: Fixed issue where trigger was failing due to empty output fields #2535
Merged
Conversation
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
igorski-r7
requested review from
cmcnally-r7,
ablakley-r7,
jerichardson-r7,
dlaverty-r7,
abmccann-r7,
joneill-r7,
ekelly-r7 and
rbowden-r7
May 17, 2024 09:06
rbowden-r7
approved these changes
May 17, 2024
ekelly-r7
approved these changes
May 17, 2024
cmcnally-r7
reviewed
May 22, 2024
links: | ||
- "[Palo Alto Cortex XDR](https://www.paloaltonetworks.com/cortex/cortex-xdr)" | ||
references: | ||
- "This plugin was tested using Viewer, Security Admin, and Instance Administrator Roles using both Standard and Advanced Security Levels. Please ensure your selected Role has adequate permissions to perform the desired actions." |
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.
Would this be better put in troubleshooting?
cmcnally-r7
reviewed
May 22, 2024
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.
.
ablakley-r7
force-pushed
the
develop
branch
2 times, most recently
from
June 3, 2024 08:59
0b37c27
to
7a4685a
Compare
joneill-r7
force-pushed
the
develop
branch
2 times, most recently
from
June 5, 2024 09:06
17bf76d
to
0ddb7a5
Compare
…due to empty or wrong typed output fields
igorski-r7
force-pushed
the
Palo_Alto_Cortex
branch
from
July 26, 2024 10:20
7d1c31c
to
cb7fb98
Compare
ablakley-r7
pushed a commit
that referenced
this pull request
Jul 29, 2024
…due to empty or wrong typed output fields (#2535)
ekelly-r7
pushed a commit
that referenced
this pull request
Jul 30, 2024
…due to empty or wrong typed output fields (#2535)
ablakley-r7
pushed a commit
that referenced
this pull request
Aug 12, 2024
…due to empty or wrong typed output fields (#2535)
joneill-r7
pushed a commit
that referenced
this pull request
Aug 12, 2024
…due to empty or wrong typed output fields (#2535)
ablakley-r7
pushed a commit
that referenced
this pull request
Aug 12, 2024
…due to empty or wrong typed output fields (#2535)
joneill-r7
pushed a commit
that referenced
this pull request
Aug 12, 2024
…due to empty or wrong typed output fields (#2535)
joneill-r7
pushed a commit
that referenced
this pull request
Aug 22, 2024
…due to empty or wrong typed output fields (#2535)
ablakley-r7
pushed a commit
that referenced
this pull request
Aug 27, 2024
…due to empty or wrong typed output fields (#2535)
rbowden-r7
pushed a commit
that referenced
this pull request
Aug 27, 2024
…due to empty or wrong typed output fields (#2535)
rbowden-r7
pushed a commit
that referenced
this pull request
Aug 28, 2024
…due to empty or wrong typed output fields (#2535)
igorski-r7
added a commit
that referenced
this pull request
Aug 28, 2024
…due to empty or wrong typed output fields (#2535)
17 tasks
ewilson-r7
pushed a commit
that referenced
this pull request
Aug 28, 2024
…due to empty or wrong typed output fields (#2535)
igorski-r7
added a commit
that referenced
this pull request
Aug 29, 2024
…due to empty or wrong typed output fields (#2535)
rbowden-r7
pushed a commit
that referenced
this pull request
Sep 3, 2024
…due to empty or wrong typed output fields (#2535)
igorski-r7
added a commit
that referenced
this pull request
Sep 5, 2024
…due to empty or wrong typed output fields (#2535)
rbowden-r7
pushed a commit
that referenced
this pull request
Sep 11, 2024
…due to empty or wrong typed output fields (#2535)
rbowden-r7
pushed a commit
that referenced
this pull request
Sep 11, 2024
…due to empty or wrong typed output fields (#2535)
rbowden-r7
pushed a commit
that referenced
this pull request
Sep 12, 2024
…due to empty or wrong typed output fields (#2535)
rbowden-r7
pushed a commit
that referenced
this pull request
Sep 18, 2024
…due to empty or wrong typed output fields (#2535)
ablakley-r7
pushed a commit
that referenced
this pull request
Sep 19, 2024
…due to empty or wrong typed output fields (#2535)
ablakley-r7
pushed a commit
that referenced
this pull request
Sep 19, 2024
…due to empty or wrong typed output fields (#2535)
cmcnally-r7
pushed a commit
that referenced
this pull request
Sep 23, 2024
…due to empty or wrong typed output fields (#2535)
ekelly-r7
pushed a commit
that referenced
this pull request
Sep 24, 2024
…due to empty or wrong typed output fields (#2535)
cmcnally-r7
added a commit
that referenced
this pull request
Oct 2, 2024
* Palo Alto Cortex - Get Alerts: Fixed issue where trigger was failing due to empty or wrong typed output fields (#2535) * [SOAR-17528] Palo alto Plugin Refresh (#2740) * SDK Bump * Reverting Version * Updating help.md * [SOAR-17529] Palo alto Cortex XDR Task (#2754) * Logging to find credential headers * test * Fix logging * Spec file refresh * start parse custom config * Successful API Call * Update checksum * Get Alerts * API Call & Custom Config * Some updates * Change limit to 7500 * Return total count * Get timestamp if max limit * Custom testing for pagination * Rough Draft for pagination & switching out get_alerts_two with a better method * Tidy up * Convert alert_time to right format * Convert alert_time to right format * Convert alert_time to right format * Filters * Organise methods & start making request in task.py * Making api call in task.py * Checkpoint * Add headers retrievla in task * It's working * Loads of logging and notes * Ryan checkpoint * Ryan fibannoci murphy * More logging * Setting states * Pagination * Unit test framework * More unit test progress * Task Connection Test * Black . * Some changes and unit testing * Removing a few logger lines/ print statements * Removing monitor_incident_event task * More refactoring * Filter's added + Working * custom config and sort by working * Exception handling improved, still needs minor tweaks * Unit tests * Add url back * Remove lots of comments in task | fix unit test * Some abtracting | refactoring * help.md/plugin.spec updated with SDK bump and examples added. Working through comments * Exception handling working. removed unused constants/lines * changing connection_version, CHECKSUM and reverting changed methods in apy.py to original (change not needed) * Refactoring & making datetime/epoch conversions cleaner and easier * Fix connection SCA * Pagination progress * trying to debug pagination error * Fix SCA in action, refactor request to be in api.py * Remove unused imports * Improve comments * Debugging * Conversion custom_config bug fix * Pagination issue resolved * Drop pagination state * Add len * has_more_pages flag set to false after finished paginating * Tidy a bit * ;-; * Now to fix up the state * Strip Empty Spaces when Inputting API Keys * Tidyed state management * Rename search state variables * Remove testing items and update comments * Fix sca * CHECKSUM FIX * Unit Test Test / Possible workaround? * Unit Test * Change import path for a unit test * Version change and unit test * unit test fixing in progress * strip removed for int * Rename state variables, remove total count from state * Fix pagination again * Woops remove print statement * Comment out unit test * Remove last hash alert from drop state * Change version back to 4.1.0, make connection version 4 * Improving state * Some comments addressed * Remove some repeated logging, add another safety check in api.py * Remove all new unit tests for task * Rename vars, improve logging * Fix pagination again * Streamline datetimes, improve logging * Change version back to 4.0.0 * Fix the spec file * Fixed Task Connection test (updated to new method and params) * Tidy datetime more * Done * Remove authenitcation error in api.py, change post body logging to debug * Datetime fixed * Simplfy task connection test, remove some things in error handling * Fix SCA * Remove logger in connection --------- Co-authored-by: rjmurray <[email protected]> * Update cloud enabled (#2809) * Reset offsets when changing lookback (#2811) * Reset offsets when changing lookback * Reset query endtime back to now * Make it store the int not the datetime object * Pop last search to * Add default none incase of key error * Update pop * Palo Alto | Update error to return error.data (#2823) * Update error to return error.data * Remove print statements * Wrap it in a plugin exception * Palo Alto Cortex XDR - 17008 - Get Alerts: Fixed issue with triggers output validation (#2824) * Rename response to new response * Take headers away from initialisation (#2827) * Palo Alto | Fix start time moving bug, Refactor dedupe logic (#2833) * Add logging for final page, Ensure start & end time are fixed when paginating * Add now time into get alerts * End time and start time static again * Refactor dedupe logic * Remove custom config * Update SDK * Update checksum for task schema --------- Co-authored-by: igorski-r7 <[email protected]> Co-authored-by: rmurray-r7 <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Proposed Changes
Description
Describe the proposed changes:
Get Alerts
: Fixed issue where trigger was failing due to empty output fieldsPR Requirements
Developers, verify you have completed the following items by checking them off:
Testing
Unit Tests
Review our documentation on generating and writing plugin unit tests
In-Product Tests
If you are an InsightConnect customer or have access to an InsightConnect instance, the following in-product tests should be done:
Style
Review the style guide
USER nobody
in theDockerfile
when possiblerapid7/insightconnect-python-3-38-slim-plugin:{sdk-version-num}
andrapid7/insightconnect-python-3-38-plugin:{sdk-version-num}
insight-plugin validate
which callsicon_validate
to linthelp.md
Functional Checklist
tests/
directory created withinsight-plugin samples
tests/$action_bad.json
insight-plugin run -T tests/example.json --debug --jq
insight-plugin run -T all --debug --jq
(use PR format at end)insight-plugin run -R tests/example.json --debug --jq
insight-plugin run --debug --jq
(use PR format at end)Assessment
You must validate your work to reviewers:
insight-plugin validate
and make sure everything passesinsight-plugin run -A
. For single action validation:insight-plugin run tests/{file}.json -A
insight-plugin ... | pbcopy
) and paste the output in a new post on this PR