title: New PHP File Under a Linux Web Root or Upload Path
id: 2d8f3b71-0c54-5ae2-91b8-6d4e0f77a390
status: experimental
description: |
  OUR PATTERN. A new or renamed .php, .phtml or .phar file under a common web root or upload path.
  Deployments and plugins also do this; see KQL Q2. Path list is OUR ASSUMPTION [UNVERIFIED].
  PHP 19 Nov 2026 security release. Pack 1.0.0. Not run against live data.
references:
  - https://www.php.net/ChangeLog-8.php
author: CybaVerse threat hunt
date: 2026-11-19
tags:
  - attack.persistence
  - attack.t1505.003
logsource:
  category: file_event
  product: linux
detection:
  selection_name:
    TargetFilename|endswith:
      - '.php'
      - '.phtml'
      - '.phar'
  selection_path:
    TargetFilename|contains:
      - '/var/www'
      - '/usr/share/nginx'
      - '/srv/www'
      - '/srv/http'
      - 'public_html'
      - '/uploads/'
      - '/wp-content/uploads/'
  condition: selection_name and selection_path
falsepositives:
  - Application deployments, plugin updates and cache rebuilds
level: medium
