{"id":"CVE-2026-46645","aliases":["CVE-2026-46645","GHSA-54mc-gghv-4cfj","PYSEC-2026-3073"],"related":[],"kind":"vulnerability","state":"published","title":"SQLAdmin: Authorization Bypass on `ajax_lookup`","summary":"SQLAdmin is a flexible Admin interface for SQLAlchemy models. Prior to version 0.25.1, the ajax_lookup endpoint in application.py bypasses the is_accessible() access control check that all other endpoints enforce. If a developer restricts model access by overriding is_accessible(), an authenticated user can still query that model's data through the ajax_lookup endpoint — silently bypassing the restriction. This issue has been patched in version 0.25.1.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"SQLAdmin is a flexible Admin interface for SQLAlchemy models. Prior to version 0.25.1, the ajax_lookup endpoint in application.py bypasses the is_accessible() access control check that all other endpoints enforce. If a developer restricts model access by overriding is_accessible(), an authenticated user can still query that model's data through the ajax_lookup endpoint — silently bypassing the restriction. This issue has been patched in version 0.25.1.","source":"cvelist"},{"lang":"en","text":"### Impact\n\nThe `ajax_lookup` endpoint in `application.py` bypasses the `is_accessible()` access control check that all other endpoints enforce.\n\nIf a developer restricts model access by overriding `is_accessible()`, an authenticated user can still query that model's data through the `ajax_lookup` endpoint — silently bypassing the restriction.\n\n**Affected endpoint:**\n\n`GET /{identity}/ajax/lookup?name=<field>&term=<query>`\n\n**All other endpoints enforce both checks:**\n\n| Endpoint | `@login_required` | `is_accessible()` |\n|---|---|---|\n| `list` | ✓ | ✓ |\n| `create` | ✓ | ✓ |\n| `edit` | ✓ | ✓ |\n| `delete` | ✓ | ✓ |\n| `details` | ✓ | ✓ |\n| `export` | ✓ | ✓ |\n| `ajax_lookup` (before fix) | ✗ | ✗ |\n| `ajax_lookup` (after fix) | ✓ | ✓ |\n\nNote: before this fix, `ajax_lookup` also lacked the `@login_required` decorator — unauthenticated users could query it directly. That was addressed in #1035. This report covers the remaining gap: authenticated but unauthorized users.\n\n### Patches\n\nTwo changes were made to `ajax_lookup`:\n\n1. Replaced the hand-rolled authentication check added in #1035 with the standard `@login_required` decorator used by all other endpoints.\n2. Added the missing `is_accessible(request)` check, raising `HTTP 403` when it returns `False`.\n\n### Workarounds\n\nNone. Developers relying on `is_accessible()` to restrict model visibility are exposed regardless of what other access controls are in place.","format":"markdown","source":"ghsa"},{"lang":"es","text":"SQLAdmin es una interfaz de administración flexible para modelos de SQLAlchemy. Antes de la versión 0.25.1, el endpoint ajax_lookup en application.py omite la verificación de control de acceso is_accessible() que todos los demás endpoints aplican. Si un desarrollador restringe el acceso a un modelo al sobrescribir is_accessible(), un usuario autenticado aún puede consultar los datos de ese modelo a través del endpoint ajax_lookup - eludiendo silenciosamente la restricción. Este problema ha sido parcheado en la versión 0.25.1.","source":"nvd"}],"published":"2026-05-21T21:31:40.000Z","modified":"2026-07-23T09:10:00.113Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N","score":4.3,"rating":"MEDIUM"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N","score":4.3,"rating":"MEDIUM"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N","score":4.3,"rating":"MEDIUM"},{"scorer":"PyPA Advisory Database","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N","score":4.3,"rating":"MEDIUM"}],"cwes":["CWE-862"],"affected":[{"ranges":[{"version":"< 0.25.1","status":"affected"}],"vendor":"smithyhq","product":"sqladmin","source":"cvelist"},{"ranges":[{"type":"ecosystem","introduced":"0","status":"affected","fixed":"0.25.1"}],"ecosystem":"PyPI","package":"sqladmin","purl":"pkg:pypi/sqladmin","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"0","status":"affected","fixed":"0.25.1"}],"ecosystem":"PyPI","package":"sqladmin","purl":"pkg:pypi/sqladmin","source":"pysec"}],"references":[{"url":"https://github.com/smithyhq/sqladmin/security/advisories/GHSA-54mc-gghv-4cfj","tags":["web","x-refsource-confirm"],"sources":["cvelist","ghsa","nvd","pysec"]},{"url":"https://github.com/smithyhq/sqladmin/pull/1035","tags":["web","x-refsource-misc"],"sources":["cvelist","ghsa","nvd","pysec"]},{"url":"https://github.com/smithyhq/sqladmin/commit/b0d3a19fb9b074a9ed243de46930108375dfbb98","tags":["web","x-refsource-misc"],"sources":["cvelist","ghsa","nvd","pysec"]},{"url":"https://github.com/smithyhq/sqladmin/releases/tag/0.25.1","tags":["web","x-refsource-misc"],"sources":["cvelist","ghsa","nvd","pysec"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-46645","tags":["advisory"],"sources":["ghsa","pysec"]},{"url":"https://github.com/smithyhq/sqladmin","tags":["package"],"sources":["ghsa","pysec"]},{"url":"https://pypi.org/project/sqladmin","tags":["package"],"sources":["pysec"]},{"url":"https://github.com/advisories/GHSA-54mc-gghv-4cfj","tags":["advisory"],"sources":["pysec"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2026-06-11T14:49:02.169Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-46645","url":"https://www.cve.org/CVERecord?id=CVE-2026-46645","licence":"CVE Terms of Use","modified":"2026-06-11T16:14:04.832Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-54mc-gghv-4cfj","url":"https://github.com/advisories/GHSA-54mc-gghv-4cfj","licence":"CC-BY-4.0","modified":"2026-07-13T16:42:34.470Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-46645","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-46645","licence":"Public domain","modified":"2026-07-23T09:10:00.113Z"},{"source":"pysec","name":"PyPA Advisory Database","id":"PYSEC-2026-3073","url":"https://osv.dev/vulnerability/PYSEC-2026-3073","licence":"CC-BY-4.0","modified":"2026-07-13T16:33:12.404Z"}],"updatedAt":"2026-11-25T22:59:24.393Z","epss":{"score":0.00279,"percentile":0.21836,"date":"2026-12-01T12:00:22.000Z"}}