-
-
Notifications
You must be signed in to change notification settings - Fork 100
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
Add Dialogs to ESC1 #189
Add Dialogs to ESC1 #189
Conversation
🦙 MegaLinter status:
|
Descriptor | Linter | Files | Fixed | Errors | Elapsed time |
---|---|---|---|---|---|
jscpd | yes | 21 | 2.02s | ||
editorconfig-checker | 6 | 1 | 0.25s | ||
markdownlint | 1 | 11 | 0.73s | ||
markdown-link-check | 1 | 8 | 2.85s | ||
✅ MARKDOWN | markdown-table-formatter | 1 | 0 | 0.76s | |
powershell | 5 | 4 | 10.29s | ||
✅ POWERSHELL | powershell_formatter | 5 | 0 | 7.15s | |
checkov | yes | 1 | 14.07s | ||
✅ REPOSITORY | gitleaks | yes | no | 0.9s | |
✅ REPOSITORY | git_diff | yes | no | 0.01s | |
✅ REPOSITORY | grype | yes | no | 19.99s | |
✅ REPOSITORY | secretlint | yes | no | 0.88s | |
✅ REPOSITORY | trivy | yes | no | 5.66s | |
✅ REPOSITORY | trivy-sbom | yes | no | 1.77s | |
✅ REPOSITORY | trufflehog | yes | no | 7.03s | |
cspell | 7 | 177 | 6.22s |
See detailed report in MegaLinter reports
Set VALIDATE_ALL_CODEBASE: true
in mega-linter.yml to validate all sources, not only the diff
Get-ADObject `$Object | Set-ADObject -Replace @{'msPKI-Enrollment-Flag' = 0} | ||
"@ | ||
} | ||
} |
This comment was marked as duplicate.
This comment was marked as duplicate.
Sorry, something went wrong.
# 5. Check the "Enroll" and/or "Autoenroll" boxes depending on your specific needs. | ||
# 6. Click OK. | ||
"@ | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The strict no-indent on here-strings makes it hard to keep track of which closing brace corresponds with which block. # end if ___
tags might be helpful for these two closing braces. But that's purely for code review and wouldn't make any functional difference.
@@ -19,14 +19,14 @@ function Update-ESC4Remediation { | |||
This function updates ESC4 remediations customized to the user's needs. | |||
|
|||
.EXAMPLE | |||
$Target = Get-Target |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is plural now?
@@ -83,6 +83,11 @@ Get-ADObject `$Object | Set-ADObject -Replace @{'msPKI-Enrollment-Flag' = 0} | |||
"@ | |||
Technique = 'ESC1' | |||
} | |||
|
|||
if ( $Mode -in @(1, 3, 4) ) { | |||
Update-ESC1Remediation -Issue $Issue |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Haven't tested, but I feel like you need to capture the updated remediation in $Issue before continuing to return $Issue at the end of the function. (And I could be totally wrong.) Should this be something like:
if ( $Mode -in @(1, 3, 4) ) {
$Issue = Update-ESC1Remediation -Issue $Issue
}
$Issue
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved with one question to catch me up and help me understand. :)
This PR adds a couple questions to Modes 1, 3 and 4 when an ESC1 is identified:
This should resolve #151. I decided ESC2s and ESC3s should always require Manager Approval.