Skip to content

Commit

Permalink
Security Vulnerability Check on Release Tags Updated
Browse files Browse the repository at this point in the history
  • Loading branch information
semalaiappan committed Feb 19, 2024
1 parent acf7270 commit f3bdbbf
Showing 1 changed file with 2 additions and 18 deletions.
20 changes: 2 additions & 18 deletions .github/workflows/Security Vulnerability Check on Release Tags.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,29 +32,13 @@ jobs:
repository: Ed-Fi-Alliance-OSS/Ed-Fi-ODS
path: Ed-Fi-ODS/
ref: ${{ matrix.tag }}
- name: Install Visual Studio Build Tools
working-directory: ./Ed-Fi-ODS/
run: |
$url = "https://aka.ms/vs/2019/release/vs_buildtools.exe"
$output = "vs_buildtools.exe"
Invoke-WebRequest -Uri $url -OutFile $output
$expectedSize = (Invoke-WebRequest -Uri $url -Method Head).Headers.'Content-Length'
$actualSize = (Get-Item $output).length
if ($actualSize -ne $expectedSize) {
Write-Host "Download incomplete. Expected size: $expectedSize bytes, Actual size: $actualSize bytes"
exit 1
}
$installArgs = "--quiet --wait --norestart"
Start-Process -FilePath $output -ArgumentList $installArgs -Wait
- name: Execute vulnerability
working-directory: ./Ed-Fi-ODS/
run: |
$slnFiles = Get-ChildItem -Path . -Filter "*.sln" -Recurse
##| Where-Object { $_.Name -ne "EdFi.ProjectTemplates.sln" }
$slnFiles = Get-ChildItem -Path . -Filter "*.sln" -Recurse | Where-Object { $_.Name -ne "EdFi.ProjectTemplates.sln" }
foreach ($file in $slnFiles) {
dotnet restore $file.FullName
dotnet restore $file.FullName | Out-Null
dotnet list $file.FullName package --vulnerable 2>&1 | Tee-Object -FilePath "build.log" -Append | Out-Null
}
Expand Down

0 comments on commit f3bdbbf

Please sign in to comment.