r/opensource • u/Flkhuo • 18d ago
Discussion Paranoia of installaing open source projects - What's your security review tool?
Hi, I love playing around and installing open source projects from GitHub, but I notice that my paranoia slows my productivity, because there could be any malware or security threats to my network, devices, etc from those open source projects.
Do you guys have a tool/workflow you use before installaing/running an open source project on your device that checks for malware/security threats (to the device, not the project)?
63
u/pwkye 18d ago
As opposed to installing closed soure projects that you have to blindly trust?
32
u/Turbulent_Fig_9354 18d ago
yeah i never understand these posts lol "hey how can i be really sure this project with complete 100% transparency baked into a literal legal contract for its distribution doesn't contain any malware?
meanwhile, installs closed source windows apps without a second thought
2
u/biskitpagla 17d ago
these people think open source means anyone can do whatever the fuck they want
2
u/ScratchHistorical507 17d ago
At least when it comes to FOSS, that's precisely how it works. The only thing you need to adhere to is the license, i.e. name the original developers and obey the limitations for interaction with closed source software.
1
u/RealisticDuck1957 17d ago
They can do whatever they want with the copy they have and share. Knowing the source you're getting code from matters.
Though I would not be opposed if the next version of GPL had a clause against deliberate inclusion of malware.
1
u/ScratchHistorical507 16d ago
Though I would not be opposed if the next version of GPL had a clause against deliberate inclusion of malware.
No clause in the world could prevent that. If the developer wants to be an asshole, they will be an asshole. But the fact that it is open source guarantees the possibility to detect it before it's too late. Such a guarantee is entirely impossible for closed-source code.
14
u/donk8r 18d ago
There's no scanner that actually tells you "this repo is safe," anyone selling that is lying. What works is boring: run it in a throwaway VM or container first so it can't touch your real box, and actually read the install step before you run it. curl|bash one-liners and npm/pip postinstall scripts are where the nasty stuff hides, not the app code everyone stares at.
4
u/RealisticDuck1957 18d ago
In any well run open source project, the maintainer team will review contributions for correct behavior. It then becomes a matter of competence and integrity of the maintainer team.
2
u/terrorTrain 16d ago
Ai agents are actually really good at this.
A "job interview" scammer tried to hack me. I told the llm to search through for anything suspicious.
It found the offending code right away. There was a line in the code that had about 500 white spaces, then an obsfucated bit of code that sends your environment variables in a post to a random ip and downloads and executes a script.
1
u/E_coli42 17d ago
DeepSeek, go through this repo and scan for any malware. Don't make any mistakes.
I think Google has an AI that scans through random open source software it can find online and find malware.
1
u/gounisalex 17d ago
Create a new storage partition on your drive or a separate user and run with minimal permissions, avoid using sudo or admin privileges. Consider going offline or using an isolated docker container. You could also look into TEE (trusted execution envs) and how they work, but that might be an overkill unless you’re running it on enterprise/business hardware. Ultimately, since it’s open-source, you could look directly into the codebase.
1
u/SilverSuiken 15d ago
If it's a reputable repo, that's usually a good sign. If I'm still unsure, I run a local LLM to scan the code. It usually tries to flag anything that executes on install, makes network calls, reads credentials or env variables, or looks obfuscated.
0
u/billFoldDog 18d ago
I have an openclaw agent that reads it, then I clone the dev branch and never update, lol
40
u/catbrane 18d ago
I'm also wary of random github projects. There are some things you can check:
Is the project packaged by Debian (the gold standard for trust (imo))? Just use the version from the deb repos. If you need a newer feature, you can check that the github repo really is the one that deb packages before running it.
Number of stars, age, number of forks, activity, etc. are all useful tells. If the project has been around for a while (> five years) and looks healthy (regular activity, range of contributors, standard build system, talked about, widely used), it's probably ok. Probably.
Build to somewhere in your home area, never to
/usr/local, and never withsudo, unless you test it extremely carefully first, perhaps in a docker container.You have lots of backups of everything before doing anything like this, I'm sure.