Finally.
Upcoming breaking changes for npm v12
31–40 of 221 posts
Re: Upcoming breaking changes for npm v12
#32Looks good? But doesn't this just change the compromise window from first installation to first run?
"First run" doesn't exist for JavaScript libs used only in web apps. So for that entire class of packages this change makes them safe.
Re: Upcoming breaking changes for npm v12
#33Looks good? But doesn't this just change the compromise window from first installation to first run?
"First run" doesn't exist for JavaScript libs used only in web apps. So for that entire class of packages this change makes them safe.
There is plenty of malicious stuff you can do from the browser.
Re: Upcoming breaking changes for npm v12
#34Nice that they're following pnpm's lead on this after [checks watch]... 18 months?
Re: Upcoming breaking changes for npm v12
#35Looks good? But doesn't this just change the compromise window from first installation to first run?
I’m sure we’d all welcome your alternative and or superior proposals. Without that, this just comes across like unconstructive commentary. This moves the needle a little your proposals or the lack thereof don’t move it at all. So I’ll take this over nothing.
It's node + npm compatible and its permission system locks everything down by default.
If you know ahead of time, you can turn on which permissions something is supposed to have in the config file.
Or you can just not use a config file at all. Anytime it needs a permission: it asks you what it wants. You can say yes or no, and those are saved in the config file for next time. If you say no, the script throws an error where it tried to access something it didn't have permission for.
---
Example:
- My linter wants access to my file system?
- You can have read access to ./src/ts/
- My bundler wants read and write access to my file system? - You can have read access to ./src/ts and write access to ./build-output
- Huh, what's that? The bundler was trying to both read and write a file in ./src/ts?
- We don't want input files getting overwritten, that's a recipe for hard-to-diagnose race conditions. Looks like the permission system did more than just keep things secure, it's like a type system for IO.
- Oh, look at that, there was a very subtle bundler misconfig, let me fix that now. How long would that have existed if we didn't use deno...
- Oh what's this? An updated dependency I've been using for 6 months suddenly asking for access to my .env file, and asking to run curl in a separate process? How about "no". Why would a simple DOM utility dependency be asking for those permissions? Ah, looks like it was part of a credential stealing supply chain attack. Glad I wasn't using node.---
Addendum: Node now has a permission system, but it's broken by design so it's useless.
Re: Upcoming breaking changes for npm v12
#36Earlier quoted context omitted.
If you need a quick patch, you pass another parameter to turn off the 1 day. 1 day delay will prevent more problems than it makes.
so this parameter can be passed by the attackers also thus making your point pointless
Re: Upcoming breaking changes for npm v12
#37Earlier quoted context omitted.
I’m sure we’d all welcome your alternative and or superior proposals. Without that, this just comes across like unconstructive commentary. This moves the needle a little your proposals or the lack thereof don’t move it at all. So I’ll take this over nothing.
An idea might be to not just pin "package xyz allowed", but "package xyz postinstall allowed with hash ".
Together with a lockfile that does achieve "package xyz postinstall allowed with hash "
Re: Upcoming breaking changes for npm v12
#38didn't know npm was owned by github.. well, that explains things...
Re: Upcoming breaking changes for npm v12
#39Earlier quoted context omitted.
Breaking changes have had that tag for ages
Really? Retired? What does that even mean in this context, why not "breaking" or something else that suggests breaking change?
"retired" is probably a followup to functionality that was "deprecated".
I agree "breaking" would be clearer