Earlier quoted context omitted.
Not sure what this means. bubblewrap is as free as it gets, it's just a thin wrapper around the same kernel mechanisms used for containers, except that it uses your existing filesystems instead of creating a separate "chroot" from an OCI image (or something like it). The only thing it does is hiding most of your system from the stuff that runs under it, whitelisting specific paths, and optionally making them readonly…
It means that someone just has to compromise bubblewrap instead of the other vectors.
Malicious versions of Nx and some supporting plugins were published
421–430 of 460 posts
Re: Malicious versions of Nx and some supporting plugins were published
#422Re: Malicious versions of Nx and some supporting plugins were published
#423Earlier quoted context omitted.
Do you review the 10k+ lines of generated bash in ./configure, too?
./configure shouldn't be in your repo unless it's handwritten
Theoretically you should be able to generate the configuration scripts through "autoconf" (or autoreconf), or generate Makefile.in for configure from Makefile.am using "automake", etc.
Re: Malicious versions of Nx and some supporting plugins were published
#424Earlier quoted context omitted.
And do you know what type of code the LLM was trained on? How do you know its sources were not compromised?
Why do I need to know that if I'm an experienced developer and I know exactly what the code is doing? The code is trivial, just print stuff to stdout along with escape sequences to update output.
Re: Malicious versions of Nx and some supporting plugins were published
#425Periodic reminder to disable npm install scripts. npm config set ignore-scripts true [--global] It's easy to do both at project level and globally, and these days there are quite few legit packages that don't work without them. For those that don't, you can create a separate installation script to your project that cds into that folder and runs their install-script. I know this isn't a silver bullet solution to suppl…
At this point why not just avoid npm (and friends) like the plague? Genuinely curious.
Re: Malicious versions of Nx and some supporting plugins were published
#426Periodic reminder to disable npm install scripts. npm config set ignore-scripts true [--global] It's easy to do both at project level and globally, and these days there are quite few legit packages that don't work without them. For those that don't, you can create a separate installation script to your project that cds into that folder and runs their install-script. I know this isn't a silver bullet solution to suppl…
Why the same advice doesn't apply to `setup.py` or `build.rs`? Is it because npm is (ab)used for software distribution (eg. see sibling comment: https://news.ycombinator.com/item?id=45041292 ) instead of being used only for managing library-dependencies?
Re: Malicious versions of Nx and some supporting plugins were published
#427Earlier quoted context omitted.
workspace protocol in monorepo is also great, we're using it a lot.
OK so it seems too good now, what are the downsides?
Re: Malicious versions of Nx and some supporting plugins were published
#428Earlier quoted context omitted.
Not "instead", it's "in addition to". Your classical defense-in-depth.
No, "instead". If they compromise bubblewrap to send out your files, and you run bubblewrap anyway for any reason, you're still compromised. But obviously you can probably safely pin bubblewrap to a given version, and you don't need to "install packages through it", which is the main weakness of package managers
Re: Malicious versions of Nx and some supporting plugins were published
#429Earlier quoted context omitted.
I also use bubblewrap to isolate npm/pnpm/yarn (and everything started by them) from the rest of the system. Let's say all your source code resides in ~/code; put this somewhere in the beginning of your $PATH and name it `npm`; create symlinks/hardlinks to it for other package managers: #!/usr/bin/bash bin=$(basename "$0") exec bwrap \ --bind ~/.cache/nodejs ~/.cache \ --bind ~/code ~/code \ --dev /dev \ --die-with-p…
Will this work on osX? and for pnpm?
Re: Malicious versions of Nx and some supporting plugins were published
#430Periodic reminder to disable npm install scripts. npm config set ignore-scripts true [--global] It's easy to do both at project level and globally, and these days there are quite few legit packages that don't work without them. For those that don't, you can create a separate installation script to your project that cds into that folder and runs their install-script. I know this isn't a silver bullet solution to suppl…
Because the workflow for 99.99% of developers is something resembling:
1. git clone
2. npm install (which pulls in a malicious dependency but disabling post-install scripts saved you for now!)
3. npm run (executing your malicious dependency, you're now infected)
The only way this advice helps you is if you also insert "audit the entirety of node_modules" in between steps 2 and 3 which nobody does.