Connect with us

Hi, what are you looking for?

SecurityWeekSecurityWeek

Application Security

Supply Chain Attack Technique Spoofs GitHub Commit Metadata

Security researchers at Checkmarx are warning of a new supply chain attack technique that relies on spoofed commit metadata to add legitimacy to malicious GitHub repositories.

Security researchers at Checkmarx are warning of a new supply chain attack technique that relies on spoofed commit metadata to add legitimacy to malicious GitHub repositories.

Open source software helps developers create applications faster, and many of them may skip proper auditing of the third-party code if they believe it comes from a trustworthy source. For example, they may choose actively maintained GitHub repositories or ones that have reputable individuals as contributors.

According to Checkmarx, threat actors could forge some of the data associated with GitHub repositories to enhance their track record and make them more likely to be selected by application developers.

Specifically, the researchers discovered that one could tamper with commit metadata so that a repository would appear to be older than it actually is, or that reputable contributors have been involved in its maintenance.

Commits are essential to the Git version control system: they record changes made to files, when these changes were made, and who made them. Each commit has a unique ID, or hash.

According to Checkmarx, however, one can manipulate the timestamps associated with commits in such a manner that the timestamps listed on GitHub could predate the creation of both the user committing, and that of the repository the change was made to.

Fake commits can be automatically generated and are automatically added to the user’s GitHub activity graph, which could allow a malicious user to make it look as if they have been active on the code hosting platform for a very long time.

“Since the activity graph displays activity on both public and private repositories, it is impossible to discredit these fake commits and therefore this deception technique can be hard to detect as well,” Checkmarx says.

Advertisement. Scroll to continue reading.

Furthermore, the researchers discovered that the identity of the committer can be spoofed, to attribute the commit to a real GitHub account, such as a top contributor on the platform.

For that, a malicious user would need to retrieve the target account’s email address – which would normally be hidden, if the developer opted into the feature – and use specific commands to set the username and email in the Git CLI to those of the spoofed user. While this increases the reputation of the GitHub repository, the spoofed user is never notified of their name being used.

“To make their project look reliable, attackers can use this technique once or multiple times and populate their repository’s contributors section with known reliable contributors which in turn make the project looks trustworthy,” Checkmarx notes.

GitHub users can use the Commit Signature Verification feature to cryptographically sign their commits, but unsigned commits are not flagged.

According to Checkmarx, users can enable a ‘vigilant mode’, where the verification status of all of their commits is displayed, thus increasing the effectiveness of the feature.

“Fake metadata can mislead developers to use code they would knowingly not have used and can potentially encompass malicious code. The lack of validation of the committer identity and the commit’s timestamp is an issue by itself, but it also enables ill-wished actors to leverage it to gain credibility to their users and repositories,” Checkmarx concludes.

Related: Researchers Flag ‘Significant Escalation’ in Software Supply Chain Attacks

Related: Checkmarx Finds Threat Actor ‘Fully Automating’ NPM Supply Chain Attacks

Related: Software Supply Chain Attacks Tripled in 2021: Study

Written By

Ionut Arghire is an international correspondent for SecurityWeek.

Click to comment

Trending

Daily Briefing Newsletter

Subscribe to the SecurityWeek Email Briefing to stay informed on the latest threats, trends, and technology, along with insightful columns from industry experts.

Join the session as we discuss the challenges and best practices for cybersecurity leaders managing cloud identities.

Register

SecurityWeek’s Ransomware Resilience and Recovery Summit helps businesses to plan, prepare, and recover from a ransomware incident.

Register

Expert Insights

Related Content

Application Security

Cycode, a startup that provides solutions for protecting software source code, emerged from stealth mode on Tuesday with $4.6 million in seed funding.

Risk Management

The supply chain threat is directly linked to attack surface management, but the supply chain must be known and understood before it can be...

Cybersecurity Funding

2022 Cybersecurity Year in Review: Top news headlines and trends that impacted the security ecosystem

ICS/OT

The overall effect of current global geopolitical conditions is that nation states have a greater incentive to target the ICS/OT of critical industries, while...

Application Security

Virtualization technology giant VMware on Tuesday shipped urgent updates to fix a trio of security problems in multiple software products, including a virtual machine...

Application Security

Fortinet on Monday issued an emergency patch to cover a severe vulnerability in its FortiOS SSL-VPN product, warning that hackers have already exploited the...

Application Security

PayPal is alerting roughly 35,000 individuals that their accounts have been targeted in a credential stuffing campaign.