Lessons From the Megalodon Attack: Protecting Your Philippine Dev Site From GitHub-Borne Supply Chain Attacks
Using the Megalodon attack that affected over 5,500 GitHub repositories as a case study, this guide explains the supply-chain countermeasures and NPC-notification practices that companies in the Philippines should take at their offshore development sites.
Lessons From the Megalodon Attack: A Practical Guide to Protecting Your Philippine Dev Site From GitHub-Borne Supply Chain Attacks
Based on the Megalodon attack that occurred in May 2026, this guide explains practical steps for Japanese companies with development sites in the Philippines to protect GitHub and their cloud credentials.
Part 1: Why This Matters
Step 1: The Philippine Business Context (3 min)
The Philippines is rapidly raising its profile as an offshore development site for Japanese companies. Metro Manila and Cebu host many local subsidiaries of Japanese IT companies, as well as BPO firms (outsourcing companies) that take on development for Japanese head offices, and many of them use GitHub to manage their source code. The supply-chain attack reported this time, called "Megalodon," flooded GitHub repositories with massive numbers of automated commits, hijacked the GitHub Actions mechanism used to automate development, and stole cloud credentials such as those for AWS and GCP. The damage reached over 5,500 repositories.
At Philippine development sites, it is not uncommon for local engineers to handle the Japan head office's cloud credentials and production API keys. As a result, just a single local developer's GitHub account being hijacked can cause the damage to spread all the way to the Tokyo head office's cloud environment. Moreover, in the Philippines, there is an obligation to report incidents to the NPC (National Privacy Commission, the Philippines' personal-data protection authority) under the Data Privacy Act (DPA), so a data leak becomes not just a technical problem but a legal risk.
In an office in Manila's BGC (Bonifacio Global City), a Japanese manager opens the conversation with the local IT lead like this: "Apparently there was a large-scale attack on GitHub last week. I'd like to check together whether any similar automated commits have gotten into our repositories—do you have time right now?" The local member, looking a bit surprised, immediately opens their laptop and starts checking.
Step 2: Organizing the Key Points of the Source Article (5 min)
The following is a summary table created based on the facts written in the source article.
| Item | Details |
|---|---|
| Attack name | Megalodon |
| Company that discovered/reported it | SafeDep (a security research firm) |
| Date of the attack | May 18, 2026 (about six hours, from 11:36 to 17:48 UTC) |
| Number of affected repositories | 5,561 (individual repositories) |
| Number of malicious commits injected | 5,718 total (2,878 + 2,841, sent from two email addresses) |
| Method of attack | Embedding credential-stealing code into GitHub Actions workflows |
| Types of information stolen | CI environment variables, AWS credentials, GCP access tokens, Azure credentials, SSH private keys, Docker/Kubernetes configs, API keys, database connection strings, GitHub Actions tokens, and more |
| Characteristics of the embedded mechanism | Used workflow_dispatch to plant a "dormant backdoor" that could later be triggered via the GitHub API |
| Related case of damage | A tampered version of Tiledesk (an open-source chat/chatbot platform) published on NPM was distributed on May 19–21 |
| Tiledesk's infection route | The GitHub repository was compromised, and the maintainer published from the contaminated code to NPM without noticing |
This table was created for study purposes based on facts in publicly available information. Please check the original article at the link above for details.
Related: See How AI Helps Philippine SMEs Build a Practical Adoption Roadmap for a detailed explanation.
Step 3: Comprehension Check (5 min)
Q1. What is the name of the GitHub automation feature used for the hijacking in the Megalodon attack?
Hint: It is a mechanism that automatically runs tests and deployments when code changes, and it lives under .github/workflows/.
Q2. State the time period and date when the attacker concentrated the commit injections.
Hint: It was concentrated within about six hours of a single day.
Q3. Why was the package called Tiledesk contaminated? Explain it while noting that the NPM account was not hijacked.
Hint: What the attacker touched was the GitHub side. The person who published to NPM did not notice.
Q4. Give one reason why the workflow_dispatch mechanism was convenient for the attacker.
Hint: The "recursion-prevention rule" GitHub normally applies does not apply to this trigger.
Q5. Name three types of "credentials" that could be stolen in this attack.
Hint: Recall the names of the three cloud providers, plus things related to SSH and APIs.
Related: See How Scalable AI Architecture Helps Philippine Businesses Grow Securely for a detailed explanation.
Part 2: Putting It Into Practice
Step 4: Deployment Steps in the Philippines (10 min)
We have organized the steps to prepare for a similar attack at a Philippine development site into five steps.
| Step | What to do | Philippine-specific notes |
|---|---|---|
| 1. Take inventory | List the GitHub repositories you manage and the GitHub Actions workflows running in each | If you have BPOs contracted separately in Manila and Cebu, they are often split by Organization, so request this from the IT leads of both sites at the same time |
| 2. Detect suspicious commits | Check the last six months of commits, filtering by "bot-like author names" and "commits occurring in large numbers in a short time" | Be especially wary of commits during time zones that differ greatly from local engineers' working hours (Philippine Standard Time, UTC+8) |
| 3. Minimize credentials | Remove long-lived production AWS/GCP/Azure keys from GitHub Secrets and switch to OIDC federation or short-lived tokens | Make two-factor authentication (MFA, identity verification via one-time codes) mandatory for all local members. App-based, not SMS, is recommended |
| 4. Notification and training | Prepare the NPC-notification procedure and an internal response manual, and hold a briefing session for local staff | In the Philippines, there is an obligation to notify the NPC within 72 hours of a security incident. For training, budgeting an external instructor fee of roughly 1,000–3,000 pesos per person is realistic |
| 5. Continuous monitoring | Build a setup that can check the GitHub Audit Log and cloud-side anomaly detection daily | Monitoring-tool license fees can run to tens of thousands of pesos per month. Confirm at the initial contract whether "log monitoring" is included in the BPO contract |
Step 5: Common Mistakes and Countermeasures (5 min)
Failure Pattern 1: "Deciding the response at the Japan head office alone and merely notifying the local site"
Bad example: Only the information systems department in Tokyo decides the response policy and sends the Manila subsidiary a mere directive: "Please operate under these rules starting tomorrow." The local engineers cannot understand the background, and it ends in a perfunctory response.
Good example: Together with the IT lead in Manila, you create a manual that fits the local workflow. In the team briefing session, show concrete examples of what was actually stolen in this incident, and always set aside time at the end to take questions.
Failure Pattern 2: "Reporting the security incident only to the head office and delaying NPC notification"
Bad example: When a data leak is suspected, you first report to the Tokyo head office and try to consider NPC notification only after waiting for the head office's decision. In the meantime, you miss the 72-hour deadline.
Good example: The local subsidiary's data protection officer (DPO, the person responsible for handling personal data) arranges in advance a procedure to proceed with head-office reporting and NPC notification in parallel. Prepare report templates in English, too.
Failure Pattern 3: "Leaving everything to the local BPO and not grasping the state of credential management"
Bad example: Thinking "the local BPO manages it, so it's fine," the Japan side does not grasp which staff hold the production-environment API keys. When a staff member leaves, the keys are left abandoned.
Good example: In the contract with the BPO, you specify a deadline for suspending accounts when someone leaves (for example, within 24 hours) and an obligation to submit a quarterly credential-inventory report. Prepare the report template on the Japan side and hand it over.
Part 3: Learning More Deeply
Step 6: Related Technical Terms (5 min)
A supply chain attack is an attack that targets one point somewhere in the flow from when software is created to when it is distributed, ultimately delivering malicious code to the people who use it. If a system that a Japanese-affiliated company in the Philippines delivers to its Japan head office gets hijacked, the damage spreads all the way to the Japanese customers it is delivered to, so the local subsidiary needs to treat this as a risk that is by no means someone else's problem.
GitHub Actions is a mechanism that automatically runs tasks such as tests and deployments when there is a change to code stored on GitHub. If the Manila development team operates by automatically deploying to production without waiting for review by the Japan side, abuse of this mechanism risks turning a local change directly into a production incident, so it is important to configure an approval flow in between.
CI/CD secrets are password-like strings used to log in to clouds or external services during the automated-deployment process. If you are developing at a Cebu BPO, it is reassuring to periodically confirm, even from the Japan side, that secrets are not written directly into the repository and that they are safely managed with the GitHub Secrets feature.
Two-factor authentication (MFA, a mechanism that verifies identity in two stages) is a mechanism that, in addition to a password, verifies identity using something like a smartphone authentication app. In the Philippines, it is not unusual for local engineers to work from cafes or coworking spaces, so password-only authentication is insufficient, and mandatorily applying MFA to everyone is the basis of a local subsidiary's security.
The data-breach notification obligation is a legal duty to report to the supervisory authority within a set deadline when there is a suspicion that personal data has leaked. In the Philippines, under the Data Privacy Act (DPA), you must notify the NPC within 72 hours, and if an incident occurs at the Manila subsidiary, you need to have operations in place to proceed in parallel with reporting to the Japan head office.
Step 7: Considering How to Apply This to Your Own Company (10 min)
Start taking inventory of your local site's GitHub right now
Hint for thinking: Can you immediately answer who holds management privileges for which repository at your Philippine site? When did you last check whether any departed staff member's account remains?
Next action: This week, set up a 30-minute meeting with your local IT lead and have them produce a list of GitHub Organization members and a list of who holds Owner privileges.
Decide the roles for security-incident response between the head office and the local site
Hint for thinking: If a data leak were suspected at the Manila site tonight, is it decided in writing who moves first, who contacts the NPC, and who reports to the Japan head office?
Next action: Create a single A4-sheet "initial-response flowchart" and have both the local subsidiary's DPO (data protection officer) and the Japan-side information systems lead sign and keep it.
Review the security clauses in the BPO contract
Hint for thinking: Does your current BPO outsourcing contract specify the deadline for suspending departed members' accounts, how credentials are managed, and the notification obligation when an incident occurs? Has it remained merely a verbal agreement?
Next action: Together with your legal contact, summarize in three lines a draft clause to add at the next contract renewal, share it with the local BPO in advance, and gauge their reaction.
Part 4: FAQ
Q1. We're a local subsidiary in the Philippines, but we're allowed to use the Japan head office's GitHub. Does Megalodon affect only the head office, with the local subsidiary unaffected?
It affects you. If local members access the head office's GitHub, then a local member's device or credentials being compromised affects the head office's entire repositories. Moreover, if unauthorized access occurs to a system containing local members' personal data, the obligation to notify the NPC (the Philippines' personal-data protection authority) arises on the local subsidiary's side. This is a problem that neither the head office nor the local site alone can handle.
Q2. We want to have our Filipino engineers take security training—is English-language material or Japanese-language material better?
We recommend conducting training for local members basically in English. In the Philippines, the standard language for business is English, and the NPC's guidance is official in its English version. Prepare a Japanese version separately for Japanese expatriates, and confirm internally that both contents match—this makes later alignment easier.
Q3. Is it acceptable to leave changes to GitHub Actions settings to local engineers?
The principle is minimizing privileges. We recommend operating so that changes to workflows involving production deployment require review by the Japan side. GitHub has a "Required reviewers" feature that makes approvers mandatory for specific changes; using it lets you pass head-office checks without slowing down local work speed.
Q4. We don't want to spend money on credential management. What is the minimum we should do?
There are three things you can do today without cost. First, enable two-factor authentication on everyone's GitHub account. Second, display a list of the past six months of commit history and confirm there are no unfamiliar author names. Third, remove long-lived production cloud keys from GitHub and switch to short-lived tokens. All of these can be done without additional licenses.
Q5. If a security incident occurs under Philippine law, can penalties reach the Japan head office?
The direct target of penalties is the legal entity handling personal data within the Philippines—that is, the local subsidiary. However, if the local subsidiary's responsible person is a Japanese expatriate, that individual may also bear responsibility. Furthermore, if the Japan head office is judged to substantially control the local subsidiary's personal-data processing, the head office may also become a subject of investigation. Consult a local lawyer early for legal matters.
Tips for Success (3 Tips)
Check your own GitHub's "automated commits" tonight
The hallmark of the Megalodon attack was that automated commits were injected at an abnormal speed—5,718 in about six hours. On your GitHub Organization's "Insights" screen, looking at the number of commits by author over the past 30 days lets you judge in five minutes whether there is an account with an inhumanly high count. Don't leave it to the local site—build a habit of confirming with your own eyes on the Japan head-office side too.
Connect your local subsidiary's DPO (data protection officer) and your Japan-side information systems lead by phone right now
A relationship where you make contact for the first time only after a security incident occurs won't make the 72-hour NPC notification in time. Right now, create a state where the two can communicate directly via Slack or chat, and set up a monthly regular meeting—this is the greatest defense when the time comes.
Roll out the "free minimum three-piece countermeasure set" this week
Making two-factor authentication mandatory for everyone, deleting long-lived production cloud keys, and taking inventory of the past six months of commits—these three can be done without additional licenses. Trying to build a perfect setup takes months, but just these three can be completed in a week even at a Philippine site. Start by concretely telling your local IT lead, "Please handle these three this week."
Bonus: How to Make Use of PH AI Works
PH AI Works is a company that supports the use of AI and technology for Japanese companies expanding into the Philippines and for Japanese business professionals in the Philippines. On this topic of supply-chain attack countermeasures, we can help especially in the following areas.
Examples of matters you can consult us on:
- Security checks of the local subsidiary's GitHub and cloud environment, and organizing the division of roles with the Japan head office
- Creating English training materials on security for local engineers, and preparing a Japanese version for Japanese expatriates
- Preparing the procedure for notifying the NPC (personal-data protection authority) and designing an initial-response flow that connects the local subsidiary and the Japan head office
If there is a topic of interest, you can consult us for free. Please feel free to contact us first.
References and Sources
About the author

Founder / AI Engineer (36+ years in IT)
- ●From Tokyo · based in Manila for 13+ years
- ●36+ years in IT (development, SEO, AI)
- ●IBM Certified Generative AI Engineer
- ●AI chatbots, RAG & AI agent development
A Japanese AI engineer with 36+ years in IT and 13+ years on the ground in the Philippines. I write from hands-on experience to help Japanese companies adopt AI that actually delivers results — chatbots, workflow automation, AI agents, and AI-driven marketing. Feel free to reach out in Japanese or English.
Free AI Consultation
Tell us your challenges and we'll propose the right AI adoption plan for your business.
Book a Free 30-Minute ConsultationRelated Articles
Spotting GEO Scams in the AI Search Era: A Guide to Fake Brand-Mention Services for Japanese Companies in the Philippines
A practical guide to protecting your company from GEO scams in the AI search era. Learn how to spot dubious tactics like PBN placements and fake posts, with contract and procurement tips for Japanese companies operating in the Philippines and Japanese residents on the ground.
6/27/2026
Yen at a 40-Year Low: An FX-Risk and AI Guide for Japanese Companies in the Philippines
With the yen near a 40-year low, this guide explains the FX-risk measures Japanese companies in the Philippines should take. It covers peso-denominated remittances, budget management, how to set up AI-based exchange-rate monitoring, and the BSP regulations to watch for, all framed around the realities of doing business in the Philippines.
6/26/2026
AI Didn't Kill Engineering Jobs: What the Latest Data Means for IT Talent Strategy at Japanese Firms in the Philippines
Far from replacing engineers, AI is expanding demand for them. For Japanese companies considering the Philippines and those already operating there, this guide explains how to build IT talent strategy and roll out AI, grounded in the latest hiring data and local regulations.
6/25/2026
Claude Tag in Depth: Putting a Slack-Based Virtual Employee to Work at Your Philippine Operation
A practical walkthrough of using Claude Tag, an AI virtual employee that works inside Slack, at a Philippine operation. Written for Japanese companies on the ground, it covers data-privacy compliance, building a peso budget, and tips for rolling it out to local staff.
6/24/2026
GM Installs 50 FANUC Robots: Balancing Automation and Jobs, Seen From the Philippines
Using GM's adoption of FANUC robots as a case study, this guide explains, in practical terms, how Japanese companies operating in the Philippines can advance workplace automation. It covers consideration for jobs, DOLE procedures, and how to work with local staff.
6/23/2026
What Is Loop Engineering? A Business-Automation Primer for Japanese Companies in the Philippines
A Philippines-focused look at "loop engineering" — the practice of letting AI do the work. Covers automating call centers, accounting outsourcing and other functions, managing costs, and complying with NPC data-protection rules — the adoption steps Japanese companies in the Philippines need to know.
6/22/2026
