Thousands of GitHub repos hit with secret-stealing malware
Hijacked GitHub accounts spread malware that stole secrets, credentials, and API keys from thousands of repositories.
Overview
Attackers used 4,837 compromised GitHub accounts to spread secret-stealing malwareSoftware built to steal data, spy on users, lock files, or take control of a computer across thousands of repositories. They opened probe pull requestsA proposed set of code changes submitted to a software repository for maintainers to review and merge in 61,764 repositories to check for write access before delivering the malicious payloadThe part of an attack or malware file that carries out the harmful action on the target. The malware, a 1,500-line shellThe command-line interpreter program that accepts text commands and runs them on an operating system scriptA short program written in an interpreted language to automate tasks in a browser, shell, or application, collected GitHub Actions secretsPrivate credentials used by software, such as API keys, database passwords, and encryption keys, cloud credentialsAccess keys, tokens, or login secrets that grant control over cloud servers and storage, and API keysA secret string a program sends with an API request to identify itself and get access for AI services. It ran in at least 1,806 repositories, where it exfiltrated sensitive data and deleted run logs to hide its tracks. The attackers used three methods to deliver the payload, including modifying workflows and adding a postinstall hookA script inside a software package that runs automatically right after a developer installs the package in the package.json file. This hook allowed the malware to bypass GitHub's safeguards because it did not change any workflow files, allowing it to run during routine builds.
Terms in this story
- malware
- Software built to steal data, spy on users, lock files, or take control of a computer. News reports use malware as the umbrella term for viruses, ransomware, spyware, and trojans that criminals install on phones, laptops, or servers without permission. Security+ objective 2.4 lists the term
- pull requests
- A proposed set of code changes submitted to a software repository for maintainers to review and merge. In open-source security news, attackers sometimes submit a normal-looking pull request that hides a backdoor or exploits the project's automated test pipeline.
- malicious payload
- The part of an attack or malware file that carries out the harmful action on the target. A phishing email and an exploit are only the delivery steps, while the payload is the ransomware or spyware that actually runs once the computer is compromised.
- shell
- The command-line interpreter program that accepts text commands and runs them on an operating system. When an attacker exploits a web server and pops a shell, they can type operating system commands directly as if they were sitting at the server's keyboard.
- script
- A short program written in an interpreted language to automate tasks in a browser, shell, or application. System administrators write scripts to automate daily maintenance, while attackers often use a script to download malware and disable security settings without dropping a compiled file.
- secrets
- Private credentials used by software, such as API keys, database passwords, and encryption keys. Software teams use vault tools to keep secrets out of source code because anyone who finds a leaked secret in a public repository can log right in to the company's cloud services.
- cloud credentials
- Access keys, tokens, or login secrets that grant control over cloud servers and storage. Attackers scan public code repositories and developer laptops for cloud credentials so they can spin up cryptominers or download company databases.
- credentials
- The login details, such as a username and password or key, that prove who an account belongs to. Many breaches begin when attackers steal an employee's login credentials through a fake website and sign in to the company network as if they belonged there. Security+ objective 4.6 lists the term
- API keys
- A secret string a program sends with an API request to identify itself and get access. Software teams sometimes accidentally upload an API key to a public code repository, allowing attackers who scan for leaked keys to rack up cloud bills or read private databases. Security+ objective 4.6 lists the term
- API
- A structured interface that lets one software program request data or actions from another program. Mobile apps, websites, and cloud services talk to backend servers through an API, and a poorly protected API can let attackers pull customer records in bulk. Security+ objective 4.7 lists the term
- keys
- The secret value that locks or opens a message. Many breach and ransomware stories come down to who holds the cryptographic key, since strong encryption protects data only as long as the key stays secret. From the CYBR 101 room CYBR 101: Ciphers and encryption (part 1)
- postinstall hook
- A script inside a software package that runs automatically right after a developer installs the package. Supply chain attackers abuse the postinstall hook in open-source packages so that as soon as a developer downloads a library, the script steals cloud keys from their laptop.
This page is a short description made for this site. The article itself, with its author's name and its own link, is on the CSO Online website. Cite the article, not this page.
Read the full article on CSO Online (opens in a new tab)
Course connections
Each line below connects this story to a Security+ objective (a skill on CompTIA's Security+ exam, a common first cybersecurity certification), a CYBR 101 week, or a cybersecurity job, and quotes the words that made the connection.
- Kind of story: Breach or attack
"...hijacked GitHub accounts spread secret-stealing malware..." Found by reading the article; these exact words are in it - Security+ 2.4 Given a scenario, analyze indicators of malicious activity.
"Thousands of GitHub repos hit with secret-stealing malware..." Found in the headline - Security+ 4.6 Given a scenario, implement and maintain identity and access management.
"......1,806 repos, exfiltrating CI/CD secrets and cloud credentials." Found in the opening sentences - Security+ 4.7 Explain the importance of automation and orchestration related to secure operations.
"......executed in at least 1,806 repos, exfiltrating CI/CD secrets and cloud credentials." Found in the opening sentences - CYBR 101 week 9: malware, indicators and how detection works
"Thousands of GitHub repos hit with secret-stealing malware..." Found in the headline
How a story is connected to the course, and every objective, week and job role
Same story at other outlets
- Hackers compromise 4,800 GitHub accounts to steal cloud credentials
- Check your GitHub repos: A secret stealer hit tens of thousands of them
- Hackers Hijack 4,837 GitHub Accounts to Target 61,764 Repositories With CI Secret-Stealing Malware
- Attacker Used 4,837 Hijacked GitHub Accounts to Run a CI Secret Stealer in 1,806+ Repositories
- Hackers Compromise Nearly 5,000 GitHub Accounts to Steal Secrets From Software Development Pipelines
- Compromised GitHub accounts push CI secret stealer to tens of thousands of repositories