mirror of
https://github.com/Yamato-Security/WELA.git
synced 2025-12-06 17:22:50 +01:00
update
This commit is contained in:
4
WELA.ps1
4
WELA.ps1
@@ -88,13 +88,15 @@ $rules = Get-ApplicableRules -outputFilePath $outputFilePath -jsonFilePath "./co
|
||||
$usableSecRules = $rules | Where-Object { $_.applicable -eq $true -and $_.channel -eq "sec" }
|
||||
$usablePwsRules = $rules | Where-Object { $_.applicable -eq $true -and $_.channel -eq "pwsh" }
|
||||
$unusableRules = $rules | Where-Object { $_.applicable -eq $false }
|
||||
$allSecRules = $rules | Where-Object { $_.channel -eq "sec" }
|
||||
|
||||
$totalCounts = Get-RuleCounts -rules $rules
|
||||
$totalSecCounts = Get-RuleCounts -rules $allSecRules
|
||||
$usableSecCounts = Get-RuleCounts -rules $usableSecRules
|
||||
$usablePwsCounts = Get-RuleCounts -rules $usablePwsRules
|
||||
|
||||
# Step 5: Calculate the Rate
|
||||
$usableSecRate = CalculateRate -counts $usableSecCounts -totalCounts $totalCounts
|
||||
$usableSecRate = CalculateRate -counts $usableSecCounts -totalCounts $totalSecCounts
|
||||
$usablePwsRate = CalculateRate -counts $usablePwsCounts -totalCounts $usablePwsCounts
|
||||
|
||||
# Step 6: Generate the required outputtotal
|
||||
|
||||
Reference in New Issue
Block a user