Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[GHSA-r7c9-c69m-rph8] Code injection in PHPUnit #197

Merged

Conversation

donatj
Copy link

@donatj donatj commented Apr 13, 2022

Updates

  • Affected products

The vulnerability was added with this commit - sebastianbergmann/phpunit@3aaddb1

You can see from the tags on that commit that it was added in 4.8.19 and no earlier.

image

@github-actions github-actions bot changed the base branch from main to donatj/advisory-improvement-197 April 13, 2022 05:05
@shelbyc
Copy link

shelbyc commented Apr 13, 2022

Good afternoon. Do you have a reference that indicates sebastianbergmann/phpunit@3aaddb1 marks the introduction of the vulnerability?

@donatj
Copy link
Author

donatj commented Apr 13, 2022

So a lot of sources say "PHPUnit before 4.8.28" I think it just a lazy way of saying "we didn't want to bother checking old versions"

That file didn't exist until 2015 but PHP Unit's first release was in 2006.

From https://nvd.nist.gov/vuln/detail/CVE-2017-9841

external access to the /vendor/phpunit/phpunit/src/Util/PHP/eval-stdin.php URI

If you compare the src/Util/PHP directory across releases, that file with the nasty dangerous eval was added in 4.8.19 - it did not exist prior to that and thus the bug did not exist.

The file itself was added in this PR - sebastianbergmann/phpunit#1956

@shelbyc
Copy link

shelbyc commented Apr 14, 2022

Thank you for all the information and providing links! I've added 4.8.19 as the earliest vulnerable version and changed the description to include it. The commit and pull request that introduced the vulnerability are also reference links now.

@advisory-database advisory-database bot merged commit 9ee0b70 into donatj/advisory-improvement-197 Apr 14, 2022
@advisory-database
Copy link
Contributor

Hi @donatj! Thank you so much for contributing to the GitHub Advisory Database. This database is free, open, and accessible to all, and it's people like you who make it great. Thanks for choosing to help others. We hope you send in more contributions in the future!

@advisory-database advisory-database bot deleted the donatj-GHSA-r7c9-c69m-rph8 branch April 14, 2022 15:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants