Please perform a **complete, deep, end-to-end malware cleanup, backdoor removal, database cleanup, file integrity check, plugin/theme audit, administrator audit, persistence investigation, reinfection prevention, and security hardening** for this WordPress website.
The final result must be a **clean, stable, secure, fully working website and database** with no malware, no backdoors, no malicious plugins, no suspicious administrator accounts, no persistence mechanism, and no unnecessary malicious residue left behind.
## Main Goal
I want you to check **everything**,
## Critical Problem
The website is currently showing a **suspicious CAPTCHA popup**.
After interacting with this popup, it shows instructions/steps that can lead users toward actions that may compromise or infect their PC.
This is not legitimate website behavior.
Please investigate and **completely remove the source of this fake/malicious CAPTCHA popup** from:
- Website files
- Database
- Plugins
- Themes
- MU plugins
- JavaScript
- PHP
- HTML
- WordPress options
- Posts/postmeta
- Elementor/Divi data
- Widgets
- Header/footer injections
- Cron jobs
- `.htaccess`
- `wp-config.php`
- `.user.ini`
- Server/hosting configuration
- External scripts
- Remote URLs
Do not only hide the popup with CSS or JavaScript.
Find and remove the actual malware/backdoor responsible for generating it.
including:
- Website files
- WordPress core
- Themes
- Plugins
- MU plugins
- Uploads
- Hidden files
- Configuration files
- Database
- Users
- User metadata
- Cron jobs
- Options
- Transients
- Page-builder data
- Server/hosting configuration where accessible
- File permissions
- Recently modified files
- Cross-site infection possibility
- Reinfection source
Do not stop after removing visible malware.
The most important requirement is:
**Find the root cause and persistence mechanism so the malware does not come back again.**
The required workflow is:
**Scan → Detect → Investigate → Confirm → Remove → Clean Database → Remove Persistence → Harden → Test → Re-Scan → Reinfection Test → Final Verification**
---
# 1. No Backup or Quarantine Required
I already have my own backup.
Therefore:
- Do not create another backup.
- Do not create a quarantine folder.
- Do not keep `.infected` files.
- Do not keep `.bak` malware copies.
- Do not archive malicious files.
- Do not leave disabled malware inside the website.
- Do not move malicious files into another folder.
If a file is confirmed malicious and is not needed by the legitimate website, **delete it completely**.
If malware is injected inside a legitimate file, remove only the malicious code and preserve the legitimate functionality.
---
# 2. Important Safety Rule
Do not blindly delete a file only because:
- Its name looks unusual
- It is recently modified
- It contains `eval`
- It contains `base64_decode`
- It contains `gzinflate`
- It contains `file_put_contents`
- It contains `exec`
- It contains dynamic code
First inspect the context and confirm whether it is actually malicious.
The cleanup must not damage legitimate website functionality.
---
# 3. Full Recursive File Scan
Scan the complete WordPress installation recursively.
Check:
- Root directory
- `wp-admin`
- `wp-includes`
- `wp-content`
- `wp-content/plugins`
- `wp-content/themes`
- `wp-content/uploads`
- `wp-content/mu-plugins`
- `wp-content/cache`
- Drop-ins
- Custom folders
- Temporary folders
- Hidden files/folders
- Old/staging copies
- Backup folders inside public directories
Look for:
- Malware
- Backdoors
- Web shells
- Malware droppers
- Remote loaders
- Obfuscated PHP
- Encoded payloads
- Injected JavaScript
- Hidden iframes
- Spam redirects
- SEO spam
- Remote command execution
- Unauthorized admin creation code
- File-writing malware
- File recreation scripts
- Suspicious external domains
- Random PHP files
- Fake images containing PHP
- Malicious `.ico` files
- Hidden executable files
- Suspicious symlinks
- Unknown loaders
---
# 4. Suspicious Code Search
Review suspicious usage of:
- `eval()`
- `assert()`
- `base64_decode()`
- `gzinflate()`
- `str_rot13()`
- `shell_exec()`
- `exec()`
- `system()`
- `passthru()`
- `proc_open()`
- `popen()`
- Dynamic function execution
- Remote `include`
- Remote `require`
- `file_put_contents()`
- `fopen()`
- `fwrite()`
- `copy()`
- `rename()`
- `touch()`
- `chmod()`
- Remote HTTP downloads
Determine whether the usage is legitimate or malicious before removing anything.
---
# 5. WordPress Core Integrity
Detect the installed WordPress version.
Verify WordPress core files against clean official WordPress checksums or official source files.
Check for:
- Modified core files
- Missing core files
- Extra PHP files inside `wp-admin`
- Extra PHP files inside `wp-includes`
- Modified root WordPress files
Restore compromised core files from clean official WordPress files.
Do not overwrite:
- `wp-config.php`
- `wp-content`
- Legitimate custom files
without reviewing them first.
---
# 6. Theme Deep Scan
Inspect every active and inactive theme.
Pay special attention to:
- `functions.php`
- `header.php`
- `footer.php`
- `index.php`
- `404.php`
- `single.php`
- `page.php`
- `inc/`
- `includes/`
- Template parts
- Theme JavaScript
- Custom PHP files
Look for:
- Injected malware
- Backdoors
- Remote loaders
- Admin creation code
- File recreation code
- Suspicious includes
- Hidden PHP files
Preserve all legitimate:
- Design
- Custom functions
- Theme options
- CSS
- JavaScript
- Template functionality
---
# 7. Plugin Deep Scan
Inspect every installed plugin.
Check for:
- Unknown plugins
- Fake plugins
- Malware plugins
- Modified plugin files
- Hidden PHP files
- Backdoors
- Remote loaders
- Nulled/cracked plugins
- Abandoned vulnerable plugins
- Extra executable files
- Malware persistence code
Where possible, compare plugin files against clean official plugin releases.
If a legitimate plugin file is infected, restore the clean official file rather than removing the entire plugin unnecessarily.
Delete confirmed malicious plugins completely.
---
# 8. MU Plugins and WordPress Drop-ins
Inspect:
`wp-content/mu-plugins/`
very carefully.
Also inspect WordPress drop-ins such as:
- `advanced-cache.php`
- `object-cache.php`
- `db.php`
- `sunrise.php`
Confirm the purpose of every file.
Look for:
- Hidden persistence
- Remote loaders
- Malware brokers
- Automatically recreated MU plugins
- Unauthorized management files
Do not assume an unknown MU plugin is malware until its source is verified.
If confirmed malicious or unauthorized:
- Delete it.
- Find what created it.
- Remove the recreation source.
---
# 9. Uploads Directory Deep Scan
Inspect:
`wp-content/uploads/`
recursively.
Look for:
- `.php`
- `.phtml`
- `.phar`
- `.php5`
- Fake image files containing PHP
- Suspicious `.ico`
- Hidden scripts
- Random executable files
Delete confirmed malicious executable files.
Preserve legitimate media.
Where safe, prevent PHP execution inside uploads.
---
# 10. Configuration File Audit
Inspect:
- `wp-config.php`
- `.htaccess`
- `.user.ini`
- `php.ini`
- Apache configuration where accessible
- PHP handler configuration
Check for:
- Injected PHP
- Unknown includes
- Remote includes
- `auto_prepend_file`
- `auto_append_file`
- Malicious redirects
- Suspicious rewrite rules
- Unauthorized PHP handlers
- Hidden execution directives
Preserve legitimate WordPress and hosting configuration.
---
# 11. Recently Modified Files
Review recently created and modified files.
Look for patterns such as:
- Many PHP files modified at the same time
- `functions.php` changing repeatedly
- `.htaccess` changing repeatedly
- Random files appearing after page loads
- MU plugins being recreated
- Hidden files created after cron execution
Use timestamps to help identify the persistence source.
---
# 12. Complete Database Deep Scan
Inspect the complete WordPress database.
Do not check only the standard tables.
Review all WordPress and plugin-created tables.
Use the actual WordPress table prefix.
Pay special attention to:
- `{prefix}_users`
- `{prefix}_usermeta`
- `{prefix}_options`
- `{prefix}_posts`
- `{prefix}_postmeta`
- `{prefix}_comments`
- `{prefix}_commentmeta`
- `{prefix}_terms`
- `{prefix}_termmeta`
- `{prefix}_term_taxonomy`
- `{prefix}_term_relationships`
- Plugin tables
- SEO tables
- Security plugin tables
- Elementor data
- Divi data
- Widgets
- Theme options
- Cron data
- Transients
- Session data
- Custom tables
---
# 13. Database Malware Search
Search for:
- Malware markers
- Backdoor configuration
- Suspicious remote URLs
- Redirect domains
- Spam URLs
- Gambling spam
- Pharmaceutical spam
- Adult spam
- Crypto spam
- Injected `