{
  "schemaVersion": "ebb.rule.v1",
  "id": "php.runtime.eol-7.4",
  "ecosystem": "php",
  "purl": "pkg:generic/php",
  "affectedVersions": "vers:semver/>=7.4.0|<8.0.0",
  "event": "end-of-life",
  "severity": "high",
  "title": "PHP 7.4 is end-of-life",
  "summary": "The PHP unsupported branches page lists the PHP 7.4 branch as end of life on 2022-11-28; the branch no longer receives security or bug fixes from the PHP project.",
  "replacement": "PHP 8.3 or later",
  "deadline": "2022-11-28",
  "sources": [
    {
      "title": "PHP unsupported branches",
      "url": "https://www.php.net/eol.php",
      "accessedAt": "2026-10-19"
    },
    {
      "title": "PHP supported versions",
      "url": "https://www.php.net/supported-versions.php",
      "accessedAt": "2026-10-19"
    }
  ],
  "provenance": {
    "observedAt": "2026-10-19",
    "reviewedAt": "2026-10-19",
    "reviewer": "arminazimi"
  },
  "migration": {
    "constraints": [
      "Keep .php-version, .tool-versions, composer.json require.php and config.platform.php, composer.lock platform.php, CI matrices, and container images on one supported PHP release line.",
      "Confirm Composer packages and extensions build on the target PHP and reinstall dependencies after changing the runtime."
    ],
    "steps": [
      {
        "id": "update-php-declaration",
        "title": "Raise the PHP version",
        "instructions": "Change the reported declaration from PHP 7.4 to a supported release (see the replacement), using the project's existing version manager.",
        "targets": "declaration"
      },
      {
        "id": "align-php-surfaces",
        "title": "Align other PHP version surfaces",
        "instructions": "Update CI setup-php versions, Dockerfile `php:` images, composer.json require.php and config.platform.php, and composer.lock platform.php so they agree.",
        "targets": "all"
      }
    ],
    "verification": [
      {
        "command": "php --version",
        "purpose": "Confirm the active runtime is the intended release."
      },
      {
        "command": "composer validate && composer install",
        "purpose": "Validate and reinstall dependencies on the new PHP."
      },
      {
        "command": "composer validate && vendor/bin/phpunit",
        "purpose": "Validate the Composer project and run the PHPUnit suite on the new PHP."
      }
    ]
  }
}
