CVE-2022-21646: CWE-155: Improper Neutralization of Wildcards or Matching Symbols in authzed spicedb
SpiceDB is a database system for managing security-critical application permissions. Any user making use of a wildcard relationship under the right hand branch of an `exclusion` or within an `intersection` operation will see `Lookup`/`LookupResources` return a resource as "accessible" if it is *not* accessible by virtue of the inclusion of the wildcard in the intersection or the right side of the exclusion. In `v1.3.0`, the wildcard is ignored entirely in lookup's dispatch, resulting in the `banned` wildcard being ignored in the exclusion. Version 1.4.0 contains a patch for this issue. As a workaround, don't make use of wildcards on the right side of intersections or within exclusions.
AI Analysis
Technical Summary
CVE-2022-21646 is a vulnerability identified in SpiceDB version 1.3.0, a database system designed to manage security-critical application permissions. The flaw arises from improper neutralization of wildcards or matching symbols (CWE-155) combined with improper input validation (CWE-20). Specifically, when a user employs a wildcard relationship on the right-hand branch of an 'exclusion' or within an 'intersection' operation, the system's Lookup and LookupResources functions incorrectly return resources as accessible even if they should be excluded. This occurs because the wildcard is ignored entirely during the lookup dispatch process in version 1.3.0, causing exclusions that rely on wildcards (e.g., a 'banned' wildcard) to be bypassed. Consequently, resources that should be inaccessible due to these exclusion rules are erroneously marked as accessible, potentially granting unauthorized access. The issue was addressed in SpiceDB version 1.4.0, which contains a patch correcting the wildcard handling logic. Until upgrading, the recommended workaround is to avoid using wildcards on the right side of intersections or within exclusions to prevent this bypass. No known exploits have been reported in the wild, but the vulnerability impacts the core permission evaluation mechanism, which is critical for enforcing access controls in applications relying on SpiceDB. This flaw could lead to unauthorized data access or privilege escalation within affected systems.
Potential Impact
For European organizations utilizing SpiceDB version 1.3.0 in their permission management infrastructure, this vulnerability poses a risk of unauthorized access to sensitive resources. Since SpiceDB is often integrated into applications managing critical permissions, exploitation could lead to breaches of confidentiality by exposing protected data or unauthorized privilege escalation, undermining the integrity of access controls. The availability impact is limited, as the vulnerability does not cause denial of service but rather incorrect access decisions. Organizations in sectors with stringent data protection requirements—such as finance, healthcare, and government—may face compliance risks if unauthorized access occurs. Moreover, the incorrect permission evaluations could facilitate lateral movement within networks if attackers exploit the wildcard bypass to access restricted resources. Although no active exploitation is currently known, the flaw's presence in a security-critical component necessitates prompt remediation to maintain trust in access control mechanisms and prevent potential data breaches.
Mitigation Recommendations
European organizations should prioritize upgrading SpiceDB to version 1.4.0 or later, where the wildcard handling issue is fixed. Until an upgrade is feasible, developers and administrators must audit their use of wildcards in permission definitions, specifically avoiding wildcards on the right side of intersections or within exclusions to prevent bypass scenarios. Conduct thorough permission reviews to identify and refactor any rules that rely on such wildcard usage. Implement additional compensating controls such as enhanced logging and monitoring of permission lookup results to detect anomalous access patterns that may indicate exploitation attempts. Where possible, apply strict input validation and limit the use of complex permission expressions involving wildcards. Security teams should also integrate SpiceDB permission checks with broader identity and access management (IAM) policies to enforce defense-in-depth. Finally, maintain awareness of vendor advisories and community updates for any emerging exploit reports or patches.
Affected Countries
Germany, France, United Kingdom, Netherlands, Sweden, Finland, Denmark, Belgium, Ireland
CVE-2022-21646: CWE-155: Improper Neutralization of Wildcards or Matching Symbols in authzed spicedb
Description
SpiceDB is a database system for managing security-critical application permissions. Any user making use of a wildcard relationship under the right hand branch of an `exclusion` or within an `intersection` operation will see `Lookup`/`LookupResources` return a resource as "accessible" if it is *not* accessible by virtue of the inclusion of the wildcard in the intersection or the right side of the exclusion. In `v1.3.0`, the wildcard is ignored entirely in lookup's dispatch, resulting in the `banned` wildcard being ignored in the exclusion. Version 1.4.0 contains a patch for this issue. As a workaround, don't make use of wildcards on the right side of intersections or within exclusions.
AI-Powered Analysis
Technical Analysis
CVE-2022-21646 is a vulnerability identified in SpiceDB version 1.3.0, a database system designed to manage security-critical application permissions. The flaw arises from improper neutralization of wildcards or matching symbols (CWE-155) combined with improper input validation (CWE-20). Specifically, when a user employs a wildcard relationship on the right-hand branch of an 'exclusion' or within an 'intersection' operation, the system's Lookup and LookupResources functions incorrectly return resources as accessible even if they should be excluded. This occurs because the wildcard is ignored entirely during the lookup dispatch process in version 1.3.0, causing exclusions that rely on wildcards (e.g., a 'banned' wildcard) to be bypassed. Consequently, resources that should be inaccessible due to these exclusion rules are erroneously marked as accessible, potentially granting unauthorized access. The issue was addressed in SpiceDB version 1.4.0, which contains a patch correcting the wildcard handling logic. Until upgrading, the recommended workaround is to avoid using wildcards on the right side of intersections or within exclusions to prevent this bypass. No known exploits have been reported in the wild, but the vulnerability impacts the core permission evaluation mechanism, which is critical for enforcing access controls in applications relying on SpiceDB. This flaw could lead to unauthorized data access or privilege escalation within affected systems.
Potential Impact
For European organizations utilizing SpiceDB version 1.3.0 in their permission management infrastructure, this vulnerability poses a risk of unauthorized access to sensitive resources. Since SpiceDB is often integrated into applications managing critical permissions, exploitation could lead to breaches of confidentiality by exposing protected data or unauthorized privilege escalation, undermining the integrity of access controls. The availability impact is limited, as the vulnerability does not cause denial of service but rather incorrect access decisions. Organizations in sectors with stringent data protection requirements—such as finance, healthcare, and government—may face compliance risks if unauthorized access occurs. Moreover, the incorrect permission evaluations could facilitate lateral movement within networks if attackers exploit the wildcard bypass to access restricted resources. Although no active exploitation is currently known, the flaw's presence in a security-critical component necessitates prompt remediation to maintain trust in access control mechanisms and prevent potential data breaches.
Mitigation Recommendations
European organizations should prioritize upgrading SpiceDB to version 1.4.0 or later, where the wildcard handling issue is fixed. Until an upgrade is feasible, developers and administrators must audit their use of wildcards in permission definitions, specifically avoiding wildcards on the right side of intersections or within exclusions to prevent bypass scenarios. Conduct thorough permission reviews to identify and refactor any rules that rely on such wildcard usage. Implement additional compensating controls such as enhanced logging and monitoring of permission lookup results to detect anomalous access patterns that may indicate exploitation attempts. Where possible, apply strict input validation and limit the use of complex permission expressions involving wildcards. Security teams should also integrate SpiceDB permission checks with broader identity and access management (IAM) policies to enforce defense-in-depth. Finally, maintain awareness of vendor advisories and community updates for any emerging exploit reports or patches.
Affected Countries
For access to advanced analysis and higher rate limits, contact root@offseq.com
Technical Details
- Data Version
- 5.1
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2021-11-16T00:00:00.000Z
- Cisa Enriched
- true
Threat ID: 682d9842c4522896dcbf2217
Added to database: 5/21/2025, 9:09:22 AM
Last enriched: 6/23/2025, 6:48:59 PM
Last updated: 8/5/2025, 10:03:52 AM
Views: 13
Related Threats
CVE-2025-9091: Hard-coded Credentials in Tenda AC20
LowCVE-2025-9090: Command Injection in Tenda AC20
MediumCVE-2025-9092: CWE-400 Uncontrolled Resource Consumption in Legion of the Bouncy Castle Inc. Bouncy Castle for Java - BC-FJA 2.1.0
LowCVE-2025-9089: Stack-based Buffer Overflow in Tenda AC20
HighCVE-2025-9088: Stack-based Buffer Overflow in Tenda AC20
HighActions
Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.
External Links
Need enhanced features?
Contact root@offseq.com for Pro access with improved analysis and higher rate limits.