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

[#294, #295] Update Gmail policies 5 and 7 to include all instances of spoofing and authentication settings that are not complaint #394

Merged
merged 34 commits into from
Sep 11, 2024

Conversation

snarve
Copy link
Collaborator

@snarve snarve commented Sep 10, 2024

🗣 Description

Update Gmail policy 5 and 7 to include all settings related to spoofing and authentication that are not complaint

Closes #294
Closes #295
Closes #396
Closes #397

💭 Motivation and context

  • The current implementation reports the first failing setting for spoofing and authentication from policies 5 and 7
  • So in cases where multiple settings fail only one of them is reported instead of all
  • This update handles this use case so that all the failing settings are reported for both the policies

🧪 Testing

  • Test Gmail policies 5 and 9 (follow the baseline implementation steps)
  • Modify the settings for both the policies
  • Make more than one setting non-complaint, ie: leave it at the default value, so more than one setting is set to 'Keep in inbox'
  • The report should include all the settings that fail
  • Test the unit tests to confirm they pass

Policy 5 can be set as below:

image

Policy 7 can be set as below:

image

Report

image

image

✅ Pre-approval checklist

  • This PR has an informative and human-readable title.
  • Changes are limited to a single goal - eschew scope creep!
  • If applicable, All future TODOs are captured in issues, which are referenced in the PR description.
  • The relevant issues PR resolves are linked preferably via closing keywords.
  • All relevant type-of-change labels have been added.
  • I have read and agree to the CONTRIBUTING.md document.
  • These code changes follow cisagov code standards.
  • All relevant repo and/or project documentation has been updated to reflect the changes in this PR.
  • Tests have been added and/or modified to cover the changes in this PR.
  • All new and existing tests pass.

✅ Pre-merge Checklist

  • This PR has been smoke tested to ensure main is in a functional state when this PR is merged.
  • Squash all commits into one PR level commit using the Squash and merge button.

✅ Post-merge Checklist

  • Delete the branch to clean up.
  • Close issues resolved by this PR if the closing keywords did not activate.

@snarve snarve added this to the Coast milestone Sep 10, 2024
@snarve snarve self-assigned this Sep 10, 2024
@snarve snarve linked an issue Sep 10, 2024 that may be closed by this pull request
Copy link
Collaborator

@adhilto adhilto left a comment

Choose a reason for hiding this comment

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

Huge improvement over what we had before. Just a few things:

rego/Gmail.rego Outdated Show resolved Hide resolved
rego/Gmail.rego Outdated Show resolved Hide resolved
rego/Gmail.rego Outdated Show resolved Hide resolved
@snarve
Copy link
Collaborator Author

snarve commented Sep 11, 2024

Also, included the updates for #396 and #397 in this PR and branch since those were single line updates

Copy link
Collaborator

@adhilto adhilto left a comment

Choose a reason for hiding this comment

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

Nice work

Copy link
Collaborator

@LaurenBassett LaurenBassett left a comment

Choose a reason for hiding this comment

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

Much better. Thank you!

@adhilto adhilto merged commit 9a4bbc8 into main Sep 11, 2024
7 checks passed
@adhilto adhilto deleted the 75-gmail-76-logic-is-incomplete branch September 11, 2024 19:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants