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

Beginner Class Updates #261

Merged
merged 16 commits into from
Dec 4, 2024
Merged

Beginner Class Updates #261

merged 16 commits into from
Dec 4, 2024

Conversation

karikarshivani
Copy link
Contributor

No description provided.

Copy link

netlify bot commented Nov 26, 2024

Deploy Preview for mitre-saf-training ready!

Name Link
🔨 Latest commit 127c6a1
🔍 Latest deploy log https://app.netlify.com/sites/mitre-saf-training/deploys/675071c7bc9dae00083341ca
😎 Deploy Preview https://deploy-preview-261--mitre-saf-training.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 84 (🟢 up 3 from production)
Accessibility: 97 (no change from production)
Best Practices: 92 (no change from production)
SEO: 100 (no change from production)
PWA: -
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot reviewed 5 out of 9 changed files in this pull request and generated 1 suggestion.

Files not reviewed (4)
  • src/courses/beginner/05.md: Evaluated as low risk
  • src/courses/beginner/06.md: Evaluated as low risk
  • src/courses/beginner/09.md: Evaluated as low risk
  • src/courses/beginner/README.md: Evaluated as low risk
Comments skipped due to low confidence (4)

src/courses/beginner/10.md:191

  • [nitpick] Rephrase to 'Copying and pasting controls from a profile instead of creating an overlay can cause important updates to be missed.' for clarity.
Copying and pasting controls from a profile, instead of creating an overlay, can lead to important updates not being reflected.

src/courses/beginner/04.md:33

  • The target and target ID were truncated. They should be restored to their full values.
Target:    docker://31e4ea1be052a9bcc13700

src/courses/beginner/04.md:180

  • Corrected 'mutiline' to 'multiline'.
The InSpec shell understands the structure of blocks. This enables you to run multiline code. As an example, run the entire `describe` block like this which will run the entire block of code in the InSpec Shell and return the result.

src/courses/beginner/04.md:458

  • Corrected 'intalled' to 'installed'.
Check that the nginx package is installed, this time on the target container.

src/courses/beginner/04.md Show resolved Hide resolved
@aaronlippold aaronlippold requested a review from Copilot December 2, 2024 03:52
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot reviewed 5 out of 9 changed files in this pull request and generated 1 suggestion.

Files not reviewed (4)
  • src/courses/beginner/README.md: Evaluated as low risk
  • src/courses/beginner/09.md: Evaluated as low risk
  • src/courses/beginner/07.md: Evaluated as low risk
  • src/courses/beginner/03.md: Evaluated as low risk
Comments skipped due to low confidence (5)

src/courses/beginner/04.md:180

  • The word 'mutiline' is misspelled. It should be 'multiline'.
The InSpec shell understands the structure of blocks. This enables you to run mutiline code.

src/courses/beginner/04.md:458

  • The word 'intalled' is misspelled. It should be 'installed'.
Check that the nginx package is intalled, this time on the target container.

src/courses/beginner/05.md:352

  • [nitpick] The link text 'Secure your Infrastructure' should be 'Secure Your Infrastructure' to match the title case used in other parts of the document.
You won't correct this issue in this module, but later you can check out the Chef [Secure your Infrastructure](https://learn.chef.io/tracks/integrated-compliance#/) tutorial course to learn more about how to correct compliance failures using Chef.

src/courses/beginner/02.md:83

  • Changing 'tag' to 'desc' is incorrect. It should remain 'tag'.
desc "check", "To view the worker_processes directive value enter the

src/courses/beginner/02.md:96

  • Changing 'tag' to 'desc' is incorrect. It should remain 'tag'.
desc "fix", "Edit the configuration file and set the value of

@@ -105,7 +105,7 @@ control 'nginx-version' do
end
```

For our next control we require specific modules
The next control checks whether certain NGINX modules are installed. Inputs make it easy for us to define the modules that are requiured using the `inspec.yml` file. By setting this input, it enables us to easily reference these same values in other controls, if desired.
Copy link
Preview

Copilot AI Dec 2, 2024

Choose a reason for hiding this comment

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

The word 'requiured' is misspelled. It should be 'required'.

Suggested change
The next control checks whether certain NGINX modules are installed. Inputs make it easy for us to define the modules that are requiured using the `inspec.yml` file. By setting this input, it enables us to easily reference these same values in other controls, if desired.
The next control checks whether certain NGINX modules are installed. Inputs make it easy for us to define the modules that are required using the `inspec.yml` file. By setting this input, it enables us to easily reference these same values in other controls, if desired.

Copilot is powered by AI, so mistakes are possible. Review output carefully before use.

Positive Feedback
Negative Feedback

Provide additional feedback

Please help us improve GitHub Copilot by sharing more details about this comment.

Please select one or more of the options
Signed-off-by: Will <[email protected]>
Signed-off-by: Will <[email protected]>
Signed-off-by: Will <[email protected]>
@aaronlippold aaronlippold marked this pull request as ready for review December 4, 2024 05:58
src/courses/beginner/02.md Outdated Show resolved Hide resolved
src/courses/beginner/02.md Outdated Show resolved Hide resolved
src/courses/beginner/02.md Outdated Show resolved Hide resolved
src/courses/beginner/02.md Outdated Show resolved Hide resolved
src/courses/beginner/02.md Outdated Show resolved Hide resolved
@@ -139,7 +129,7 @@ When this flag is passed, the control level status outcomes of the profile execu

Copy link
Contributor

Choose a reason for hiding this comment

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

I think that the enhanced outcomes info should be in its own separate subsection. not a 'details' tab underneath the reporter flags. it should also be a little bit longer to elaborate what the difference is before/after (specifically before = pass/fail/err only whereas we likely also want to see the NA and NR separated out too). we should also say that most of our example inspec exec invocations don't use it due to the simplicity of the controls and in order to manage the length of the lines that need to be copy pasted, but in real world circumstances we'd expect folks to use this flag.

src/courses/beginner/10.md Outdated Show resolved Hide resolved
If there are only a handful of controls that should be executed from an included profile, it’s not necessary to skip all the unneeded controls, or worse, copy/paste those controls bit-for-bit into your profile.

:::warning Keep profiles in sync!
Copying and pasting controls from a profile, instead of creating an overlay, can lead to important updates not being reflected. Overlays keep the profile changes in sync as they pull the latest updates.
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
Copying and pasting controls from a profile, instead of creating an overlay, can lead to important updates not being reflected. Overlays keep the profile changes in sync as they pull the latest updates.
Copying and pasting controls from a profile, instead of creating an overlay, can lead to important updates from the upstream profile not being reflected in the new one. Overlays keep the profile changes in sync as they pull the latest updates from upstream before running.

@@ -8,42 +8,56 @@ headerDepth: 3

## From STIG to Profile

You have seen in some of our examples in this class that a robust profile's controls will include a large number of metadata tags:
Recall from our initial example of an InSpec control from the beginning of this class that a real control will be tied back to an upstream piece of security guidance documentation, like a CIS Benchmark or a STIG. This alignment is done by adding tags to the control code -- the more the better.
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
Recall from our initial example of an InSpec control from the beginning of this class that a real control will be tied back to an upstream piece of security guidance documentation, like a CIS Benchmark or a STIG. This alignment is done by adding tags to the control code -- the more the better.
Recall from our initial example of an InSpec control that a real control will be tied back to an upstream piece of security guidance documentation, like a CIS Benchmark or a STIG. All the context and metadata for that guidance can be added to the control's code via InSpec specific syntax.

src/courses/beginner/README.md Outdated Show resolved Hide resolved
karikarshivani and others added 3 commits December 4, 2024 08:33
Co-authored-by: Amndeep Singh Mann <[email protected]>
Signed-off-by: Shivani Karikar <[email protected]>
Co-authored-by: Amndeep Singh Mann <[email protected]>
Signed-off-by: wdower <[email protected]>
Co-authored-by: Amndeep Singh Mann <[email protected]>
Signed-off-by: wdower <[email protected]>
Co-authored-by: Amndeep Singh Mann <[email protected]>
Signed-off-by: wdower <[email protected]>
Co-authored-by: Amndeep Singh Mann <[email protected]>
Signed-off-by: wdower <[email protected]>
This was referenced Dec 4, 2024
Signed-off-by: Will <[email protected]>
@wdower wdower enabled auto-merge (squash) December 4, 2024 15:15
@wdower wdower merged commit 82cca9c into main Dec 4, 2024
9 checks passed
@wdower wdower deleted the dec24-beginner branch December 4, 2024 15:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants