Scan a batch of submitted add-ons with Virus Total #4
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Scan all submitted add-ons with Virus Total | |
on: | |
workflow_dispatch: | |
jobs: | |
virusTotal-analysis: | |
runs-on: windows-latest | |
strategy: | |
matrix: | |
python-version: [ 3.11 ] | |
permissions: | |
contents: read | |
issues: write | |
env: | |
VT_API_KEY: ${{ secrets.VT_API_KEY }} | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Install virusTotal | |
run: choco install vt-cli | |
- name: Install Node.js | |
uses: actions/setup-node@v2 | |
- name: Install glob | |
run: npm install glob | |
- name: Set Virus Total analysis status | |
id: setVirusTotalAnalysisStatus | |
uses: actions/github-script@v7 | |
with: | |
script: | | |
const setVirusTotalAnalysisStatus = require('./.github/workflows/virusTotalAnalysis.js') | |
setVirusTotalAnalysisStatus({core}, "./addons/*/*.json") | |
- name: Upload results | |
id: uploadResults | |
if: failure() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: VirusTotal | |
path: vt.json | |
overwrite: true | |
- name: Upload manual approval | |
id: uploadManualApproval | |
if: failure() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: manualApproval | |
path: reviewedAddons.json | |
overwrite: true |