Linux 软件免费装
Banner图

UploadSleuth – Media Audit & Cleanup

开发者 eboxnet
更新时间 2026年9月15日 02:46
PHP版本: 7.4 及以上
WordPress版本: 7.1
版权: GPLv3 or later
版权网址: 版权信息

标签

media cleanup wp-cli uploads audit

下载

1.0.5 1.0.2 1.0.3 1.0.4 1.1.0

详情介绍:

UploadSleuth reconciles files in the uploads directory against WordPress attachment metadata and database references. Files without a detected reference are shown as likely stray candidates. They are not declared safe to delete. The plugin encourages a review, dry-run, and quarantine workflow before permanent removal. Features Important safety note A file can be referenced by an external system, theme or plugin code, encoded data, a custom database, or another location the plugin cannot inspect. Make a verified backup and test quarantined files before deleting anything permanently. UploadSleuth is maintained by the same developer behind Notificator – Alerts & Notifications, a WordPress plugin for turning site events into dashboard alerts and optional mobile or MQTT notifications. Browse the UploadSleuth source code on GitHub.

安装:

  1. Upload the upload-sleuth directory to /wp-content/plugins/.
  2. Activate UploadSleuth through the Plugins screen.
  3. Open Tools > UploadSleuth.
  4. Configure ignore patterns or custom table checks if needed.
  5. Begin with a narrow subdirectory scan.

升级注意事项:

1.0.5 Updates internal branding constants without changing plugin behavior. 1.0.4 Documents the cleanup-safe uninstall routine and clearer admin menu label. 1.0.3 Updates the directory readme and enables the WordPress Playground Live Preview configuration. 1.0.2 Adopts the UploadSleuth name and hardens quarantine, restore, backup, and deletion for WordPress.org directory review. 1.0.1 Improves dashboard consistency and adds a more useful plain-language guide to scanning and safe cleanup. 1.0.0 First stable public release with uploads auditing, safe cleanup workflows, Media Library integrity checks, and WP-CLI support. 0.16.0 Standards and submission-readiness release with hardened AJAX input handling and no intended workflow changes. 0.15.4 Allows safe multi-dot filenames to be scanned and cleaned without weakening traversal protection. 0.15.3 Improves spacing around dashboard notices. 0.15.2 Fixes Delete all for large and stale browser result sets while retaining server-owned validation. 0.15.1 Keeps operational feedback beside the workflow that produced it instead of at the top of the page. 0.15.0 Adds a guarded Media Library database-integrity workflow. Review offloaded media carefully before deleting records. 0.14.1 Corrects checkbox alignment in settings cards. 0.14.0 Reduces browser memory, DOM, layout, and filtering work for very large result sets. 0.13.3 Makes browser console diagnostics opt-in to avoid unnecessary client-side work. 0.13.2 Improves statistics placement and keeps empty counters out of the interface. 0.13.1 Keeps very large deletion reports from expanding the admin page. 0.13.0 Adds real file-action progress and tuning controls for slow servers. Revalidation remains enabled by default. 0.12.0 Adds visible progress feedback to Delete all and other dashboard tasks. 0.11.0 Adds persistent cleanup and reclaimed-space statistics; tracking begins after this update. 0.10.1 Fixes authenticated dashboard ZIP downloads returning an error page. 0.10.0 Adds whole-result deletion and selected/all quarantine cleanup controls. 0.9.2 Restores automatic ZIP downloads and makes dashboard dry-run opt-in. 0.9.1 Fixes ZIP download navigation and filenames. 0.9.0 Adds guarded quarantine restoration and fixes the remaining file-action page jumps. 0.8.0 Dashboard backup-and-remove now downloads a verified ZIP and no longer jumps the page during file actions. 0.7.0 Improves the live scanning and results interface without changing the safety model or filesystem actions. 0.6.1 Adds developer-facing code documentation without changing scan behavior. 0.6.0 Adds stoppable batched dashboard scans with preserved partial results. 0.5.0 Adds last-moment reference validation and WordPress-native standalone-file deletion. 0.4.0 Adds the complete WP-CLI reference directly to the UploadSleuth dashboard. 0.3.0 Adds verified backups before removing original files and improved scan diagnostics. 0.2.0 Adds the AJAX dashboard and safer, more capable WP-CLI workflows. Back up before performing any filesystem action.

常见问题:

Does a finding mean the file is safe to delete?

No. A finding means the plugin did not detect a reference in the locations it checked. Treat it as a candidate requiring review.

What does quarantine do?

Quarantine moves selected files into a timestamped directory below the configured quarantine folder while preserving their original relative paths. The quarantine directory is excluded from future scans.

Can I restore a quarantined file?

Yes. The Quarantined files panel lists recoverable files and restores each one to its original uploads path. Restore is blocked rather than overwriting a file that already exists there. The same panel can permanently delete selected quarantined files or all recoverable quarantined files. Downloadable backup ZIPs are not included in Delete all.

What does Download ZIP & remove do?

The dashboard and WP-CLI create one ZIP, verify every archived entry using its size and SHA-256 hash, and only then remove the originals. The dashboard starts an authenticated download; WP-CLI reports the protected server-side archive path.

Can I preview an action?

Yes. Dry-run is an opt-in checkbox in the dashboard. WP-CLI supports --dry-run with quarantine or deletion.

Can I stop a long scan?

Yes. Dashboard scans process database candidates in small batches. Stop finishes the current request, saves everything classified through the latest completed batch, and marks the result as partial. Unprocessed candidates are not included in partial findings.

Does it support ACF?

ACF commonly stores values in post, term, user, and options metadata. Those locations are checked. Unusual custom tables can be configured explicitly.

What is the WP-CLI command?

Run wp upload-sleuth. Use wp help upload-sleuth for all options.

How do I inspect older, larger candidates only?

Use wp upload-sleuth --older-than=90 --min-size=100 to report candidates older than 90 days and at least 100 KB.

Can the command be used in automation?

Yes. --summary-only --fail-on-findings provides a concise result and a non-zero exit when candidates exist.

Does the plugin send data elsewhere?

No. Scanning and file operations run locally within WordPress.

Can it find Media Library records whose files are missing?

Yes. The Library integrity tab checks attachment records in batches. It reports missing local originals and, separately, generated sizes that are absent while the original exists. Missing-original records can be deleted individually or all at once after confirmation; cleanup uses WordPress wp_delete_attachment() rather than direct database queries. Sites using S3, CDN, or another media-offload plugin require special care. A valid remote attachment may intentionally have no local file, so confirm the remote object and offload configuration before deleting a reported record.

更新日志:

1.1.0 1.0.5 1.0.4 1.0.3 1.0.2 1.0.1 1.0.0 0.16.0 0.15.4 0.15.3 0.15.2 0.15.1 0.15.0 0.14.1 0.14.0 0.13.3 0.13.2 0.13.1 0.13.0 0.12.0 0.11.0 0.10.1 0.10.0 0.9.2 0.9.1 0.9.0 0.8.0 0.7.0 0.6.1 0.6.0 0.5.0 0.4.0 0.3.0 0.2.0 0.1.0