<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Daptin — CraftedSignal Threat Feed</title><link>https://feed.craftedsignal.io/tags/daptin/</link><description>Trending threats, MITRE ATT&amp;CK coverage, and detection metadata — refreshed continuously.</description><generator>Hugo</generator><language>en</language><managingEditor>hello@craftedsignal.io</managingEditor><webMaster>hello@craftedsignal.io</webMaster><lastBuildDate>Wed, 06 May 2026 22:10:11 +0000</lastBuildDate><atom:link href="https://feed.craftedsignal.io/tags/daptin/feed.xml" rel="self" type="application/rss+xml"/><item><title>Daptin SQL Injection Vulnerability via Fuzzy Search</title><link>https://feed.craftedsignal.io/briefs/2024-01-daptin-sqli/</link><pubDate>Wed, 06 May 2026 22:10:11 +0000</pubDate><author>hello@craftedsignal.io</author><guid isPermaLink="true">https://feed.craftedsignal.io/briefs/2024-01-daptin-sqli/</guid><description>Daptin versions up to 0.11.4 are vulnerable to SQL injection, where an authenticated user can inject unvalidated column names into raw SQL via the `processFuzzySearch` function, allowing them to read the entire database.</description><content:encoded><![CDATA[<p>Daptin versions up to and including 0.11.4 are susceptible to a SQL injection vulnerability within the <code>processFuzzySearch</code> function located in <code>server/resource/resource_findallpaginated.go</code>. This flaw allows any authenticated user, including those self-registered without administrative oversight, to inject arbitrary SQL commands by manipulating the <code>column</code> parameter during a fuzzy search. Specifically, when a GET request is made to <code>/api/&lt;entity&gt;</code> with the <code>operator</code> set to <code>fuzzy</code>, <code>fuzzy_any</code>, or <code>fuzzy_all</code>, the application fails to properly sanitize the column name before incorporating it into a raw SQL query. This vulnerability enables malicious actors to bypass column whitelists, potentially granting them unauthorized access to sensitive data within the entire database. The issue is distinct from the vulnerability patched in GHSA-rw2c-8rfq-gwfv and requires a separate patch to address the vulnerable fuzzy search path.</p>
<h2 id="attack-chain">Attack Chain</h2>
<ol>
<li>An attacker registers a new user account, leveraging the default self-signup feature which requires no admin approval.</li>
<li>The attacker authenticates with the newly created account to obtain a valid JWT (JSON Web Token).</li>
<li>The attacker crafts a malicious HTTP GET request to <code>/api/&lt;entity&gt;</code>, setting the <code>operator</code> parameter to <code>fuzzy</code> (or <code>fuzzy_any</code>, <code>fuzzy_all</code>).</li>
<li>The attacker injects a SQL payload into the <code>column</code> parameter using string formatting. For example: <code>reference_id) OR 1=1 OR LOWER(world.reference_id</code>.</li>
<li>The crafted <code>column</code> parameter bypasses the column name whitelist check due to the execution path going through <code>processFuzzySearch</code> instead of <code>processQueryFilter</code>.</li>
<li>The injected SQL payload is passed to <code>goqu.L</code>, which incorporates it directly into a raw SQL query without proper sanitization.</li>
<li>The database executes the malicious SQL query, potentially leaking sensitive information or allowing for data manipulation.</li>
<li>The attacker extracts data using boolean-blind SQL injection, exploiting the vulnerability to read data from all tables within the database, including credential data (emails, bcrypt password hashes) in the <code>user_account</code> table.</li>
</ol>
<h2 id="impact">Impact</h2>
<p>Successful exploitation of this vulnerability allows an attacker with only a valid JWT to read the entire database via boolean-blind extraction. This includes sensitive information such as user credentials (emails and bcrypt password hashes). The self-signup feature of Daptin means that no administrative involvement is needed for an attacker to create an account and exploit this vulnerability.  The extraction rate is approximately 7 HTTP requests per character, making full database extraction feasible.</p>
<h2 id="recommendation">Recommendation</h2>
<ul>
<li>Apply the patch that adds a <code>GetColumnByName</code> whitelist check in <code>processFuzzySearch</code> (line 1484) to prevent SQL injection via the <code>column</code> parameter.</li>
<li>Implement input validation and sanitization for the <code>column</code> parameter in the <code>processFuzzySearch</code> function to prevent the injection of arbitrary SQL commands.</li>
<li>Deploy the Sigma rule &ldquo;Daptin Suspicious Fuzzy Search Query&rdquo; to detect potential exploitation attempts based on the presence of SQL syntax in the <code>query</code> parameter of HTTP requests to the <code>/api/&lt;entity&gt;</code> endpoint.</li>
<li>Monitor web server logs (logsource: webserver) for requests to <code>/api/world</code> or other entities that include the <code>fuzzy</code> operator and contain suspicious characters or SQL syntax in the <code>query</code> parameter, as detected by the &ldquo;Daptin Suspicious Fuzzy Search Query&rdquo; rule.</li>
</ul>
]]></content:encoded><category domain="severity">critical</category><category domain="type">advisory</category><category>sqli</category><category>daptin</category><category>github</category><category>fuzzy-search</category></item></channel></rss>