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

Make it so that the scubagoggles reports link to the baselines #323

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

jfevang
Copy link
Collaborator

@jfevang jfevang commented Jun 21, 2024

πŸ—£ Description

Make it so that the control group names in the report are links to their respective groups in the baseline.

Closes #200
Closes #312

πŸ’­ Motivation and context

Feature already present in ScubaGear. Nice to have feature, making it easier for users to learn more about the controls.

πŸ§ͺ Testing

Run ScubaGoggles to ensure HTML reports are created correctly with proper URL links for group titles.
Ensure that group reference URLs for control groups are included in ScubaResults.json file.

βœ… 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.

@jfevang jfevang added improvement This issue or pull request will add new or improve existing functionality Code Changes Required labels Jun 21, 2024
@jfevang jfevang requested review from buidav and adhilto June 21, 2024 15:15
@jfevang jfevang self-assigned this Jun 21, 2024
@jfevang jfevang linked an issue Jun 21, 2024 that may be closed by this pull request
1 task
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.

Overall looks great. Just one small thing.

scubagoggles/reporter/reporter.py Outdated Show resolved Hide resolved
@adhilto
Copy link
Collaborator

adhilto commented Jun 21, 2024

Also @jfevang I'm assuming you're leaving #312 for a separate PR?

@adhilto adhilto added this to the Coast milestone Jun 21, 2024
@jfevang
Copy link
Collaborator Author

jfevang commented Jun 21, 2024

@adhilto @buidav
Will work on #312 within same branch and notify reviewers when completed.

jfevang and others added 3 commits June 21, 2024 21:47
Co-authored-by: Alden Hilton <106177711+adhilto@users.noreply.github.com>
@jfevang
Copy link
Collaborator Author

jfevang commented Jun 22, 2024

@adhilto @buidav Completed work for #200 and #312. PR is ready for your review.

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. Just one final piece, I didn't notice this before but the spaces in the URLs are not properly encoded.

For example, instead of this:
https://github.com/cisagov/scubagoggles/tree/v0.2.0/baselines/Google Meet Minimum Viable Secure Configuration Baseline v0.2.md#4-External-Participants

The links should look like this:
https://github.com/cisagov/ScubaGoggles/blob/v0.2.0/baselines/Google%20Meet%20Minimum%20Viable%20Secure%20Configuration%20Baseline%20v0.2.md#4-External-Participants

@buidav buidav changed the title 200 make it so that the scubagoggles reports link to the baselines Make it so that the scubagoggles reports link to the baselines Jul 3, 2024
Comment on lines 323 to 324
group_reference_url = f'{SCUBA_GITHUB_URL}/blob/v0.2.0/baselines/'\
f'{full_name} Minimum Viable Secure Configuration Baseline v0.2.md#'\
Copy link
Collaborator

@buidav buidav Jul 3, 2024

Choose a reason for hiding this comment

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

perhaps pull both v0.2.0's out into their own variable?
This will make refactoring easier in the future for version bumps.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I went ahead and added variables for the baseline and tool versions for the URL

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Code Changes Required improvement This issue or pull request will add new or improve existing functionality
Projects
None yet
3 participants