Skip to content
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

Security Analytics 2.7 Backports #938

Merged
merged 7 commits into from
Mar 19, 2024
Merged

Security Analytics 2.7 Backports #938

merged 7 commits into from
Mar 19, 2024

Conversation

toepkerd
Copy link
Contributor

Description

Backports #695 #722 #724 #873

  • Bump build version to 2.7.1
  • Fix build

Issues Resolved

[List any issues this PR will resolve]

Check List

  • New functionality includes testing.
    • All tests pass
  • New functionality has been documented.
    • New functionality has javadoc added
  • Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

goyamegh and others added 6 commits March 13, 2024 19:54
Signed-off-by: Megha Goyal <[email protected]>
* fix detector writeTo() method missing fields

Signed-off-by: Surya Sashank Nistala <[email protected]>

* fix test

Signed-off-by: Surya Sashank Nistala <[email protected]>

---------

Signed-off-by: Surya Sashank Nistala <[email protected]>
* fix null query filter conversion from sigma to query string query

Signed-off-by: Surya Sashank Nistala <[email protected]>

* fix rule to query conversion tests for null filter

Signed-off-by: Surya Sashank Nistala <[email protected]>

* enhance test to verify non null doc doesnt match null query

Signed-off-by: Surya Sashank Nistala <[email protected]>

---------

Signed-off-by: Surya Sashank Nistala <[email protected]>
Signed-off-by: Megha Goyal <[email protected]>

* Adding integ tests for empty mappings/aliases use-cases

Signed-off-by: Megha Goyal <[email protected]>

* Fix unit tests for MappingsTraverser

Signed-off-by: Megha Goyal <[email protected]>

---------

Signed-off-by: Megha Goyal <[email protected]>
…emove blocking actionGet() calls (#873)

* pass query field names in doc level queries during monitor creation/updation

Signed-off-by: Surya Sashank Nistala <[email protected]>

* remove actionGet() and change get index mapping call to event driven flow

Signed-off-by: Surya Sashank Nistala <[email protected]>

* fix chained findings monitor

Signed-off-by: Surya Sashank Nistala <[email protected]>

* add finding mappings

Signed-off-by: Surya Sashank Nistala <[email protected]>

* remove test messages from logs

Signed-off-by: Surya Sashank Nistala <[email protected]>

* revert build.gradle change

Signed-off-by: Surya Sashank Nistala <[email protected]>

---------

Signed-off-by: Surya Sashank Nistala <[email protected]>
@toepkerd toepkerd changed the title Backports 2.7 Security Analytics 2.7 Backports Mar 19, 2024
Copy link

codecov bot commented Mar 19, 2024

Codecov Report

Attention: Patch coverage is 5.66667% with 283 lines in your changes are missing coverage. Please review.

Project coverage is 27.77%. Comparing base (58c33a9) to head (e12f6fb).
Report is 1 commits behind head on 2.7.

Files Patch % Lines
...lytics/transport/TransportIndexDetectorAction.java 0.00% 278 Missing ⚠️
...search/securityanalytics/mapper/MapperService.java 0.00% 5 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##                2.7     #938      +/-   ##
============================================
- Coverage     28.09%   27.77%   -0.32%     
- Complexity      900      902       +2     
============================================
  Files           231      231              
  Lines          9341     9495     +154     
  Branches       1076     1081       +5     
============================================
+ Hits           2624     2637      +13     
- Misses         6481     6623     +142     
+ Partials        236      235       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

import org.opensearch.common.SetOnce;
import org.apache.lucene.util.SetOnce;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't think this was supposed to change. Not sure what the ramifications are

Signed-off-by: Dennis Toepker <[email protected]>
@toepkerd toepkerd marked this pull request as ready for review March 19, 2024 00:44
Copy link
Collaborator

@engechas engechas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code LGTM, approving. Will rerun the CIs to make sure they are just flaky

@engechas engechas merged commit 0f8369c into opensearch-project:2.7 Mar 19, 2024
6 of 15 checks passed
riysaxen-amzn pushed a commit to riysaxen-amzn/security-analytics that referenced this pull request Mar 25, 2024
…) (opensearch-project#938)

(cherry picked from commit e0b7a5a7905b977e58d80e3b9134b14893d122b0)

* remove unneeded import

---------






* Stashed user together with it's roles



---------







* Added workflow execution logic (opensearch-project#850)

* Added workflow execution logic



* Adjusted code according to comments



* Updated version of the findings json



* Updating the workflow metadata in the case of updating flag set to false while the metadata alerady exist



* Added logging for workflow metadata update



* Added Rest Execute Workflow action



* Extended workflow context with workflowMetadataId. Adjusted the doc level monitor findings



* Updated conditions for unstashing the context when indexing and deleting the workflow



---------



* Added fix when executing the workflow and when chained findings index… (opensearch-project#890)



* Fixed deleting monitor workflow metadata (#882)

* Fixed deleting monitor metadata and workflow metadata.




* fix monitor metadata error from conflict resolution



* remove unused import



* remove rest execute workflow action



* increment schema version for findings mapping json



---------

Signed-off-by: Stevan Buzejic <[email protected]>
Signed-off-by: Angie Zhang <[email protected]>
Signed-off-by: Ashish Agrawal <[email protected]>
Signed-off-by: Surya Sashank Nistala <[email protected]>
Co-authored-by: Stevan Buzejic <[email protected]>
Co-authored-by: Angie Zhang <[email protected]>
Co-authored-by: opensearch-trigger-bot[bot] <98922864+opensearch-trigger-bot[bot]@users.noreply.github.com>
Co-authored-by: Petar Dzepina <[email protected]>
Co-authored-by: Ashish Agrawal <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants