Cybersecurity news

Jessica Doner

Back to the list

How Cloudflare WAF helps protect against phpAfterShell and other critical PHP flaws

Cloudflare,

A security company disclosed a critical flaw in PHP's session handler that allows remote code execution, which the PHP project fixed the same day.

Vulnerabilities and patches

Overview

On November 19, 2026, the security research company depthfirst disclosed phpAfterShell, a vulnerability in PHPA widely used server-side scripting language that builds dynamic web pages before sending them to browsers's default file-based sessionAn active logged-in period of communication between a user or device and a server handler that can lead to remote code executionA flaw that lets an attacker run their own code on someone else's computer over a network. This flaw received a score of 9.2 out of 10 under the Common Vulnerability Scoring System, which marks it as critical. The PHP project fixed the issue the same day in versions 8.2.36, 8.3.37, 8.4.28, 8.5.13, and 8.6.0, which also resolved 16 other security vulnerabilitiesA flaw in software or hardware that lets an attacker do something the maker did not intend. Cloudflare's web application firewallA filter placed in front of a website that inspects HTTP traffic and blocks common web attacks blocks known attack patterns for this vulnerability, including for customers on the Free plan. The only complete fix is to upgrade PHP and restart every worker, as the firewall is an additional layer of defense rather than a replacement for the patchA software update released by a developer to fix a bug or close a security flaw. Organizations running these specific PHP versions must update their systems to prevent potential remote code executionA flaw that lets an attacker run any commands or program they choose on the target machine.

Terms in this story

PHP
A widely used server-side scripting language that builds dynamic web pages before sending them to browsers. Because millions of websites and content management systems run on PHP, a newly discovered vulnerability in the PHP engine can put a huge portion of the web at risk.
session
An active logged-in period of communication between a user or device and a server. Once you log in to a website, the server tracks your session so you can click from page to page without retyping your password on every screen.
remote code execution
A flaw that lets an attacker run their own code on someone else's computer over a network. This is one of the most dangerous bug classes in the news because an attacker across the internet can send a crafted request and take control of a server.
code execution
A flaw that lets an attacker run any commands or program they choose on the target machine. When an advisory warns that a bug allows arbitrary code execution, an attacker who triggers the flaw can install malware, read files, or take over the program's account.
security vulnerabilities
A flaw in software or hardware that lets an attacker do something the maker did not intend. Security advisories report a vulnerability when researchers or attackers find a coding mistake in an app or server that allows someone to break in or crash it. Security+ objective 2.3 lists the term
web application firewall
A filter placed in front of a website that inspects HTTP traffic and blocks common web attacks. Companies put a web application firewall in front of their web servers to spot and block SQL injection, cross-site scripting, and bot traffic before those requests hit the application code. Security+ objective 3.2 lists the term
patch
A software update released by a developer to fix a bug or close a security flaw. When a software flaw is discovered, the vendor ships a patch so administrators and ordinary users can update their systems before attackers exploit the bug. Security+ objective 4.3 lists the term
CVE
The public tracking code assigned to a specific known security flaw in software or hardware. Every cataloged software flaw gets a unique CVE label so security teams, vendors, and news reports can talk about the exact same bug without confusion. Security+ objective 2.3 lists the term
CVSS
The standard rating scale used to score how severe a software security flaw is. Security advisories include a CVSS rating from low to critical based on how easy a bug is to exploit and how much damage it allows. Security+ objective 4.3 lists the term
extension
A small add-on program installed inside a web browser to add features like ad blocking. Because a browser extension can often read and change every web page you visit, attackers buy or hijack legitimate extensions to steal session cookies and passwords.
server
A computer or program on a network that stores data and responds to requests from client devices. Online stores, email systems, and multiplayer games all run on servers in data centers or the cloud, making unpatched servers a primary target for intruders.
configuration
A text file that stores settings, network addresses, and options for how a program or server runs. Attackers who gain read access to a server look for its configuration file first because it often contains database passwords, API keys, and internal server paths.

This page is a short description made for this site. The article itself, with its author's name and its own link, is on the Cloudflare website. Cite the article, not this page.

Read the full article on Cloudflare (opens in a new tab)

Course connections

Each line below connects this story to a Security+ objective (a skill on CompTIA's Security+ exam, a common first cybersecurity certification), a CYBR 101 week, or a cybersecurity job, and quotes the words that made the connection.

How a story is connected to the course, and every objective, week and job role

Related