Uh oh!
There was an error while loading. Please reload this page.
Add snyk for npm package security - #841
Conversation
fhemberger
commented
Aug 9, 2016
/cc @nodejs/website Can we merge this one? Yay? Nay? |
lpinca
commented
Aug 9, 2016
I'm still -0. |
Starefossen
commented
Aug 10, 2016
What about nsp? |
guypod
commented
Aug 11, 2016
@Starefossen I believe the conversation here is primarily about fixing the issues, which - for these vulnerabilities - is only doable by using Snyk's patches. There are various other reasons to use Snyk over nsp for testing purposes (clearly I'm biased...), but either way nsp wouldn't help with the remediation discussed here. |
ghost
commented
Aug 11, 2016
i'd say merge it now to avoid security loopholes and contemplate on it later on. LGTM |
lpinca
commented
Aug 11, 2016
Did we ever try to see if we were actually affected by the minimatch vulnerability? |
lpinca
commented
Aug 11, 2016
Please correct me if I'm wrong but given I doubt we were vulnerable as I can't see how a malicious input could be provided to minimatch once the site was built. The site is static and once built is served via nginx. |
lpinca
commented
Aug 11, 2016
@guypod is running the wizard the only way to update the policy file? |
Starefossen
commented
Aug 11, 2016
Will snyk block/patch vulnerabilities automatically during runtine, or will we have to update the policy file and then redeploy?
|
guypod
commented
Aug 11, 2016
@lpinca the wizard is the only tool that automatically edits it, but you can manually edit it too. Format is probably self explanatory but happy to answer questions about it. You can also run |
guypod
commented
Aug 11, 2016
@Starefossen to patch, Snyk adds the By the time More details on our docs: https://snyk.io/docs/using-snyk/#protect |
guypod
commented
Aug 11, 2016
@Starefossen I realized I didn't explicitly answer your question: the short answer is you need to update the .snyk file, ensure you run |
This means updating the whole dependency tree and the policy file before each commit for us. Also I guess the policy file is based on the dependency tree so the npm version used for development must match with the npm version used on the remote server during the deployment phase. |
guypod
commented
Aug 11, 2016
@lpinca I might be missing something here... the .snyk file specifies a dependency path, and will only patch that. You can choose to include a more loose path (e.g. The patching happens each time you run In other words, there shouldn't be any need for you to refresh your deploys any more than you did before. You just need to ensure |
@guypod I may be the one missing something here 😄 but I'll try to clarify my thoughts.
|
guypod
commented
Aug 11, 2016
You're right that the solution is a moving target. Which is the reason we created Snyk :) My advice would be to "Watch" this project with Snyk (free for open source), and you'll get pull requests both on fixes to new vulns and (still a bit of a WIP) when a better remediation is made available. Maybe try that out? |
guypod
commented
Aug 11, 2016
@lpinca regarding the specific scenarios:
Makes sense? |
lpinca
commented
Aug 11, 2016
@guypod yes it does but AFAIK we can't grant access to the Synk application. See #821 (comment). As I see it, right now a lot of effort is necessary to keep the |
I second that @lpinca. Imho it looks like the work of maintaining an effective snyk configuration is greater than the received benefit. |
guypod
commented
Aug 11, 2016
@lpinca@phillipj can I ask what are the reason you don't want to integrate Snyk to the org? I understand you removed Greenkeeper, but Snyk is quite different, notably sending far fewer PRs (only vuln related ones) and has controls stating what you do and don't want reported on. Happy to do a quick hangout to talk through it if it's a bit much for GitHub comment conversation |
phillipj
commented
Aug 12, 2016
@guypod it's a nodejs org security policy to not add 3rd party github applications which requests private access. All the gh apps we have been wanting to add so far, has been asking for private access. It would be okey for us if we could setup a webhook against snyk manually for this repo alone, instead of org wide permissions. Would that be a possibility? P.S. we didn't turn off greenkeeper cause we wanted to, it required org wide permissions which we couldn't grant it. |
guypod
commented
Aug 13, 2016
@phillipj understood. What others have done to achieve this is to:
Snyk will then use only this user's token, and so will not have access to the private repos. Would this work here? |
This is a cleaned up version of #821. Please check the discussion over there.
/cc @nodejs/build