diff --git a/.gitea/workflows/datastack-docker-ci.yml b/.gitea/workflows/datastack-docker-ci.yml index 1dde364..a6d6474 100644 --- a/.gitea/workflows/datastack-docker-ci.yml +++ b/.gitea/workflows/datastack-docker-ci.yml @@ -62,7 +62,7 @@ jobs: - name: Security backport applicability and behavioral proof run: | set -eu - npm ci --omit=dev --ignore-scripts --no-audit --no-fund + npm ci --no-audit --no-fund node <<'NODE' const fs = require('node:fs'), crypto = require('node:crypto'), assert = require('node:assert/strict'); const targets = { @@ -76,15 +76,13 @@ jobs: }; for (const [path, expected] of Object.entries(targets)) { const current = crypto.createHash('sha256').update(fs.readFileSync(path)).digest('hex'); - assert.equal(current, expected, 'locked package integrity mismatch: '+path); + if(path.includes('onezip/node_modules/glob/dist/commonjs/walker.js')) assert.equal(current,expected,'glob13 already guarded and should be unchanged: '+path); else assert.notEqual(current,expected,'security patch was not installed: '+path); } console.log('SECURITY_ORIGINAL_INSTALLED_SOURCE_INTEGRITY_PASS',Object.keys(targets).length); NODE for p in patches/cloudcmd-got-security.patch patches/cloudcmd-glob-security.patch patches/cloudcmd-minimatch-security.patch patches/cloudcmd-file-type-security.patch; do - git apply --check "$p" - git apply "$p" git apply --reverse --check "$p" - echo SECURITY_PATCH_APPLIED "$p" + echo SECURITY_PATCH_INSTALLED_AND_VERIFIED "$p" done node --check node_modules/got/dist/source/request-as-event-emitter.js node --check node_modules/glob/dist/commonjs/walker.js @@ -148,3 +146,5 @@ jobs: } main().catch(error=>{console.error('SECURITY_BACKPORT_PROOF_FAILED',error);process.exitCode=1}); NODE + npx --yes tsx@4.20.6 --test tests/files-manager.test.ts + echo SECURITY_CLEAN_INSTALL_AND_FM_REGRESSION_PASS