fix: 7.2.5 aligned with test-template
This commit is contained in:
@@ -1,11 +1,14 @@
|
|||||||
function Test-SharePointGuestsItemSharing {
|
function Test-SharePointGuestsItemSharing {
|
||||||
[CmdletBinding()]
|
[CmdletBinding()]
|
||||||
param (
|
param (
|
||||||
|
# Aligned
|
||||||
# Define your parameters here
|
# Define your parameters here
|
||||||
)
|
)
|
||||||
|
|
||||||
begin {
|
begin {
|
||||||
# Initialization code
|
# Dot source the class script if necessary
|
||||||
|
#. .\source\Classes\CISAuditResult.ps1
|
||||||
|
# Initialization code, if needed
|
||||||
|
|
||||||
$auditResult = [CISAuditResult]::new()
|
$auditResult = [CISAuditResult]::new()
|
||||||
}
|
}
|
||||||
@@ -19,7 +22,6 @@ function Test-SharePointGuestsItemSharing {
|
|||||||
$auditResult.CISControlVer = "v8"
|
$auditResult.CISControlVer = "v8"
|
||||||
$auditResult.CISControl = "3.3"
|
$auditResult.CISControl = "3.3"
|
||||||
$auditResult.CISDescription = "Configure Data Access Control Lists"
|
$auditResult.CISDescription = "Configure Data Access Control Lists"
|
||||||
|
|
||||||
$auditResult.Rec = "7.2.5"
|
$auditResult.Rec = "7.2.5"
|
||||||
$auditResult.ELevel = "E3"
|
$auditResult.ELevel = "E3"
|
||||||
$auditResult.ProfileLevel = "L2"
|
$auditResult.ProfileLevel = "L2"
|
||||||
@@ -27,7 +29,6 @@ function Test-SharePointGuestsItemSharing {
|
|||||||
$auditResult.IG2 = $true
|
$auditResult.IG2 = $true
|
||||||
$auditResult.IG3 = $true
|
$auditResult.IG3 = $true
|
||||||
$auditResult.RecDescription = "Ensure that SharePoint guest users cannot share items they don't own"
|
$auditResult.RecDescription = "Ensure that SharePoint guest users cannot share items they don't own"
|
||||||
|
|
||||||
$auditResult.Result = $isGuestResharingPrevented
|
$auditResult.Result = $isGuestResharingPrevented
|
||||||
$auditResult.Details = "PreventExternalUsersFromResharing: $isGuestResharingPrevented"
|
$auditResult.Details = "PreventExternalUsersFromResharing: $isGuestResharingPrevented"
|
||||||
$auditResult.FailureReason = if (-not $isGuestResharingPrevented) { "Guest users can reshare items they don't own." } else { "N/A" }
|
$auditResult.FailureReason = if (-not $isGuestResharingPrevented) { "Guest users can reshare items they don't own." } else { "N/A" }
|
||||||
|
Reference in New Issue
Block a user