Skip to content

EEF-CVE-2026-80227 CVE-2026-80227 GHSA-76wx-w7ww-5xfq

SQL string_trim removes only spaces, diverging from in-memory trimming in AshSql

Not rated yet Hex
Severity
0.0 / 10
Unknown · CVSS 4.0
Exploit chance (EPSS)
0.37%
Chance of exploitation in the next 30 days. Higher than 30.55% of scored vulnerabilities.
Known exploited
No
Not in CISA's catalog
Weakness
CWE-697 Incorrect Comparison
Fix
0.7.1
Upgrade ash_sql to this version or later

Description

Summary

Incorrect Comparison vulnerability in ash-project ash_sql allows a user to pad a string field with tab, newline, carriage-return, or form-feed characters and pass a trimmed uniqueness or equality check in the database that the same expression would fail in memory (or the reverse).

string_trim/1 compiles to REGEXP_REPLACE patterns built from an Elixir string in which \s is the escape for a single space (codepoint 32), not a regex whitespace class. The generated SQL therefore removes only literal spaces and leaves tabs, newlines, carriage returns, and form feeds in place, whereas String.trim/1 in Elixir removes them all. Any Ash filter, validation, or identity that relies on string_trim/1 then behaves differently depending on whether Ash pushes the expression down to SQL or evaluates it in memory, so padded input can register a near-duplicate value or slip past a trimmed comparison.

This issue affects ash_sql: from 0.1.0 before 0.7.1.

Configurations

An application must use string_trim/1 in a filter, validation, calculation, or identity that an attacker-influenced string field flows through, where the trimmed value is compared for equality or uniqueness.

Affected versions

Hex

PackageVulnerableFixed in
ash_sql
>= 0.1.0, < 0.7.1
0.7.1

How to fix

Move to the fixed version or later with your package manager, update the lockfile, and run your tests. If the package only arrives through another dependency, upgrade that dependency first. If none of its releases pulls a fixed version yet, force the version with your package manager's override.

ash_sql Hex → 0.7.1

mix
{:ash_sql, "~> 0.7.1"} # then: mix deps.update ash_sql

Severity breakdown

CVSS 4.0 0.0

CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N

Attack vector
Local
Attack complexity
Low
Attack requirements
Present
Privileges required
None
User interaction
None
Confidentiality (vulnerable system)
None
Integrity (vulnerable system)
Low
Availability (vulnerable system)
None
Confidentiality (subsequent systems)
None
Integrity (subsequent systems)
None
Availability (subsequent systems)
None

Weakness

CWE-697: Incorrect Comparison

The product compares two entities in a security-relevant context, but the comparison is incorrect.

References

Timeline

  1. Published
  2. Last updated by the source
  3. Latest EPSS score
AdvisorySeverityWhy it's related
EEF-CVE-2026-77454
exists/2 predicate silently dropped on limited relationships with a parent() filter in AshSql
Not rated yet Also affects ash_sql
EEF-CVE-2026-81316
Same-named aggregates with differing filters are conflated in AshSql
Not rated yet Also affects ash_sql
EEF-CVE-2026-81318
Distinct-query aggregate drops the tenant schema prefix, leaking across tenants in AshSql
Not rated yet Also affects ash_sql
EEF-CVE-2026-78691
Unescaped backslash allows LIKE wildcard injection in AshSql string search
Not rated yet Also affects ash_sql
GHSA-rpw4-54j3-4h4q
ip-address: Address6.isLinkLocal() recognizes fe80::/64 rather than fe80::/10, allowing SSRF and trust-boundary bypass to on-link hosts
Medium Same weakness, CWE-697
GHSA-j6r3-76f7-8jcv
ip-address: isInSubnet() and isHostInSubnet() compare addresses of different families as if they shared an address space, allowing an allowlist check to admit an address outside its range
Medium Same weakness, CWE-697
GHSA-jqcg-44mw-7w3h
proxy-addr vulnerable to IP spoofing via IPv4-mapped IPv6 trust subnet
Critical Same weakness, CWE-697
GHSA-39q2-94rc-95cp
DOMPurify's ADD_TAGS function form bypasses FORBID_TAGS due to short-circuit evaluation
Medium Same weakness, CWE-697

Credits: Jonatan Männchen / EEF, Peter Ullrich, Zach Daniel / Ash Project

Is this in your code?

MergeHarbor checks every repository's dependencies against this database, ranks what matters by exploitability and reachability, routes it to the owning team and opens the fix pull request.

Check your repos with MergeHarbor