Repository navigation
Auto Learning Pipeline
Varun Dubey edited this page Sep 13, 2026
·
2 revisions
Every scan and cleanup action automatically records to a local SQLite threat database. No manual steps needed - the system learns from every operation.
┌──────────────────┐
│ wp_quarantine │──┐
│ wp_scan_themes │ │ ┌─────────────────────┐ ┌──────────────────────┐
│ wp_scan_hidden │ ├───>│ _record_to_threat_db│────>│ cleanup_records │
│ wp_clean_core │ │ │ (best-effort) │ │ known_malicious_files│
│ wp_delete_opts │ │ └─────────────────────┘ └──────────────────────┘
│ wp_revoke_app │──┘
│ wp_complete │
│ wp_scan_mu │
└──────────────────┘
| Tool | Action Type | What's Stored |
|---|---|---|
wp_quarantine_file |
quarantine |
File hash, path, quarantine location. Also adds hash to known_malicious_files
|
wp_scan_hidden_plugins |
hidden_plugin_detected |
Plugin slug, risk flags (self-hiding, user-hiding, self-healing) |
wp_scan_themes |
malware_theme_detected |
Theme slug, detection reasons |
wp_clean_core_injections |
core_injection_deleted |
File path of each deleted injection |
wp_delete_malware_options |
malware_option_deleted |
Option name + its value |
wp_revoke_app_passwords |
app_password_revoked |
User ID + username |
wp_complete_cleanup |
complete_cleanup |
Summary with total steps completed |
wp_scan_mu_plugins |
mu_plugin_user_hiding |
MU-plugin filenames with user-hiding hooks |
This is the key intelligence feature:
- You quarantine a malicious file on Site A
- The file's MD5 hash is stored in
known_malicious_files - When scanning Site B,
wp_threat_check_filerecognizes the same hash - The file is flagged immediately - no signature matching needed
This means the system gets better the more sites you clean.
All threat DB recording is wrapped in a try/except. If the database is unavailable or a write fails:
- The cleanup continues normally
- No error is shown to the user
- The action is still logged to the plaintext log file
This ensures the learning pipeline never blocks actual security operations.
# View database stats
wp_threat_db_stats()Look for:
- cleanup_records - should grow after every scan/cleanup
- known_malicious_files - should grow after quarantine operations
- signatures - community + locally added detection patterns
The threat database is stored at:
~/.wp-malware-cleanup/threat_intel.db
This is a SQLite file. Back it up - it contains your accumulated threat intelligence.
After building up local threat intelligence, share it with the community:
# Export your signatures and hashes
wp_threat_export()
# Then submit a PR to the community repositoryGetting Started
Running as a Service
Threat Intelligence
Reference
Project
- GitHub Repo
- WP Vanguard (threat research)
- Wbcom Designs
- License: GPL-2.0-or-later