From d30d8d0813dcd5d332fe4b15195fabcf01965f36 Mon Sep 17 00:00:00 2001 From: fukusuket <41001169+fukusuket@users.noreply.github.com> Date: Wed, 12 Mar 2025 09:05:44 +0900 Subject: [PATCH] update --- .github/workflows/check-audit.yml | 12 ++++++++++-- config/WELA.ps1 | 4 ++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/.github/workflows/check-audit.yml b/.github/workflows/check-audit.yml index 11d4f248..ef28188d 100644 --- a/.github/workflows/check-audit.yml +++ b/.github/workflows/check-audit.yml @@ -47,6 +47,14 @@ jobs: $duration = $endTime - $startTime Write-Output "Duration: $duration" - - name: Run + - name: Run WELA.ps1 run: | - ./config/WELA.ps1 \ No newline at end of file + ./config/WELA.ps1 + + - name: Output UsableRules.csv + run: | + Get-Content ./config/UsableRules.csv + + - name: Output UnUsableRules.csv + run: | + Get-Content ./config/UnusableRules.csv \ No newline at end of file diff --git a/config/WELA.ps1 b/config/WELA.ps1 index b9574013..9bb0bef9 100644 --- a/config/WELA.ps1 +++ b/config/WELA.ps1 @@ -93,5 +93,5 @@ $utilizationPercentage = "{0:N2}" -f (($totalUsable / $totalRulesCount) * 100) Write-Output "You can only utilize $utilizationPercentage% of your Security detection rules." # Step 7: Save the lists of usable and unusable rules to CSV files -$usableRules | Export-Csv -Path "UsableRules.csv" -NoTypeInformation -$unusableRules | Export-Csv -Path "UnusableRules.csv" -NoTypeInformation \ No newline at end of file +$usableRules | Select-Object title, level, id | Export-Csv -Path "UsableRules.csv" -NoTypeInformation +$unusableRules | Select-Object title, level, id | Export-Csv -Path "UnusableRules.csv" -NoTypeInformation