HighGHSA-7xr2-8ff7-6fjqCVE-2023-37473

zenstruck/collection passing callable string to EntityRepository::find() and query()

Published 14 Jul 2023 · Updated 10 Sept 2026

Is your project on an affected zenstruck/collection?

Private repo? Upload its lockfile instead, or connect GitHub to check every repo.

Look after several Laravel or PHP apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie

Affected package

Affected
<0.2.1
Fixed in
0.2.1
Update to the fixed version for your release line, for example:composer require zenstruck/collection:^0.2.1

Details

Impact

Passing _callable strings_ (ie system) caused the function to be executed.

Patches

Fixed in v0.2.1.

Workarounds

Do not allow passing user strings to EntityRepository::find() or query().

References

Fix commit.

Is GHSA-7xr2-8ff7-6fjq in any of your client repos?

Checking one package by hand is fine. Checking it across forty client projects is not. NPMscan reads the lockfiles in every GitHub repo you pick, finds each project with an affected zenstruck/collection, and gives you the command that fixes it.

References

Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily.