Merge branch 'main' of https://github.com/finos/FDC3-Sail #93
This file contains hidden or 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: Node.js CVE Scanning | ||
|
Check failure on line 1 in .github/workflows/cve-scanning.yml
|
||
| on: | ||
| pull_request: | ||
| paths: | ||
| - "**/package.json" | ||
| - "**/package-lock.json" | ||
| - ".github/workflows/cve-scanning.yml" | ||
| push: | ||
| branches: [main] | ||
| paths: | ||
| - "**/package.json" | ||
| - "**/package-lock.json" | ||
| - ".github/workflows/cve-scanning.yml" | ||
| schedule: | ||
| # Run every day at 5am and 5pm | ||
| - cron: "0 5,17 * * *" | ||
| permissions: | ||
| contents: read | ||
| jobs: | ||
| audit: | ||
| runs-on: ubuntu-latest | ||
| # setup-node cache: npm needs Actions cache write (and read via the same token scope) | ||
| permissions: | ||
| contents: read | ||
| actions: write | ||
| strategy: | ||
| matrix: | ||
| node-version: [24.x] | ||
| steps: | ||
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd #v6.0.2 | ||
| - name: Use Node.js ${{ matrix.node-version }} | ||
| uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e #v6.4.0 | ||
| with: | ||
| node-version: ${{ matrix.node-version }} | ||
| cache: npm | ||
| - run: npm ci | ||
| - name: NPM security audit | ||
| run: npm audit --audit-level=high | ||
| # OSS Index requires a free account + token since auth enforcement (Sonatype). | ||
| # Repo secrets: OSS_INDEX_USERNAME, OSS_INDEX_TOKEN — https://ossindex.sonatype.org/ | ||
| - name: Sonatype OSS Index audit | ||
| if: ${{ secrets.OSS_INDEX_USERNAME != '' && secrets.OSS_INDEX_TOKEN != '' }} | ||
| run: npx --yes auditjs ossi -u "${{ secrets.OSS_INDEX_USERNAME }}" -p "${{ secrets.OSS_INDEX_TOKEN }}" | ||