cisagov / ScubaGear

Automation to assess the state of your M365 tenant against CISA's baselines
https://www.cisa.gov/resources-tools/services/secure-cloud-business-applications-scuba-project
Creative Commons Zero v1.0 Universal
1.69k stars 222 forks source link

Dolphin release candidate testing - Defender Product Assessment Sanity Testing #179

Closed nanda-katikaneni closed 1 year ago

nanda-katikaneni commented 1 year ago

πŸ’‘ Summary

In preparation of releasing the Dolphin or v0.3.0 of ScubaGear code, conduct sanity testing of the Defender product. Objective and Scope of the task are provided below.

Objectives:

  1. There are no regression issues in the Defender product assessments with Dolphin Release
  2. Additional sanity testing to ensure that: each policy assessment result is shown in the report, assessment works against all available tenants (G5/E5, G3/E3)
  3. Defender product assessment works both in interactive and non-interactive (service principal) modes.

Scope:

  1. Detailed functional testing of each policy statement result is out of scope
  2. Consistent results between interactive/non-interactive modes and no operational issues in running the test against all tenant types are within the scope.

Motivation and context

This would be useful to ensure that Dolphin release is stable

Implementation notes

Before the test, ensure that test user has minimum user role on a given tenant to assess Defender (look into README). Then, execute the Defender product assessment on all available tenants – first in interactive mode and then in non-interactive mode. After the test verify the following

  1. Verify that all tests run without errors and results reports are generated. Each policy has a result (no empty results)
  2. Ensure that there are no regressions from Coral release – for the tested tenant compare the result report from current assessment against saved Coral release results - ensure that any different result is consistent with code change (provide a detailed explanation on any observed diff in results)

Acceptance criteria

  1. Defender product assessment works in both interactive and non-interactive mode against G5, E5, G3 and E3 tenants.
  2. There are no crashes and/or empty results
  3. Results are consistent with Coral release assessment results - any diff is consistent with code changes.
ssatyapal123 commented 1 year ago

G5 results are as expected based on the policy settings, with one error due to known issue. MSFT deprecated the two alert policies the Rego is checking for. As we called out the alert policies in the baseline, this requires a baseline update and a rego update. This will addressed during Emerald. image

ssatyapal123 commented 1 year ago

To confirm policy changes are properly working, ran a quick test on two policies on Commercial E5 tenant:

image

Before: image

After: image

nanda-katikaneni commented 1 year ago

After further discussions with Shanti, seems like the Policy 2.2 result for E5 is same in v0.2.1 as well. So there is no regression with Dolphin. On 'why it is failing when it is expected to pass' - it will be investigated further and if needed a separate issue will be opened for a future release.