There's basically no way to do this without trusting the redistributor in addition to the original publisher, but some things can reduce the amount of trust. Having a verifiable build process, that checks signing keys and hashes, that re-signs, etc, that all helps. If end-users can theoretically produce exactly the same build themselves it's easier to trust it.
The best option however is for the source project to produce unbranded builds themselves, and potentially for a project like VSCodium to become "config only" for things like disabling telemetry, and therefore not requiring re-signing. The Chromium project distributes its own Chromium binaries which lack the Google-specific stuff for example.
[^1]: Mostly thinking of app stores, but the same is basically true of things like Debian package repositories.
[^2]: App stores typically re-sign in the middle, so you do have to trust the store, but see (1), these companies go to great lengths to ensure trustworthiness there.
Really what much else could you ask for?
It only takes 1 trusted friend to verify the codebase, and from there it can spread. Luckily there are a lot of talented people on the Internet whom several people can vouch for, easy to find. It's pretty much a non-problem in the age of the Internet.
The same natural logic applies to anything else really... like cars - "yo what car do you trust?"
It's just the nature of living. If you don't have the skills, you need to find someone who does to trust. And no just because it comes from a company doesn't mean you can trust it, that's a fallacy. "Safety" doesn't necessary equate to "profits" which is what a business needs to live. It's an organism.
I don't think your car analogy quite fits, as there are ongoing updates, and it's not like the end-user perception of regular VSCode, or backdoored VSCode, are going to be any different until someone spots the backdoor (and we can't rely on that).
https://news.ycombinator.com/item?id=37261500
Why would a GitHub Action be worse? You're just telling me it is, asking me to believe that...
The car analogy is just that - you can break any analogy if you try. You've got a better one to help prove me right? :)
When I worked for one of the largest voting machine companies I was astounded how the final build process for the software was done just before it was sent to the customer. It was built on a Jenkins server that several people had access to change and update with minimal oversight and the devops person had freedom to do anything to with no oversight. For the year I worked there this one man could have changed dozens of elections if he chose to and figuring it out would have been very hard. I am sure a large enough investigation could could have figured out such a thing, but by then the damage would already be done. If he changed only municipal elections that couldn't affors such an investigation it might never have been done. I have no reason to claim this happened, but we certainly can't prove it didn't and this is in one of the most paranoid and regulated spaces in software development.
I don't know if other big tech is quite the same, but from the little I've heard, I suspect that Microsoft, Amazon, Apple, and others in that ilk are similar.
I'm very much in the camp of "trust but verify" here. You're right that Solar Winds was an utter disaster. It should never have been able to happen.
https://news.ycombinator.com/item?id=36979532 (Microsoft comes under blistering criticism for “grossly irresponsible” security)
The reason why organizations turn to other companies to deliver this is because there's a "throat to choke" for when things go wrong and a financial incentive to fix the inevitable issues when they come up.
For example, Microsoft recently "lost" (they didn't disclose what happened) some sort of authentication key that allowed Chinese hackers to break into their network: https://techcrunch.com/2023/07/17/microsoft-lost-keys-govern...
How does this even happen at a big company like Microsoft? Then you take a look at small, <100 people company, their security policies are much more strict than Microsoft's. And even if it happened the same way, we wouldn't have such high expectations because they have a small team.
Honestly, I prefer trusting a small project than a big company project. Take a look at Terraform now, HashiCorp pulled the plug and made it a proprietary app with source available requiring you to sign a CLA to prevent them from being sued later on. Red Hat is manipulating the GPL2 to force people to buy their subscriptions.
EDIT: how can we forget how GitHub was before Microsoft bought it in 2016? GitHub was much more friendly to open source and nowadays they just use any open source code available on their service to train their Copilot AI without respecting the terms of the licenses of the millions of projects hosted there. They killed Atom. They scan your private and public repos for "vulnerabilities". They literally read everything on your repo and feed it into Copilot. If GitHub wasn't sold, I'm pretty sure the situation would be different.
Call me crazy or dumb but I strongly believe that the bigger a company is, the worse their policies are. They neglect security at the cost of higher profits (ahem, looking at Facebook for allowing people to mine their users' data via an exploit that was just fixed when they called out Facebook for selling users' data).
I don't know if this is because Microsoft took down the blog posts and press releases or because Google web search sucks now (different conversation) but I had trouble finding the source for Microsoft statement. I'm talking about the incident when Microsoft spied into a user's hotmail email contents.
> However, to determine the identity of the leaker, CNET reveals, Microsoft actually looked through the Hotmail email of a French blogger who was in contact with the leaker, and make available online early copies of Windows 7 and Windows 8, as well as means that allowed users to circumvent activations protection for Microsoft and Windows.
https://bgr.com/general/microsoft-hotmail-and-outlook-privac...
I wouldn't give Microsoft any benefit of the doubt. While I have utmost respect for the people (who I know and) who work there, the senior leadership has always been poopy at best. I would never trust a word they say.
As Capricorn2481 points out though, suing isn't really on the cards for most individual.
lol.
It's unlikely that this project knowingly does shady stuff – I've heard of it before, seems to be a long running legit project – but there are lots of unverified factors in that, and the lack of signing (I think?) on the final binaries also means it's hard to know if they get tampered with at some other step.
That's the key value of open-source projects. You don't have to release a binary, just source code and a build guide. It's also one of the reasons why I have such high respect for OS distributions like BSDs and Slackware. They give you a good base that you can build upon if you know what you're doing.
The problem is, many PC users don't really know what they're doing.
I'd say most, even software engineers.
Can't tell you how many times I've had to explain how environmental variables work to developers, and that's a pretty simple concept compared to many other things in an operating system.
https://github.com/VSCodium/vscodium/blob/master/.github/wor...
- Downloads binaries for use in build with no hash/signing verification.
- Doesn't pin shared actions.
- Uses Yarn to install dependencies (which can involve downloading/executing arbitrary code from anywhere)
- Doesn't sign the final binary.
None of this is necessarily wrong, all would make maintenance harder in the long run, but it means this project is really about removing MS branding and some telemetry, and that there is a security trade-off to get those benefits.
> - Downloads binaries for use in build with no hash/signing verification.
It downloads them using TLS.
> - Doesn't pin shared actions.
The shared actions are just @actions/checkout and @actions/setup-node. They're official. I wouldn't pin them - YAGNI.
> - Uses Yarn to install dependencies (which can involve downloading/executing arbitrary code from anywhere)
It downloads/executes code based on the carefully chosen dependencies
> - Doesn't sign the final binary.
That's platform dependent I think. For Mac OS X it does.
Seems like FUD, which you might be able to recognize because you say "None of this is necessarily wrong". Especially the part about pinning first party GitHub Actions. There would be nothing wrong with that but it is much more useful to pin third party GitHub Actions, and IMHO suboptimal to pin first party actions.
I don't think it's quite FUD, but I do agree none of these are strictly necessary, all can be rationalised as unnecessary and for many users this project probably provides a perfectly reasonable security posture. However the fact that there's so little explicit acknowledgement of the security concerns, and that 2 minutes looking at the repo turned these things up, suggests that security is not a priority of the project. Again, not the wrong thing to do, but maybe not the trade-offs all users will want.
Pinning actions is so low effort/high reward that even the low risk makes it worth it for a project like this in my opinion. Official actions are certainly much safer, but ultimately it's still just human review and PRs being merged.
Downloading over TLS negates some impact of hash/signing verification, but it would be a nice extra layer. You're otherwise putting a lot of trust in the combination of DNS+CDN+Hosting. I've seen hijacked sites due to IPs being re-used on cloud providers for example. Unlikely, but again easy to do and high impact in the rare situation that is is taken advantage of.
Yarn dependencies may be carefully chosen, I'm not familiar with the VSCode practices. I bet that official binaries however are not built like this – I'd bet that there are allowances for specific network connectivity and binary execution, and that everything else is locked down. To my knowledge GitHub Actions have open internet access. I wouldn't even say this is low risk either, the NPM ecosystem is so deeply nested that I'm sure malicious code could be snuck in somewhere. This is a lot harder to solve for this project, and certainly the most debatable aspect as to whether it's worth it or not.
Are there any shared actions that aren't actions/name-of-project? If not, that's zero reward.
Malicious code with the correct checksum? VSCode team is not auto updating dependencies but I also doubt they are reviewing the source code of every package they update. I've never worked anywhere that does. So yeah, "gulp-vinyl-zip" (or any other package used at build time) could add some code that secretly triggers when run in the VSCode repository and makes some malicious source code changes. But, it's still going to be the same code in VSCode and VSCodium. Unless the attacker decides to use specific logic to target one or the other.
As for writing such a check manually, you would just need to check "bin" in */package.json after installing everything, and verify each script.
Trusting a big company seems to be another suggestion I see in this thread too. I don't agree with that one.
I think the idea MS has deployed this is over optimistic. Look at this with Google. https://giraffesecurity.dev/posts/google-remote-code-executi...
Also, it depends how determined your attacker is. If they write code to detect whether they're being installed in the vscode project, have access to commercially available security scanning tools to ensure they evade detection, etc...
>> - Downloads binaries for use in build with no hash/signing verification.
> It downloads them using TLS.
If the binary is updated to a shady version, sure, no one will be able to tamper with the download, they're certain to have received the correct shady stuff.
[1] Of course this includes ensuring it doesn't e.g. pull anything from the internet whose integrity you can't similarly guarantee...
I have absolutely 0 trust towards any big corp doing things properly, and not cramming the applications full of spyware in the name of telemetry. and i would rather trust a bunch of insane dedicated people trying to make FOSS software.
Reproducible builds would help here, like Go did for their newest SDK [1].
This would be particularly true for a fork when the source changes are fairly minimal, since you could just verify the patch.
Linux distros are fairly similar; why do we mostly trust Debian packages? Because there’s an umbrella organization and a process. That’s less true of a standalone organization.
Maybe eventually there will be an umbrella organization that just does reproducible builds, and people will use that to distribute binaries. (And independent verification could keep them honest, like happens with domain registrars.)
I don't assume that there won't be security holes, but in effect, I'm assuming they probably won't affect me.
I’m sure you could diff the source code the package used, and the upstream Microsoft git SHA it is claims to be derived from:
https://aur.archlinux.org/packages/vscodium
Incidentally, there is now an open source remote mode extension, so I have no reason to use the proprietary version. No more telemetry from me!
URL please? Open VSX lists several but it's hard to evaluate if they're complete & stable from just the READMEs. For example, https://github.com/xaberus/vscode-remote-oss has existed for a long time, but one would need to spend a few hours to know if it works well enough.
God bless the Arch User Repo. Stuff like this has made it impossible for me to move on from Arch.
I use vscodium either way, you need to get used to stuff like this from time to time.
So if there is a supply chain risk it's the same for VS Code
It's like buying your heart medication off an anonymous guy on Craigslist to stick it to big pharma.
The choice is obvious.
On first install:
- read AUR file
- audit build & patching framework
- audit patches
On upgrade:
- review patch changes
- treat upstream changes like you would otherwise
On upgrade with AUR file change:
- review AUR file changes
- review build & patching framework changes
If you've bothered to set up your own repos and build pipeline integrating your patches already (and you can get a lot of that for free), the additional overhead isn't as large as it may sound.vscodium is doing the much larger work of cross-checking vscode and in exchange I do the smaller work of cross-checking theirs - and putting in my own so I have zeroconf installs with prebundled extensions and whatnot on new machines.
Same for browser (ungoogled-chromium, vanadium, librewolf or whathaveyou)
I'm not worried about the government spying on me or ad tracking, I'm worried about a random hacker.
It's ironic that for a lot of people the concept of privacy has been inverted: The closer someone is to you the more we want to hide from them.
Facebook showing my online status to acquaintances(Or the lack of an online status, which could also create suspicion that I'm hiding something) bothers me more often than a random Google employee listening in through my alarm clock.
Most of the really scary big data possibilities seems more like political issues than data issues, the data is just something they could use to do the things people are worried about.
It's not great, but it's competing for mind share with a lot of other possibile horrors people are afraid of and people are rather fatigued.
The more subtle stuff they're already doing seems like it would be a problem with even the most basic data.
The biggest issue I see is personalized content which causes fights, hate, wasted time, and all that, because the algorithms want you to engage with it as much as possible, and it shits on real journalism by giving all the attention to clickbaits.
I suspect every time I've responded to such clickbaits might be more problematic than all the data they get from all my smart devices in a year...
Protecting one's privacy because of societal harm is a worthy thing but also a pretty big effort and I sure don't have a solution, or even any confident prediction of how big the problem is or where it's coming from...
But I probably won't truly be worried unless one of those horrid encryption bans gets close to passing.
Well, like you write, aggregated data is already being used to influence populations which makes it immediate. An hypothetical hacker is not.
> Most of the really scary big data possibilities seems more like political issues than data issues, the data is just something they could use to do the things people are worried about.
I don't follow. Not giving away the data removes the need for politics. Crime is illegal nevertheless it exists because it is possible to commit.
> It's not great, but it's competing for mind share with a lot of other possibile horrors people are afraid of and people are rather fatigued.
Not everyone shares the same concerns and nobody likes problems, that doesn't' mean they should be accepted.
> The more subtle stuff they're already doing seems like it would be a problem with even the most basic data.
All the more reason not to give them more. The personalized hate content is a direct consequence of big data aggregation.
All in all, seems like more of an issue than a possible compromise of a FOSS project.
So don’t lull yourself into thinking the supply chain on everything on your system is any better :) It’s likely substantially worse.
In reality I think distributions that are willing to ship binaries (NixOS, Homebrew on MacOS) ship VSCodium, and other distributions (Alpine) have packages called things like `code-oss` that are basically the distribution's internal compiled version of VSCode and have nothing (?) to do with VSCodium.
I'm afraid that such projects, with much less man power and skin in the game, are more vulnerable to supply chain attacks or a hostile takeover if a dev sells the project.
I'm not very knowledgeable in this area. Would someone contribute here some resources on how this is avoided in such projects? Or maybe my concerns are valid :)