diff --git a/functions/datastore/.snyk b/functions/datastore/.snyk new file mode 100644 index 0000000000..b90aa7708f --- /dev/null +++ b/functions/datastore/.snyk @@ -0,0 +1,10 @@ +# Snyk (https://snyk.io) policy file, patches or ignores known vulnerabilities. +version: v1.14.1 +ignore: {} +# patches apply the minimum changes required to fix a vulnerability +patch: + SNYK-JS-LODASH-567746: + - '@google-cloud/datastore > google-gax > lodash': + patched: '2020-05-01T03:33:16.262Z' + - '@google-cloud/datastore > google-gax > @grpc/proto-loader > lodash': + patched: '2020-05-01T03:33:16.262Z' diff --git a/functions/datastore/package.json b/functions/datastore/package.json index 6236b96974..f201be7ef2 100644 --- a/functions/datastore/package.json +++ b/functions/datastore/package.json @@ -14,11 +14,14 @@ "scripts": { "e2e-test": "export FUNCTIONS_CMD='gcloud functions' && sh test/updateFunctions.sh && BASE_URL=\"https://$GCF_REGION-$GCLOUD_PROJECT.cloudfunctions.net/\" ava -T 20s --verbose test/*.test.js", "system-test": "export FUNCTIONS_CMD='functions' && sh test/updateFunctions.sh && BASE_URL=\"http://localhost:8010/$GCLOUD_PROJECT/$GCF_REGION\" ava -T 20s --verbose test/*.test.js", - "test": "npm run system-test" + "test": "npm run system-test", + "snyk-protect": "snyk protect", + "prepublish": "npm run snyk-protect" }, "dependencies": { "@google-cloud/datastore": "2.0.0", - "supertest": "^3.0.0" + "supertest": "^3.0.0", + "snyk": "^1.316.1" }, "devDependencies": { "@google-cloud/functions-emulator": "^1.0.0-beta.4", @@ -36,5 +39,6 @@ "GCF_REGION", "FUNCTIONS_CMD" ] - } + }, + "snyk": true }