Am I affected?

type your ash_admin version to check

Description

Authorization Bypass Through User-Controlled Key vulnerability in ash-project ash_admin turns a record-lookup URL into an equality oracle over sensitive attributes.

AshAdmin.Helpers.decode_primary_key/2 decodes the composite-primary-key form (Base64 plus ETF) and returns the decoded map verbatim as the lookup filter, without checking that its keys are the resource's primary-key fields. The deserialization guards bound size, block new atoms and funs, and reject nested expressions, but none restricts which fields come back, and :safe still allows any already-interned attribute name. An attacker can therefore encode %{api_token: "guess"} and have it spliced into the lookup filter, brute-forcing a sensitive attribute value (API token, reset token) one equality guess at a time; Map.to_list/1 also accepts structs, yielding a bogus __struct__ key. The fix rejects any decoded key that is not a real primary-key field.

This issue affects ash_admin: from 0.1.0 before 1.3.1.

Weaknesses & attack patterns

Weakness

CWE-639 · Authorization Bypass Through User-Controlled Key in catalog → MITRE ↗

Attack patterns

CAPEC-77 · Manipulating User-Controlled Variables MITRE ↗

Affected — Hex / ash_admin Hex.pm ↗ Repository ↗

≥ 0.1.0 < 1.3.1 affected
every other version: unaffected
cpe cpe:2.3:a:ash-project:ash_admin:*:*:*:*:*:*:*:*
version type semver
modules · source files · routines
modules 'Elixir.AshAdmin.Helpers'
source files lib/ash_admin/helpers.ex
routines 'Elixir.AshAdmin.Helpers':decode_primary_key/2

Affected — GitHub / ash-project/ash_admin Repository ↗

≥ 98b03ba < 3c3e905 affected
every other version: unaffected
cpe cpe:2.3:a:ash-project:ash_admin:*:*:*:*:*:*:*:*
version type git
modules · source files · routines
modules 'Elixir.AshAdmin.Helpers'
source files lib/ash_admin/helpers.ex
routines 'Elixir.AshAdmin.Helpers':decode_primary_key/2

Configurations

The resource has a composite primary key, and the deployment relies on AshAdmin's authorization (a custom actor plug and policies) so that reading otherwise-restricted attribute values crosses a boundary.

References

Credits

Peter Ullrich Finder Reporter
Jonatan Männchen / EEF Coordinator
Zach Daniel / Ash Project Remediation developer

CVSS breakdown

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

Exploitability

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
Present
Privileges Required
Low
User Interaction
None

Vulnerable System

Confidentiality
Low
Integrity
None
Availability
None

Subsequent Systems

Confidentiality
None
Integrity
None
Availability
None
« All CVEs