← Voltar ao feed

PHP 8.6 released with hardened session defaults, stricter file-write error handling and deprecations that may break existing apps

2 fonte(s) · 2 atualização(ões) · publicado 19/11/2026 12:22 · coletado há 2 semanas

Matéria consolidada. Reúne 2 matérias que o Tifon tinha publicado separadamente sobre a mesma história. A IA reescreveu o relatório com o que as 2 fontes trouxeram em 22/11/2026 04:08; os links antigos trazem para cá.

Fontes: theregister.com ↗ helpnetsecurity.com ↗

PHP 8.6 has been released. One source says it was available by November 19, 2026 (helpnetsecurity.com), another says it was officially released on November 20, 2026 (theregister.com). This is a product release, not a vulnerability or an incident, and no CVEs, exploitation or threat activity are reported for the release itself (helpnetsecurity.com). It enables safer session defaults, makes file operations report failures more reliably and turns more invalid input into errors, which can help against session hijacking and CSRF. It also adds partial function application, a Time\Duration class, the Io\Poll polling API and clamp(). Some changes and deprecations can break existing applications, so defenders and administrators should test before upgrading. The Register ties the hardening to an October wave of unauthenticated RCE flaws affecting WordPress, Laravel and Symfony (theregister.com).

Detalhes técnicos

  • Sessions: sessions now start with session.use_strict_mode and session.cookie_httponly enabled and session.cookie_samesite set to Lax (helpnetsecurity.com). Strict Mode, HttpOnly and SameSite are described as mitigations for session hijacking and CSRF (theregister.com). Custom session handlers that do not implement both create_sid() and validateId() are deprecated (helpnetsecurity.com).
  • File and stream errors: fclose(), file_put_contents() and copy() now return false when flushing or closing a file fails. Many other functions throw a ValueError on out-of-range values, invalid flags or strings with NUL bytes. Stream operations can be set to throw a StreamException (helpnetsecurity.com). The Register describes the NUL-byte handling as a measure to curb RCE exploitation techniques (theregister.com).
  • Crypto and TLS: Sodium gains post-quantum key encapsulation (X-Wing and ML-KEM-768). TLS streams gain support for TLS 1.3 early data (helpnetsecurity.com).
  • Deprecations:
    • The mbstring regex functions mb_ereg() and mb_split() are deprecated because Oniguruma is no longer maintained. PCRE with the u modifier is the recommended replacement.
    • is_double(), is_long(), is_integer(), doubleval() and spl_object_hash() are deprecated.
    • Using return inside a finally block is deprecated. (helpnetsecurity.com)
  • Behaviour change: trim(), ltrim() and rtrim() now strip form feeds by default (helpnetsecurity.com).
  • Features: partial function application, a Time\Duration class, the Io\Poll polling API and clamp() (helpnetsecurity.com, theregister.com).

Remediação

  • Test login and session flows before upgrading, because the session defaults changed (helpnetsecurity.com).
  • Review code that relies on the old file-write behaviour, on NUL-byte handling or on the deprecated functions, and migrate custom session handlers to implement create_sid() and validateId() (helpnetsecurity.com).
  • Check that overrides in php.ini or in application frameworks do not negate the new secure session defaults (theregister.com).

Relatos divergentes

  • Release date: helpnetsecurity.com was published on November 19, 2026 and reports PHP 8.6 as released. theregister.com, published on November 20, 2026, says the official release was on November 20, 2026. The sources do not reconcile this, and the later article is the only one giving an explicit date.
  • Security context: theregister.com links the release to an October wave of unauthenticated RCE flaws in WordPress, Laravel and Symfony and to PHP Foundation commitments on faster patching. helpnetsecurity.com reports no CVEs or threat activity, and neither source names CVE identifiers for that wave, so the claim is unverified here.

Linha do tempo

  1. theregister.com ↗ · pub. 20/11/2026 20:28 · coletado 20/11 22:00

    PHP 8.6 Released with Hardened Session Security Defaults and Error Handling Enhancements

    ler a análise desta fonte

    On November 20, 2026, PHP 8.6 was officially released, continuing PHP's yearly update cycle. This release follows intense scrutiny from a previous wave of vulnerabilities in October that included unauthenticated remote code execution (RCE) flaws impacting major applications like WordPress, Laravel, and Symfony. PHP 8.6 introduces stricter default security settings for session management, including enabling Strict Mode, HttpOnly, and SameSite flags by default, which help mitigate session hijacking and cross-site request forgery attacks. Additionally, the engine now throws errors on null byte strings to curb RCE exploitation techniques and improves error signaling for file operations. These hardening measures come after community proposals and the PHP Foundation's commitment to faster patch deployment. The release also includes developer convenience features such as Partial Function Application, a native polling API, and utility functions like a Duration class and clamp(). However, administrators must ensure that existing configuration overrides (e.g., in php.ini or within application frameworks) do not negate these new default security features.

  2. helpnetsecurity.com ↗ · pub. 19/11/2026 12:22 · coletado 19/11 13:02 primeiro registro

    PHP 8.6 released: new session security defaults, stricter write error handling and deprecations that can break existing apps

    ler a análise desta fonte

    PHP 8.6 has been released. It adds partial function application, a Time\Duration class, the Io\Poll polling API and clamp(). This is product release news, not a vulnerability or an incident. No CVEs, exploitation or threat activity are reported. The article was the only source used, with no web research. Some changes can affect existing apps and are worth testing before an upgrade.

    Technical Details

    • Sessions now start with session.use_strict_mode and session.cookie_httponly enabled and session.cookie_samesite set to Lax. Custom session handlers that do not implement both create_sid() and validateId() are deprecated.
    • fclose(), file_put_contents() and copy() now return false when flushing or closing a file fails. Many other functions throw a ValueError on out-of-range values, invalid flags or strings with NUL bytes. Stream operations can be set to throw a StreamException.
    • Sodium gains post-quantum key encapsulation (X-Wing and ML-KEM-768). TLS streams gain support for TLS 1.3 early data.
    • The mbstring regex functions (mb_ereg(), mb_split()) are deprecated because Oniguruma is no longer maintained. PCRE with the u modifier is the recommended replacement.
    • is_double(), is_long(), is_integer(), doubleval() and spl_object_hash() are deprecated. Using return inside a finally block is deprecated.
    • trim(), ltrim() and rtrim() now strip form feeds by default.

    Remediation

    Test login and session flows before upgrading, because the session defaults changed. Also review code that relies on the old file-write behaviour or on the deprecated functions.