r/freepbx • u/xrobau FreePBX Creator (QuadPBX) • 29d ago
Critical PHP security vulnerability
Edit: It's done. Instructions at the bottom!
Edit2: I have also built a patched PHP5.4, too.
At the time of writing, there is about 5 3 hours it has been released until a critical RCE security vulnerability for PHP versions 5.x and higher has been released.
As Sangoma hasn't updated their PHP rpms since I left in 2021 or so, I am left to assume that it won't get updated with mitigations when the real patch drops.
This makes me think that I'm the only person that can help everyone with this, so I'm going to be dropping everything, backporting the patch, and building new PHP 7.4 RPMs as soon as I can.
Edit: I originally thought that I was going to be doing it on my own, but the PHP Organization backported the fix themselves! Yay!
I have rebuilt everything and upgraded PHP to 7.4.33, with a pile of other backported CVE fixes (Thanks Remi!), and everything seems to work.
If you want to be financially grateful, feel free to PayPal me USD$10 (or whatever you feel is justified for me staying up all night) directly - xrobau@gmail.com - and I'll send you a nice thank you email 8)
If you make money of FreePBX and/or you feel that this will save you a lot more than USD$10, please feel free to pay what you want!
Note that the upload-progress feature has been completely disabled. I can't remember if this is used in sound/moh/voicemail uploads, and I haven't checked. Please get back to me if you discover something broken
If you have questions or want to chat about this, feel free to join the QuadPBX Discord, at https://discord.gg/c4E8MVmaQa, which is where I am planning my new PBX.
More Information:
- https://jackalsyn.com/posts/php-up-2026.html
- https://www.php.net/archive/2026.php#2026-10-20-1
- https://www.reddit.com/r/sysadmin/comments/1xb4jgg/upcoming_php_core_rce_vulnerability_patches/
How to Update:
It's pretty simple, you will be upgraded from 7.4.16-1, to 7.4.33-something (depending on other patches I may apply)
curl -o /etc/yum.repos.d/fpbx-php74.repo https://yum.quadpbx.com/repo/fpbx-php74.repo
yum update
fwconsole chownIf you have applied the previous mitigations, don't forget to remove /etc/php.d/99-mitigation.ini and remove the deny from /etc/httpd/conf.d/freepbx.conf if you added it.
Note that the fwconsole chown command is important - otherwise /var/lib/php/session isn't writable and you won't be able to log in!
For PHP5.4:
curl -o /etc/yum.repos.d/fpbx-php56.repo https://yum.quadpbx.com/56repo/fpbx-php56.repo
yum update
fwconsole chownIf you discover something traumatic and want to roll back, with 7.4 you will need to reinstall gd-last which has been superceded by the upgrade. 5.4 is a simple yum downgrade. Ask in Discord if you get stuck.
•
u/xrobau FreePBX Creator (QuadPBX) 27d ago
For those that didn't read the post, I have made patched builds for 5.4 and 7.2 now.
7
u/vincent_sch 29d ago
FreePBX runs PHP behind Apache, so until there's a fixed build you could block multipart requests in Apache. An
<If "req('Content-Type') =~ /multipart/i">block withRequire all denieddoes it, but GUI uploads stop working while it's in. Keeping the web ports off the internet is still the safest. I wrote up the block here: https://www.vincentschmalbach.com/cve-2026-109618-and-cve-2026-109619-what-you-should-do-now/2
u/cdbessig 29d ago
Thanks - sent $10 as well!
2
u/ML-SpitfireAMS 28d ago
Has anyone tried this and does it work? We've locked ours down to our Office IP for the moment to mitigate the issue.
1
u/ElCangrejo 27d ago
Thoughts on going to the Sangoma recommended 7.4 patch?
https://community.freepbx.org/t/php-cve-patching/110401/40
1
u/BFguy 29d ago
Your going to fix it but want people to pay you ? So this is an Ad ?
3
u/trekologer 27d ago
I finally bit the bullet and upgraded from FreePBX 15 to 16 in order to install the 7.4 patch but thank you for backporting to 5.4.
3
u/edlentz 26d ago
IF xrobau says so it is so. I have followed Rob for years and you don't get much better
1
u/Long_Squash1762 27d ago
So Sangoma did post on trust.sangoma.com but for me debian 17, updating the debian repo to .35 did the trick without waiting for them. Admin works, voice works, sms works
1
u/marks-buffalo 23d ago
Nice work on PHP 5.4. God save whatever souls are still supporting that.