Skip to main content

CVE-2022-39342: CWE-285: Improper Authorization in openfga openfga

Medium
Published: Tue Oct 25 2022 (10/25/2022, 00:00:00 UTC)
Source: CVE
Vendor/Project: openfga
Product: openfga

Description

OpenFGA is an authorization/permission engine. Versions prior to version 0.2.4 are vulnerable to authorization bypass under certain conditions. Users whose model has a relation defined as a tupleset (the right hand side of a ‘from’ statement) that involves anything other than a direct relationship (e.g. ‘as self’) are vulnerable. Version 0.2.4 contains a patch for this issue.

AI-Powered Analysis

AILast updated: 06/22/2025, 14:53:18 UTC

Technical Analysis

CVE-2022-39342 is an authorization bypass vulnerability affecting OpenFGA, an open-source authorization and permission engine used to manage fine-grained access control. The vulnerability exists in versions prior to 0.2.4 and arises due to improper authorization checks (CWE-285) when the authorization model includes relations defined as tuplesets that involve indirect relationships rather than direct ones (e.g., 'as self'). In these cases, the engine may incorrectly grant access to users who should not have it, effectively bypassing intended authorization constraints. This flaw can lead to unauthorized access to protected resources or operations within applications relying on OpenFGA for access control. The issue was addressed in version 0.2.4 by correcting the authorization logic to properly handle complex relationship tuplesets. There are no known exploits in the wild as of the published date, and no CVSS score has been assigned. The vulnerability was publicly disclosed on October 25, 2022, and is classified as medium severity by the vendor. The improper authorization weakness can impact confidentiality and integrity by allowing unauthorized users to access or modify data or functionality they should not be permitted to. Exploitation requires the attacker to have some level of access to the system using the vulnerable OpenFGA version and to leverage the specific model configuration involving indirect relationship tuplesets. No user interaction is required beyond having access to the affected system's authorization model. The scope is limited to systems using OpenFGA versions prior to 0.2.4 with the vulnerable model configuration.

Potential Impact

For European organizations, the impact of this vulnerability depends largely on the adoption of OpenFGA within their IT environments. Organizations using OpenFGA for critical access control in applications or services may face unauthorized access risks, potentially leading to data breaches, privilege escalation, or unauthorized operations. This can compromise the confidentiality and integrity of sensitive data, disrupt business processes, and damage trust with customers and partners. Sectors such as finance, healthcare, government, and technology that rely on strict access controls are particularly at risk. Since OpenFGA is a relatively new and specialized authorization engine, the overall exposure may be limited but could grow as adoption increases. The lack of known exploits reduces immediate risk, but the presence of a patchable authorization bypass means that unpatched systems remain vulnerable to targeted attacks. The vulnerability could also be leveraged in supply chain attacks if OpenFGA is embedded in third-party software used by European organizations.

Mitigation Recommendations

European organizations should first inventory their use of OpenFGA and identify any deployments running versions prior to 0.2.4. Immediate upgrade to OpenFGA version 0.2.4 or later is the primary mitigation to remediate the vulnerability. Additionally, organizations should review their authorization models to identify any relations defined as tuplesets involving indirect relationships and validate that access control policies are correctly enforced. Implementing additional monitoring and logging around authorization decisions can help detect anomalous access patterns indicative of exploitation attempts. Where possible, apply defense-in-depth by restricting access to systems running OpenFGA to trusted users and networks. Conduct regular security assessments and penetration testing focusing on authorization logic to uncover potential bypasses. Finally, maintain awareness of updates from the OpenFGA project and related security advisories to promptly address any future vulnerabilities.

Need more detailed analysis?Get Pro

Technical Details

Data Version
5.1
Assigner Short Name
GitHub_M
Date Reserved
2022-09-02T00:00:00.000Z
Cisa Enriched
true

Threat ID: 682d9846c4522896dcbf490c

Added to database: 5/21/2025, 9:09:26 AM

Last enriched: 6/22/2025, 2:53:18 PM

Last updated: 8/18/2025, 11:28:56 PM

Views: 13

Actions

PRO

Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.

Please log in to the Console to use AI analysis features.

Need enhanced features?

Contact root@offseq.com for Pro access with improved analysis and higher rate limits.

Latest Threats