Monday, April 28, 2025
HomeCyber Security NewsHackers Leveraging GitHub Platform for Hosting Malware

Hackers Leveraging GitHub Platform for Hosting Malware

Published on

SIEM as a Service

Follow Us on Google News

Researchers have discovered two novel techniques on GitHub: one exploits GitHub Gists, while the other involves sending commands through Git commit messages.

Malware authors will occasionally upload samples to services such as Dropbox, Google Drive, OneDrive, and Discord to host second-stage malware and avoid detection techniques.

Nevertheless, the threat research team at ReversingLabs has recently noticed a rise in the hosting of malware on the open-source development GitHub platform.

- Advertisement - Google News

Abusing GitHub Gists

Gists is a GitHub feature that allows developers to share code snippets easily. They can be shared publicly or privately.

“Secret gists don’t show up in Discover and are not searchable unless you are logged in and are the author of the secret gist. Secret gists aren’t private. If you send the URL of a secret gist to a friend, they’ll be able to see it”, reads Gists documentation.

They never make an appearance on the author’s GitHub profile page. This enables them to be used as a form of anonymous Pastebin service, which doesn’t trigger warning signs for an attacker.

“In this incident, several PyPI packages presented themselves as libraries for handling network proxying, and contained a Base64 encoded string, allegedly related to telemetry data, but containing a URL, pointing to a secret Gist”, ReversingLabs shared in a report with Cyber Security News.

To hide this string’s true purpose and make it more difficult for security technologies to flag it as suspicious, malware developers employed Base64 encoding. Before being sent over a network, binary data is frequently encoded using Base64 encoding.

Fetching and executing commands from a Base64 encoded URL
Fetching and executing commands from a Base64 encoded URL

The setup.py file contained hidden malicious code. The setup tools commands were extended to implement it.

Sending Commands Through git Commit Messages

Researchers discovered a sample in the easyhttprequest PyPI package that exploits characteristics of version control systems. Once more, the malicious code was built by extending the egg_info setuptools command and concealed it within the setup.py file.

“After installation on the victim’s machine, the malicious code from this package clones a specific git repository from GitHub and checks if the “head” commit of this repository contains a commit message that starts with a specific string”, researchers said.

Fetching and executing commands from a Base64 encoded commit message
Fetching and executing commands from a Base64 encoded commit message

Recommendation

Developers and application security teams must be able to distinguish between harmful and legitimate packages on these platforms, as attackers are getting more proficient in their malware deployment. 

For this reason, software developers should make use of cutting-edge tools that use intricate binary analysis to offer complete software supply chain security.

Gurubaran
Gurubaran
Gurubaran is a co-founder of Cyber Security News and GBHackers On Security. He has 10+ years of experience as a Security Consultant, Editor, and Analyst in cybersecurity, technology, and communications.

Latest articles

Obfuscation Techniques: A Key Weapon in the Ongoing War Between Hackers and Defenders

Obfuscation stands as a powerful weapon for attackers seeking to shield their malicious code...

React Router Vulnerabilities Allow Attackers to Spoof Content and Alter Values

The widely used React Router library, a critical navigation tool for React applications, has...

CISA Alerts Users to Security Flaws in Planet Technology Network Products

The United States Cybersecurity and Infrastructure Security Agency (CISA) has issued a critical security...

New iOS Vulnerability Could Brick iPhones with Just One Line of Code

A security researcher has uncovered a critical vulnerability in iOS, Apple's flagship mobile operating...

Resilience at Scale

Why Application Security is Non-Negotiable

The resilience of your digital infrastructure directly impacts your ability to scale. And yet, application security remains a critical weak link for most organizations.

Application Security is no longer just a defensive play—it’s the cornerstone of cyber resilience and sustainable growth. In this webinar, Karthik Krishnamoorthy (CTO of Indusface) and Phani Deepak Akella (VP of Marketing – Indusface), will share how AI-powered application security can help organizations build resilience by

Discussion points


Protecting at internet scale using AI and behavioral-based DDoS & bot mitigation.
Autonomously discovering external assets and remediating vulnerabilities within 72 hours, enabling secure, confident scaling.
Ensuring 100% application availability through platforms architected for failure resilience.
Eliminating silos with real-time correlation between attack surface and active threats for rapid, accurate mitigation

More like this

Obfuscation Techniques: A Key Weapon in the Ongoing War Between Hackers and Defenders

Obfuscation stands as a powerful weapon for attackers seeking to shield their malicious code...

React Router Vulnerabilities Allow Attackers to Spoof Content and Alter Values

The widely used React Router library, a critical navigation tool for React applications, has...

CISA Alerts Users to Security Flaws in Planet Technology Network Products

The United States Cybersecurity and Infrastructure Security Agency (CISA) has issued a critical security...