Live data from Hacker News

Over 100k Infected Repos Found on GitHub

apiiro.com

81–90 of 187 posts

Re: Over 100k Infected Repos Found on GitHub

#81

As well as this being our regular reminder to be careful what you pull from public repositories and other sources, and to verify your dependency trees, it raises another question: If malware is massively prolific in public repos, how much does this affect LLMs and other automation tools that are trained using the contents of such resources? What are the chances that we'll see copilot & friends occasionally emit malwa…

This sounds like alarmist journalist talk. What “malware”, even subtle backdoors, are sneaking into the LLM-generated code used in a piece of software that’s actually worth a damn?

[deleted]

Re: Over 100k Infected Repos Found on GitHub

#82

As well as this being our regular reminder to be careful what you pull from public repositories and other sources, and to verify your dependency trees, it raises another question: If malware is massively prolific in public repos, how much does this affect LLMs and other automation tools that are trained using the contents of such resources? What are the chances that we'll see copilot & friends occasionally emit malwa…

It's a risk. Similar to the risk that if you accept PRs from coworkers without reviewing them they might have copied and pasted in some vulnerable code from somewhere.

Using LLMs means investing more effort in code review. I think that's a worthwhile trade.

Re: Over 100k Infected Repos Found on GitHub

#83

This sounds solvable with some kind of painful to write and test heuristic tool. Something like "find other repos with similar product names and similar code but no forking audit trail" ... If you do an automated code diff and find it's involving say, posting stuff to a server, you can become suspicious. All these signals can become rather shallow with the right tooling centralizing this would make it a bit more effi…

To do so Microsoft needs to act as the strong man with a heavy hammer.

Re: Over 100k Infected Repos Found on GitHub

#84

Github is failing the same way usenet failed: everybody could post stuff to usenet just like everybody can create a github repository and there is nothing that sets an official repository apart from a spammers repository. When Amazon has "the everything store" as main strategic goal, they get hit by "90% of everything is junk". So they end up being a store of mostly junk. Github should figure out if their product is…

> Github should figure out if their product is "a repository for everybody" or it is "I can trust this code".

I'm pretty sure they decided on "repository for everybody" when they first launched the company 16 years ago.

Re: Over 100k Infected Repos Found on GitHub

#85

As well as this being our regular reminder to be careful what you pull from public repositories and other sources, and to verify your dependency trees, it raises another question: If malware is massively prolific in public repos, how much does this affect LLMs and other automation tools that are trained using the contents of such resources? What are the chances that we'll see copilot & friends occasionally emit malwa…

This is more likely than one would think, given such a large amount of samples as detected in this campaign. But there are at least 2 main barriers of an actual incident:

1. Internal instructions telling the generator to avoid exactly that. We wouldn't want to rely on this alone though.

2. Due to LLMs nature, it's unlikely that such generated malicious code would repeat addresses of actual malicious actors. This still leaves a variety of attack vectors such as bind shell, dos, on-site exfiltration, and more.

Re: Over 100k Infected Repos Found on GitHub

#86

As well as this being our regular reminder to be careful what you pull from public repositories and other sources, and to verify your dependency trees, it raises another question: If malware is massively prolific in public repos, how much does this affect LLMs and other automation tools that are trained using the contents of such resources? What are the chances that we'll see copilot & friends occasionally emit malwa…

I'm less worried about backdoors accidentally appearing in LLM output and more worried about backdoors being placed into LLM output by 3 letter agencies. Maybe not today, but certainly in a few years time.

Re: Over 100k Infected Repos Found on GitHub

#88
Wonder if the whole curl + sudo shell script installer thing is going to come to an end any time soon?

aka the whole "just run 'curl https://somesite/install.sh' | sudo sh" to install our software

Seems like it'd go very hand in hand with this infected stuff mentioned in the article.

Re: Over 100k Infected Repos Found on GitHub

#89
post #74

Earlier quoted context omitted.

I don't think you truly grasp how small this number is, this is actually good, like really really good. Github has about half a billion repositories.

Getting the actual number is probably very hard. These are the infected repos the OP found during their research.

For public repos you can get an approximate number by querying various public datasets.

    SELECT uniqHLL12(repo_name) FROM github_events;
Against https://play.clickhouse.com/play?user=play#U0VMRUNUIHVuaXFIT... returns:

    361648383

Re: Over 100k Infected Repos Found on GitHub

#90

Github is failing the same way usenet failed: everybody could post stuff to usenet just like everybody can create a github repository and there is nothing that sets an official repository apart from a spammers repository. When Amazon has "the everything store" as main strategic goal, they get hit by "90% of everything is junk". So they end up being a store of mostly junk. Github should figure out if their product is…

I don't think you truly grasp how small this number is, this is actually good, like really really good. Github has about half a billion repositories.

Not only that, millions of these type of repos get created, and the vast majority are caught and deleted. The article mentions this: "Most of the forked repos are quickly removed by GitHub, which identifies the automation. However, the automation detection seems to miss many repos, and the ones that were uploaded manually survive. Because the whole attack chain seems to be mostly automated on a large scale, the 1% that survive still amount to thousands of malicious repos."
Post reply on HN