Skip to content

Conversation

@thalurur
Copy link
Contributor

@thalurur thalurur commented Nov 4, 2021

Issue #, if available:
N/A

Description of changes:

  • Created security test to test the behavior of IM with users for different permissions.
  • The tests are not exhaustive yet, need to add more cases for transforms/rollups and verifying the actual action run in the policy for managed index
  • These tests are not currently run as part of the CI workflow but can be run locally by having a rest endpoint for security enabled cluster ./gradlew :integTest -Dtests.rest.cluster=localhost:9200 -Dtests.cluster=localhost:9200 -Dtests.clustername=opensearch -Dsecurity=true -Dhttps=true -Duser=admin -Dpassword=admin --tests "org.opensearch.indexmanagement.SecurityBehaviorIT"

CheckList:

  • 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.

@thalurur thalurur marked this pull request as draft November 4, 2021 00:29
@codecov-commenter
Copy link

codecov-commenter commented Nov 4, 2021

Codecov Report

Merging #184 (4b66875) into main (5ad90ff) will increase coverage by 0.20%.
The diff coverage is n/a.

❗ Current head 4b66875 differs from pull request most recent head d7bc7d5. Consider uploading reports for the commit d7bc7d5 to get more accurate results
Impacted file tree graph

@@             Coverage Diff              @@
##               main     #184      +/-   ##
============================================
+ Coverage     74.48%   74.68%   +0.20%     
- Complexity     1892     1899       +7     
============================================
  Files           260      260              
  Lines         11062    11093      +31     
  Branches       1736     1746      +10     
============================================
+ Hits           8239     8285      +46     
+ Misses         1888     1873      -15     
  Partials        935      935              
Impacted Files Coverage Δ
...nt/indexstatemanagement/model/destination/Chime.kt 40.90% <0.00%> (-13.64%) ⬇️
...earch/indexmanagement/transform/model/Transform.kt 87.00% <0.00%> (-0.50%) ⬇️
.../opensearch/indexmanagement/rollup/model/Rollup.kt 84.43% <0.00%> (+0.47%) ⬆️
...ndexstatemanagement/IndexStateManagementHistory.kt 78.67% <0.00%> (+1.47%) ⬆️
...dexmanagement/transform/model/TransformMetadata.kt 89.15% <0.00%> (+3.61%) ⬆️
...arch/indexmanagement/rollup/RollupSearchService.kt 64.81% <0.00%> (+5.55%) ⬆️
...action/removepolicy/TransportRemovePolicyAction.kt 61.67% <0.00%> (+10.20%) ⬆️
...ansform/action/explain/ExplainTransformResponse.kt 77.77% <0.00%> (+11.11%) ⬆️
...nt/indexstatemanagement/model/destination/Slack.kt 54.54% <0.00%> (+13.63%) ⬆️
...ndexmanagement/transform/model/ExplainTransform.kt 76.92% <0.00%> (+23.07%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5ad90ff...d7bc7d5. Read the comment docs.

@thalurur thalurur force-pushed the security-test branch 3 times, most recently from 4b66875 to c5bf026 Compare November 4, 2021 18:53
@thalurur thalurur force-pushed the security-test branch 2 times, most recently from 6f46a68 to 3cf54d5 Compare November 5, 2021 00:33
@thalurur thalurur marked this pull request as ready for review November 5, 2021 18:16
@bowenlan-amzn
Copy link
Member

I have one idea, can this test logic be same as what we are gonna show as an example in our public blog. i.e. could we have a written draft somewhere for an example of how to use this ISM security feature.

@bowenlan-amzn
Copy link
Member

Close in favor of #474

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.

3 participants