Add policy: detect compromised Laravel-Lang Composer packages#46121
Draft
fleetdm-bot wants to merge 1 commit into
Draft
Add policy: detect compromised Laravel-Lang Composer packages#46121fleetdm-bot wants to merge 1 commit into
fleetdm-bot wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Context
On May 22, 2026, Socket and Aikido disclosed a supply chain attack against the Laravel-Lang ecosystem — 233 package versions across 700 GitHub repositories were backdoored with credential-stealing malware delivered via Composer's autoloader. Affected packages:
laravel-lang/lang,laravel-lang/attributes,laravel-lang/http-statuses,laravel-lang/actions.An ad-hoc live query confirmed no current hits across responding hosts, but ~72 workstations were offline at scan time. This PR adds a continuous Fleet policy so any host that pulls a compromised package (now or later) is flagged automatically.
Changes
lib/all/policies/laravel-lang-supply-chain-compromised-packages.yml— fails whenvendor/laravel-lang/*/composer.jsonis found under common project locations on macOS, Linux, or Windows.fleets/workstations.ymlandfleets/servers.yml.Detection logic
Uses the osquery
filetable withpath LIKEpatterns covering:/Users/%/.../vendor/laravel-lang/%/composer.json(up to 4 levels deep)/home/%,/var/www/%,/opt/%,/srv/%pathsC:\Users\%\...\vendor\laravel-lang\%\composer.jsonPolicy passes when the query returns zero rows.
Resolution (if failing)
vendor/laravel-lang/*directories.composer.jsonandcomposer.lock, thencomposer install.APP_KEY.