| ▲ | llmslave2 4 hours ago | |||||||||||||
If one relies on the JS ecosystem to put food on the table and can't realistically make changes at their job to mitigate this, short of developing on a second airgapped work-only computer what can developers do to at least partially mitigate the risk? I've heard others mention doing all development in docker containers. Perhaps using a Linux VM? | ||||||||||||||
| ▲ | ryanto 4 hours ago | parent | next [-] | |||||||||||||
I run incus os, which is an operating system that is made for spinning up containers and VMs. Whenever I have to work on a JS project I launch a new container for development and then ssh into it from my laptop. You can also run incus on your computer without installing it as an operating system. Containers still have some risk since they share the host kernel, but they're a pretty good choice for protection against the types of attacks we see in the JS ecosystem. I'll switch to VM's when we start seeing container escape exploits being published as npm packages :) When I first started doing development this way it felt like I was being a bit too paranoid, but honestly it's so fast and easy it's not at all noticeable. I often have to work on projects that use outdated package managers and have hundreds of top-level dependencies, so it's worth the setup in my opinion. | ||||||||||||||
| ||||||||||||||
| ▲ | no-name-here 3 hours ago | parent | prev | next [-] | |||||||||||||
But none of those would have helped in this case, where each dev/user intentionally installed the package specifically so it could retrieve data from the WhatsApp API. What would have helped is if the dev/user had the ability for the dev/user to confirm before the code connected to a new domain or IP - api.WhatsApp.com? Approve. JoesServer.com or a random IP? Block. Such functionality could be at the OS or Docker level, etc. | ||||||||||||||
| ▲ | Gigachad 3 hours ago | parent | prev | next [-] | |||||||||||||
Some companies mandate that npm packages have to be x months old. Which gives time for this stuff to be discovered. | ||||||||||||||
| ▲ | morshu9001 4 hours ago | parent | prev [-] | |||||||||||||
If you're distributing something that uses this package, it's not just your dev computer at risk, it's all the users. | ||||||||||||||
| ||||||||||||||