An overview of the recent supply‑chain attacks that hit PHP packages, the security measures Composer and Packagist have already deployed, the features slated for release in the next weeks, and the community’s concerns about mandatory MFA, immutable releases, and long‑term provenance verification.
Composer & Packagist Supply‑Chain Security – An Update

Over the past few months the PHP ecosystem has been hit by a series of supply‑chain attacks that exploited compromised GitHub accounts and stolen access tokens. The most visible incidents were the hijacking of laravel‑lang on May 22 and intercom/intercom‑php on April 30. Those events sparked a flurry of discussion about how much trust developers place in the open‑source supply chain and what the Composer/Packagist stack can do to mitigate the risk.
Below is a snapshot of the current state, the short‑term roadmap, and the longer‑term vision. I’ll also highlight the arguments that are being raised against some of the upcoming changes – mainly around mandatory multi‑factor authentication (MFA) and the move toward immutable build artifacts.
1. What is already in place?
| Feature | How it works | Current impact |
|---|---|---|
| Aikido malware detection | Packagist imports a free‑license feed from the Aikido service. When a version is flagged, the UI shows a warning and the metadata served to Composer includes a malware flag. |
The recent Laravel‑lang and Intercom attacks were caught by this feed; the flagged versions were removed before most users could install them. |
| Rapid manual incident response | The Packagist team monitors the feed and the public transparency log, then pulls malicious versions within minutes. | Provides a safety net, but still relies on human operators – a bottleneck the team wants to eliminate. |
| Public transparency log | Every security‑relevant event – ownership changes, maintainer additions/removals, version reference updates – is recorded in a log that can be queried via an API (login required). | Enables investigators to reconstruct attack timelines, see who changed a tag, and audit package history. |
These components already give the PHP community a level of observability that many other ecosystems lack. Still, they are largely reactive: they tell you what happened after the fact.
2. Shipping this week – Composer 2.10 and immutable tags
2.1 Dependency‑policy framework
Composer 2.10 introduces a unified dependency policy configuration. Instead of scattering checks across the client, all security‑related decisions (vulnerability advisories, abandoned packages, malware flags) are now evaluated through a single policy engine. This makes it possible to add new checks without breaking existing workflows.
2.2 Minimum‑release‑age (cool‑down) policy (planned)
The first policy to be added is a minimum‑release‑age rule: Composer will refuse to install a version that is younger than N hours/days. The rationale is simple – most malicious tags are published and then removed within a few hours. By enforcing a short quarantine period, the client can avoid pulling a version that has not yet been scanned.
Note: The policy can only be enforced once Packagist guarantees that published tags are immutable. The next section explains that change.
2.3 Stable version immutability on Packagist
Effective this week, stable (non‑dev) versions become immutable on the registry. If a maintainer re‑tags a version or force‑pushes an annotated tag, Packagist will reject the change and email the maintainer. The only mutable releases remain branch‑based dev versions, which are expected to move.
Why this matters:
- Auditing – A fixed tag means an auditor can always retrieve the exact commit that was shipped.
- Safety – An attacker who compromises a maintainer’s account can no longer replace an existing widely‑used version with a back‑doored one.
- Predictability – Composer will either install the original artifact or raise an error; it will never silently substitute a different commit.
The change also forces downstream tools (mirrors, SBOM generators, CI scanners) to work with a stable reference rather than a moving target.
3. Upcoming tooling and policy work
| Initiative | Expected release | What it adds |
|---|---|---|
| MFA events in the transparency log | ~6 months | Public visibility of when maintainers enable/disable MFA or use recovery codes. |
| MFA status on maintainer profiles | ~6 months | Downstream users can see at a glance whether a package’s owners have MFA enabled. |
| Organizational Package Ownership | Q4 2026 | Packages can be owned by an organization rather than a shared account; individual users act on behalf of the org. |
| Private Packagist policy enforcement | Rolling | Server‑side enforcement of dependency policies for pre‑2.10 clients, allow‑list for Composer plugins, client‑version gating. |
| Immutable build artifacts + SLSA provenance | 2027‑2028 (long‑term) | Packagist will host signed tarballs, publish Sigstore attestations, and let Composer verify them locally. |
The short‑term work (MFA visibility, organizational ownership) is aimed at reducing the single‑point‑of‑failure that a compromised personal account represents. The long‑term vision aligns the PHP ecosystem with the OpenSSF SLSA and Security Software Repositories Working Group recommendations.
4. Counter‑perspectives – Pushback from the community
4.1 Mandatory MFA – security vs friction
The plan to eventually require MFA for all Packagist accounts (and to enforce it at the organization level) has sparked debate. Proponents argue that the data from recent attacks shows a clear pattern: a stolen token equals a compromised package. Critics worry about:
- Onboarding friction for hobbyist maintainers who may not have a hardware token or phone capable of receiving OTPs.
- Shared‑account workflows that many companies still use for CI pipelines; moving to per‑user accounts requires changes to CI configuration and secret management.
- Potential lock‑outs if a maintainer loses access to their second factor and cannot recover the account quickly.
The Packagist team acknowledges these concerns and is rolling out organizational ownership to make the migration smoother. The idea is to let a company own a namespace (e.g., acme/) and assign individual maintainers with their own MFA‑protected accounts, while CI jobs use short‑lived tokens generated via the organization’s API.
4.2 Immutability and the “re‑tag” workflow
Historically, many maintainers have used re‑tagging to fix a broken release without bumping the version number. The new immutability policy forces a new version for any change, which some see as a burden because it adds a version bump to what would otherwise be a trivial fix.
However, the trade‑off is that a re‑tag can silently corrupt downstream installations. The Composer lock file stores the commit hash, but a composer update will refresh metadata and may pull the new tag without warning. By making tags immutable, Packagist eliminates that silent drift.
4.3 Build‑artifact hosting and the “centralized” model
Hosting signed tarballs directly on Packagist would give the registry full control over the artifact, but it also introduces operational risk:
- Packagist would need to guarantee storage durability and availability for every published package.
- Smaller projects might be reluctant to trust a single point of failure for their distribution.
- The ecosystem would have to adopt a new verification flow in Composer, which could break older clients.
The plan is to roll this out as an opt‑in feature for organizations that need the highest assurance level, while the default remains the current git‑tag‑based distribution.
5. How you can help today
- Enable MFA on your Packagist account right now. The UI now shows a badge on your profile, and the upcoming transparency‑log entry will make the status visible to downstream users.
- Avoid re‑tagging stable releases. If you discover a problem, publish a new version (e.g.,
1.2.1instead of overwriting1.2.0). - Watch the transparency log – it is publicly accessible after login. You can build alerts for changes to packages you depend on.
- Consider Private Packagist if you run an organization that needs enforceable policies across many projects. It already supports server‑side policy enforcement and plugin allow‑lists.
- Provide feedback on the upcoming Composer 2.10 release notes and the dependency‑policy docs. Early adopters can surface edge cases before the policies become mandatory.
6. Looking ahead
The PHP supply‑chain story is still being written. The next few weeks will see Composer 2.10 land, immutable tags go live, and MFA events start appearing in the public log. Over the coming months the focus will shift to organizational ownership, staged releases with FIDO2, and the first experiments with signed build artifacts.
If the community embraces these changes, the PHP ecosystem could reach the same security maturity as PyPI or npm – where mandatory 2FA, provenance attestations, and quarantine periods are now the norm. If the pushback is strong enough, the roadmap may need to be adjusted, especially around mandatory MFA and centralized artifact hosting.
Bottom line: the tools are already here, the policies are on the horizon, and the most effective defense right now is simple hygiene – enable MFA, avoid mutable tags, and keep an eye on the transparency log.

Comments
Please log in or register to join the discussion