mirror of
https://github.com/Yamato-Security/WELA.git
synced 2026-10-07 23:14:45 +02:00
Reject unknown CLI arguments before legacy command dispatch
This commit is contained in:
1 parent
6d228fedef
commit
4df3bb4c79
7 files changed
+120
No files matched your search
@@ -0,0 +1,35 @@
|
||||
name: Public CLI unknown argument rejection
|
||||
on:
|
||||
push:
|
||||
branches: ['**']
|
||||
pull_request:
|
||||
workflow_dispatch:
|
||||
permissions:
|
||||
contents: read
|
||||
jobs:
|
||||
cli-arguments:
|
||||
timeout-minutes: 15
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: [windows-2022, windows-2025]
|
||||
engine: [powershell, pwsh]
|
||||
runs-on: ${{ matrix.os }}
|
||||
steps:
|
||||
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
|
||||
- name: Windows PowerShell 5.1 process and native state checks
|
||||
if: matrix.engine == 'powershell'
|
||||
shell: powershell
|
||||
run: ./tests/CliArguments.Tests.ps1
|
||||
- name: PowerShell 7 process and native state checks
|
||||
if: matrix.engine == 'pwsh'
|
||||
shell: pwsh
|
||||
run: ./tests/CliArguments.Tests.ps1
|
||||
- name: Retain native before and after observations
|
||||
if: always()
|
||||
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02
|
||||
with:
|
||||
name: cli-arguments-${{ matrix.os }}-${{ matrix.engine }}
|
||||
path: ${{ runner.temp }}/wela-cli-arguments.json
|
||||
if-no-files-found: error
|
||||
retention-days: 7
|
||||
Reference in new issue
Block a user