Loading...
Skip to main content

CVE-2026-54178 — Vulnerability in backpack/crud — CVE Details

HIGH

Laravel Backpack CRUD: Arbitrary file deletion via attacker-controlled clear_<attr>[] in HasUploadFields::uploadMultipleFilesToDisk

Published August 20, 2026Updated September 10, 2026Source: osv

Summary

## Summary `HasUploadFields::uploadMultipleFilesToDisk` (in `src/app/Models/Traits/HasUploadFields.php`) reads file paths from the `clear_<attribute>[]` request input and deletes them from the configured storage disk **without verifying that the paths belong to the current model record**. An authenticated user with Update access on any CRUD that wires `uploadMultipleFilesToDisk` as a model mutator (the pattern documented in the v5.x `upload_multiple` field guide) can supply arbitrary disk-relative paths in `clear_<attr>[]` to delete files that were never associated with the record they are editing. The safe pattern already exists in the codebase: `src/app/Library/Uploaders/MultipleFiles.php` intersects the requested deletions against the files currently stored in the database column before calling `Storage::disk()->delete()`. The trait method lacks that intersection. ## Affected code - `src/app/Models/Traits/HasUploadFields.php` — `uploadMultipleFilesToDisk` (primary sink) - `src/app/Models/Traits/CrudTrait.php` — mixes `HasUploadFields` into all Backpack-managed models The vulnerability is present in all 5.x, 6.x < 6.8.12, and 7.x < 7.0.35 releases. ## Impact An attacker with low-privilege Backpack admin access (e.g. a content editor) can delete any file under the configured disk root: other records' attachments, shared assets, or files placed on the same disk for operational purposes. No confidentiality impact (files cannot be read, only deleted). **CWE-285** (Authorization Bypass) / **CWE-639** (IDOR on file deletion) CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H = **8.1 High** ## Fix Intersect `$files_to_clear` against the filenames currently persisted on the model before calling `delete()`, mirroring the logic already present in `MultipleFiles::uploadFiles`. Fixed in **6.8.12** and **7.0.35**. Deployments still using the `uploadMultipleFilesToDisk` mutator pattern from the v5.x docs should migrate to the Uploader API (`MultipleFiles::class` via `config/backpack/crud.php`), which applies the safe intersection automatically. ## Credits Reported by Vishal Shukla ([@shukla304](https://github.com/shukla304)).

Advisory Timeline

  • First published August 20, 2026 (53 days ago).
  • Last revised September 10, 2026 — 20 days after initial publication.

Remediation

Upgrade to the fixed version using your package manager.

Composer
Update backpack/crud to 6.8.12 or later
composer require "backpack/crud:^6.8.12"
Composer
Update backpack/crud to 7.0.35 or later
composer require "backpack/crud:^7.0.35"

After upgrading, run your dependency scanner again to confirm the vulnerability is resolved.

Affected Packages (3)

Affects 1 ecosystem: packagist (1).

PackageEcosystemAffectedFixed In
backpack/crud
packagist
6.0.0, 6.0.1, 6.0.2, 6.0.3 (+114 more)6.8.12
backpack/crud
packagist
7.0.0, 7.0.1, 7.0.10, 7.0.11 (+31 more)7.0.35
backpack/crud
packagist
5.0.0, 5.0.1, 5.0.10, 5.0.11 (+286 more)Range-based data available

Vulnerability Classification

Common Weakness Enumeration (CWE) identifiers for this vulnerability type.

  • CWE-22
    Path TraversalMITRE
  • CWE-285
    Improper AuthorizationMITRE
  • CWE-639
    Insecure Direct Object Reference (IDOR)MITRE

CVSS Score Breakdown

What the CVSS (Common Vulnerability Scoring System) 8.1 score means for each attack dimension.

Attack Vector
Network
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
High
Availability
High

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H

Frequently Asked Questions

What is CVE-2026-54178?
Laravel Backpack CRUD: Arbitrary file deletion via attacker-controlled clear_<attr>[] in HasUploadFields::uploadMultipleFilesToDisk This vulnerability has been assigned a severity rating of HIGH (CVSS score: 8.1/10).
How do I check if my project is affected by CVE-2026-54178?
CVE-2026-54178 affects backpack/crud. Use GeekWala's free vulnerability scanner to check your dependencies against CVE-2026-54178 and 200,000+ other known vulnerabilities.

Severity & Exploitability

CVSS Score
8.1

High exploitability or significant impact. Prioritize remediation within days.

Also Known As

GHSA-8xjm-wqrp-2f25

Related CVEs

  • CVE-2026-54182
    HIGH

    Laravel Backpack CRUD: OS command injection in Stats::makeCurlRequest via attacker-controlled Host header (pre-auth)

  • CVE-2026-65954
    HIGH

    PHPCSUtils: Remote code execution via eval() in AbstractArrayDeclarationSniff::getActualArrayKey()

  • CVE-2026-61825
    HIGH

    code16/sharp has a stored XSS via data-html-content Sanitizer Bypass

Check if you're affected

Scan your dependencies to see if this vulnerability affects your projects.

Scan Your Dependencies