CWE-269
DiscouragedImproper Privilege Management
Abstraction: Class · Status: Draft
The product does not properly assign, modify, track, or check privileges for an actor, creating an unintended sphere of control for that actor.
6082 vulnerabilities reference this CWE, most recent first.
GHSA-2FMP-MW85-GXQW
Vulnerability from github – Published: 2023-11-28 03:30 – Updated: 2023-11-28 03:30An improper privilege management vulnerability in the ZySH of the Zyxel ATP series firmware versions 4.32 through 5.37, USG FLEX series firmware versions 4.50 through 5.37, USG FLEX 50(W) series firmware versions 4.16 through 5.37, USG20(W)-VPN series firmware versions 4.16 through 5.37, and VPN series firmware versions 4.30 through 5.37, could allow an authenticated local attacker to modify the URL of the registration page in the web GUI of an affected device.
{
"affected": [],
"aliases": [
"CVE-2023-5650"
],
"database_specific": {
"cwe_ids": [
"CWE-269"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2023-11-28T02:15:43Z",
"severity": "MODERATE"
},
"details": "An improper privilege management vulnerability in the ZySH of the Zyxel ATP series firmware versions 4.32 through 5.37, USG FLEX series firmware versions 4.50 through 5.37, USG FLEX 50(W) series firmware versions 4.16 through 5.37, USG20(W)-VPN series firmware versions 4.16 through 5.37, and VPN series firmware versions 4.30 through 5.37, could allow an authenticated local attacker to modify the URL of the registration page in the web GUI of an affected device.",
"id": "GHSA-2fmp-mw85-gxqw",
"modified": "2023-11-28T03:30:22Z",
"published": "2023-11-28T03:30:22Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2023-5650"
},
{
"type": "WEB",
"url": "https://www.zyxel.com/global/en/support/security-advisories/zyxel-security-advisory-for-multiple-vulnerabilities-in-firewalls-and-aps"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N",
"type": "CVSS_V3"
}
]
}
GHSA-2FP9-FVCR-FJ52
Vulnerability from github – Published: 2023-02-01 06:30 – Updated: 2023-02-08 15:30Dell PowerScale OneFS 9.0.0.x - 9.4.0.x, contains an Improper Handling of Insufficient Privileges vulnerability in NFS. A remote unauthenticated attacker could potentially exploit this vulnerability, leading to information disclosure and remote execution.
{
"affected": [],
"aliases": [
"CVE-2022-45101"
],
"database_specific": {
"cwe_ids": [
"CWE-269"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2023-02-01T05:15:00Z",
"severity": "CRITICAL"
},
"details": "Dell PowerScale OneFS 9.0.0.x - 9.4.0.x, contains an Improper Handling of Insufficient Privileges vulnerability in NFS. A remote unauthenticated attacker could potentially exploit this vulnerability, leading to information disclosure and remote execution.",
"id": "GHSA-2fp9-fvcr-fj52",
"modified": "2023-02-08T15:30:32Z",
"published": "2023-02-01T06:30:29Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2022-45101"
},
{
"type": "WEB",
"url": "https://www.dell.com/support/kbdoc/en-us/000206357/dell-emc-powerscale-onefs-security-updates-for-multiple-security-vulnerabilities"
}
],
"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:H",
"type": "CVSS_V3"
}
]
}
GHSA-2FQH-MW2Q-WR69
Vulnerability from github – Published: 2022-05-24 17:22 – Updated: 2022-07-13 00:00HylaFAX+ through 7.0.2 and HylaFAX Enterprise have scripts that execute binaries from directories writable by unprivileged users (e.g., locations under /var/spool/hylafax that are writable by the uucp account). This allows these users to execute code in the context of the user calling these binaries (often root).
{
"affected": [],
"aliases": [
"CVE-2020-15397"
],
"database_specific": {
"cwe_ids": [
"CWE-269"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2020-06-30T12:15:00Z",
"severity": "HIGH"
},
"details": "HylaFAX+ through 7.0.2 and HylaFAX Enterprise have scripts that execute binaries from directories writable by unprivileged users (e.g., locations under /var/spool/hylafax that are writable by the uucp account). This allows these users to execute code in the context of the user calling these binaries (often root).",
"id": "GHSA-2fqh-mw2q-wr69",
"modified": "2022-07-13T00:00:43Z",
"published": "2022-05-24T17:22:06Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2020-15397"
},
{
"type": "WEB",
"url": "https://bugzilla.suse.com/show_bug.cgi?id=1173519"
},
{
"type": "WEB",
"url": "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/J52QFVREJWJ35YSEEDDRMZQ2LM2H2WE6"
},
{
"type": "WEB",
"url": "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/Y46FOVJUS5SO44A2VEKR7DXEHTI4WK5L"
},
{
"type": "WEB",
"url": "https://security.gentoo.org/glsa/202007-06"
},
{
"type": "WEB",
"url": "https://sourceforge.net/p/hylafax/HylaFAX+/2534"
},
{
"type": "WEB",
"url": "http://lists.opensuse.org/opensuse-security-announce/2020-08/msg00039.html"
},
{
"type": "WEB",
"url": "http://lists.opensuse.org/opensuse-security-announce/2020-08/msg00040.html"
},
{
"type": "WEB",
"url": "http://lists.opensuse.org/opensuse-security-announce/2020-08/msg00046.html"
},
{
"type": "WEB",
"url": "http://lists.opensuse.org/opensuse-security-announce/2020-09/msg00054.html"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-2FR6-WPCJ-W435
Vulnerability from github – Published: 2026-08-21 00:31 – Updated: 2026-08-21 00:31IBM AIX 7.2, and 7.3 and IBM PowerVM VIOS 4.1 could allow a remote attacker to execute arbitrary code due to improper privilege management.
{
"affected": [],
"aliases": [
"CVE-2026-17145"
],
"database_specific": {
"cwe_ids": [
"CWE-269"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2026-08-20T22:17:13Z",
"severity": "CRITICAL"
},
"details": "IBM AIX 7.2, and 7.3 and IBM PowerVM VIOS 4.1 could allow a remote attacker to execute arbitrary code due to improper privilege management.",
"id": "GHSA-2fr6-wpcj-w435",
"modified": "2026-08-21T00:31:20Z",
"published": "2026-08-21T00:31:20Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-17145"
},
{
"type": "WEB",
"url": "https://www.ibm.com/support/pages/node/7283858"
}
],
"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:H",
"type": "CVSS_V3"
}
]
}
GHSA-2FX8-GX73-P72F
Vulnerability from github – Published: 2022-05-24 17:33 – Updated: 2023-12-31 21:30DirectX Elevation of Privilege Vulnerability
{
"affected": [],
"aliases": [
"CVE-2020-16998"
],
"database_specific": {
"cwe_ids": [
"CWE-269"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2020-11-11T07:15:00Z",
"severity": "HIGH"
},
"details": "DirectX Elevation of Privilege Vulnerability",
"id": "GHSA-2fx8-gx73-p72f",
"modified": "2023-12-31T21:30:24Z",
"published": "2022-05-24T17:33:40Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2020-16998"
},
{
"type": "WEB",
"url": "https://portal.msrc.microsoft.com/en-US/security-guidance/advisory/CVE-2020-16998"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-2G29-VVH2-XX4W
Vulnerability from github – Published: 2023-07-18 21:30 – Updated: 2024-04-04 06:15Vulnerability in the Oracle Solaris product of Oracle Systems (component: Device Driver Interface). The supported version that is affected is 11. Easily exploitable vulnerability allows low privileged attacker with logon to the infrastructure where Oracle Solaris executes to compromise Oracle Solaris. Successful attacks of this vulnerability can result in takeover of Oracle Solaris. Note: CVE-2023-22023 is equivalent to CVE-2023-31284. CVSS 3.1 Base Score 7.8 (Confidentiality, Integrity and Availability impacts). CVSS Vector: (CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H).
{
"affected": [],
"aliases": [
"CVE-2023-22023"
],
"database_specific": {
"cwe_ids": [
"CWE-269"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2023-07-18T21:15:13Z",
"severity": "HIGH"
},
"details": "Vulnerability in the Oracle Solaris product of Oracle Systems (component: Device Driver Interface). The supported version that is affected is 11. Easily exploitable vulnerability allows low privileged attacker with logon to the infrastructure where Oracle Solaris executes to compromise Oracle Solaris. Successful attacks of this vulnerability can result in takeover of Oracle Solaris. Note: CVE-2023-22023 is equivalent to CVE-2023-31284. CVSS 3.1 Base Score 7.8 (Confidentiality, Integrity and Availability impacts). CVSS Vector: (CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H).",
"id": "GHSA-2g29-vvh2-xx4w",
"modified": "2024-04-04T06:15:41Z",
"published": "2023-07-18T21:30:37Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2023-22023"
},
{
"type": "WEB",
"url": "https://www.oracle.com/security-alerts/cpujul2023.html"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-2G49-FR8W-J923
Vulnerability from github – Published: 2025-04-01 12:30 – Updated: 2025-04-01 12:30The WP RealEstate plugin for WordPress, used by the Homeo theme, is vulnerable to authentication bypass in all versions up to, and including, 1.6.26. This is due to insufficient role restrictions in the 'process_register' function. This makes it possible for unauthenticated attackers to register an account with the Administrator role.
{
"affected": [],
"aliases": [
"CVE-2025-2237"
],
"database_specific": {
"cwe_ids": [
"CWE-269"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2025-04-01T12:15:15Z",
"severity": "CRITICAL"
},
"details": "The WP RealEstate plugin for WordPress, used by the Homeo theme, is vulnerable to authentication bypass in all versions up to, and including, 1.6.26. This is due to insufficient role restrictions in the \u0027process_register\u0027 function. This makes it possible for unauthenticated attackers to register an account with the Administrator role.",
"id": "GHSA-2g49-fr8w-j923",
"modified": "2025-04-01T12:30:34Z",
"published": "2025-04-01T12:30:34Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2025-2237"
},
{
"type": "WEB",
"url": "https://themeforest.net/item/homeo-real-estate-wordpress-theme/26372986#item-description__updates-history"
},
{
"type": "WEB",
"url": "https://www.wordfence.com/threat-intel/vulnerabilities/id/f6f7bff6-3bc3-4572-97fd-a039d54ac0ff?source=cve"
}
],
"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:H",
"type": "CVSS_V3"
}
]
}
GHSA-2G6P-35QG-P778
Vulnerability from github – Published: 2022-05-24 17:27 – Updated: 2022-05-24 17:27An issue was discovered on LG mobile devices with Android OS 9 and 10 software. LGTelephonyProvider allows a bypass of intended privilege restrictions. The LG ID is LVE-SMP-200017 (July 2020).
{
"affected": [],
"aliases": [
"CVE-2020-25062"
],
"database_specific": {
"cwe_ids": [
"CWE-269"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2020-08-31T21:15:00Z",
"severity": "HIGH"
},
"details": "An issue was discovered on LG mobile devices with Android OS 9 and 10 software. LGTelephonyProvider allows a bypass of intended privilege restrictions. The LG ID is LVE-SMP-200017 (July 2020).",
"id": "GHSA-2g6p-35qg-p778",
"modified": "2022-05-24T17:27:03Z",
"published": "2022-05-24T17:27:03Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2020-25062"
},
{
"type": "WEB",
"url": "https://lgsecurity.lge.com"
}
],
"schema_version": "1.4.0",
"severity": []
}
GHSA-2GC6-XPQ3-F7GM
Vulnerability from github – Published: 2022-04-23 00:03 – Updated: 2022-05-11 00:02A potential vulnerability in the SMI callback function used in the NVME driver in some Lenovo Desktop, ThinkStation, and ThinkEdge models may allow an attacker with local access and elevated privileges to execute arbitrary code.
{
"affected": [],
"aliases": [
"CVE-2021-4210"
],
"database_specific": {
"cwe_ids": [
"CWE-269"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2022-04-22T21:15:00Z",
"severity": "HIGH"
},
"details": "A potential vulnerability in the SMI callback function used in the NVME driver in some Lenovo Desktop, ThinkStation, and ThinkEdge models may allow an attacker with local access and elevated privileges to execute arbitrary code.",
"id": "GHSA-2gc6-xpq3-f7gm",
"modified": "2022-05-11T00:02:09Z",
"published": "2022-04-23T00:03:00Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2021-4210"
},
{
"type": "WEB",
"url": "https://support.lenovo.com/us/en/product_security/LEN-77639"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-2GH4-JMWQ-RR8W
Vulnerability from github – Published: 2026-08-28 18:14 – Updated: 2026-08-28 18:14Summary
piccolo_admin uses a helper called superuser_validators to gate access to the user and session tables for non-superusers. The helper rejects PUT, PATCH, DELETE, and POST, but does not reject GET.
The sessions table stores live session tokens in plaintext, and the token column is not marked secret=True, so it is included in every GET response. Any non-superuser admin can therefore list every other user's live session token with one request, replay the token as their own Cookie: id=…, impersonate that user (including the superuser), and then permanently self-promote by writing superuser = true on their own row.
The chain is reachable on a realistic, documented configuration: a deployer adds the Sessions (and User) tables to create_admin([...]) so superusers have a UI to monitor and revoke sessions.
Affected component
- File:
piccolo_admin/endpoints.py - Function:
superuser_validators(around line 419)
def superuser_validators(piccolo_crud: PiccoloCRUD, request: Request):
user: BaseUser = request.user.user
if not user.superuser:
if request.method.upper() in ["PUT", "PATCH", "DELETE", "POST"]:
raise HTTPException(
detail="Only superusers can perform these actions.",
status_code=405,
)
The method check is a deny-list instead of an allow-list; GET is absent. Compounding the issue, SessionsBase.token in piccolo_api/session_auth/tables.py is a Varchar without secret=True, so the default exclude_secrets=True in PiccoloCRUD does not strip it.
Preconditions
- Network reachability to the admin.
- Valid credentials for a non-superuser admin (
admin=True, superuser=False— the default role created byBaseUser.create_user(admin=True)). - The deployment includes the
Sessionstable (and typically theUsertable) increate_admin([...])— the documented pattern for "active sessions" management UIs.
Steps to reproduce
-
Log in as the non-superuser admin (
john / john123). Open the Piccolo User table and confirm john'sSUPERUSERcolumn is ✗. (See Screenshot 1.) -
Attempt the target write directly. Send the following request:
```http PATCH /api/tables/piccolo_user/2/ HTTP/1.1 Host: target:8001 Content-Type: application/json Cookie: id=; csrftoken= X-CSRFToken:
{"superuser": true} ```
The server returns:
HTTP/1.1 405
{"detail":"Only superusers can perform these actions."}
The same response is shown both in the dashboard banner (Screenshot 2) and in Burp Repeater (Screenshot 3). This establishes the privilege boundary that the bug will break.
- Leak the credential. As the same john user, request:
http
GET /api/tables/sessions/ HTTP/1.1
Host: target:8001
Cookie: id=<john's session>; csrftoken=<token>
Response: 200 OK containing every active session in plaintext, e.g.
json
{"rows":[
{"token":"jeb1d-IXIC0BWTOV6G-ApTksrbvdBDkZV9KN4taN2nE","user_id":1, ...},
{"token":"...","user_id":2, ...},
...
]}
Copy the token value of any row whose user_id matches the superuser. That string IS the live session cookie of that user. (Screenshot 4.)
- Replay the step-2 PATCH with the stolen cookie. Send the exact same request as step 2, changing only the
Cookie: id=value to the stolen token:
```http PATCH /api/tables/piccolo_user/2/ HTTP/1.1 Host: target:8001 Content-Type: application/json Cookie: id=jeb1d-IXIC0BWTOV6G-ApTksrbvdBDkZV9KN4taN2nE; csrftoken= X-CSRFToken:
{"superuser": true} ```
Response: 200 OK, body shows "superuser": true for john. (Screenshot 5.)
- Verify persistence. Log in fresh as
john / john123(no stolen cookie). John is now a superuser. The stolen cookie is no longer needed — the elevation is permanent on john's own row.
Impact
Full superuser takeover of the admin from any non-superuser admin account. The promoted attacker can:
- read/write/delete any row in any table the admin exposes;
- revoke any other session, locking out other admins;
- change any user's password;
- export data (including via the bulk CSV download forms);
- plant payloads (e.g. CSV-formula injections) that fire when higher-trust operators open exports.
Persistence is automatic — once the attacker writes superuser=true on their own row in step 4, the stolen cookie can be discarded.
Suggested fix
Primary (single-line): make superuser_validators reject all requests from non-superusers — there is no legitimate non-superuser use case for the user or session tables in this context:
def superuser_validators(piccolo_crud, request):
if not request.user.user.superuser:
raise HTTPException(
status_code=403,
detail="Only superusers can access this resource.",
)
Defence in depth: in piccolo_api/session_auth/tables.py, mark SessionsBase.token with secret=True. The existing exclude_secrets=True default on PiccoloCRUD then strips the field from every response, closing the leak even if the validator is later misconfigured by a downstream consumer.
Severity
CVSS 3.1: 8.8 HIGH — CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
Reasoning:
- AV:N — accessible over the network.
- AC:L — single GET; no race or timing dependency.
- PR:L — requires non-superuser admin credentials (the default admin role).
- UI:N — no victim interaction needed.
- S:U — scope kept Unchanged to be conservative; some auditors may prefer S:C (which yields 9.9 Critical) because crossing from admin to superuser breaks an explicit, named privilege gate.
- C:H / I:H / A:H — full read, full write, full availability impact on the admin's data and on other users' sessions.
Weaknesses
- CWE-269 Improper Privilege Management (primary)
- CWE-200 Exposure of Sensitive Information to an Unauthorized Actor
- CWE-863 Incorrect Authorization
Notes for the maintainer
- The vulnerability is reachable on any version where
superuser_validatorsuses a method deny-list andSessionsBase.tokenis notsecret=True. I tested againstpiccolo_admin 1.13.0+piccolo_api 1.9.0. - The shipped
admin_demodoes not expose theSessionstable, so the bug is not reproducible against the demo as-shipped. The PoC harness used a minimalcreate_admin([..., TableConfig(User), TableConfig(Sessions)], auth_table=User, session_table=Sessions)configuration, which mirrors the documented "Sessions admin view" pattern. - I'm happy to coordinate disclosure timing and validate any candidate patch.
{
"affected": [
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 1.13.0"
},
"package": {
"ecosystem": "PyPI",
"name": "piccolo-admin"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "1.14.0"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-55485"
],
"database_specific": {
"cwe_ids": [
"CWE-200",
"CWE-269",
"CWE-863"
],
"github_reviewed": true,
"github_reviewed_at": "2026-08-28T18:14:13Z",
"nvd_published_at": null,
"severity": "HIGH"
},
"details": "## Summary\n\n`piccolo_admin` uses a helper called `superuser_validators` to gate access to the user and session tables for non-superusers. The helper rejects `PUT`, `PATCH`, `DELETE`, and `POST`, but **does not reject `GET`**.\n\nThe `sessions` table stores live session tokens **in plaintext**, and the token column is not marked `secret=True`, so it is included in every `GET` response. Any non-superuser admin can therefore list every other user\u0027s live session token with one request, replay the token as their own `Cookie: id=\u2026`, impersonate that user (including the superuser), and then permanently self-promote by writing `superuser = true` on their own row.\n\nThe chain is reachable on a realistic, documented configuration: a deployer adds the `Sessions` (and `User`) tables to `create_admin([...])` so superusers have a UI to monitor and revoke sessions.\n\n## Affected component\n\n- **File**: `piccolo_admin/endpoints.py`\n- **Function**: `superuser_validators` (around line 419)\n\n```python\ndef superuser_validators(piccolo_crud: PiccoloCRUD, request: Request):\n user: BaseUser = request.user.user\n if not user.superuser:\n if request.method.upper() in [\"PUT\", \"PATCH\", \"DELETE\", \"POST\"]:\n raise HTTPException(\n detail=\"Only superusers can perform these actions.\",\n status_code=405,\n )\n```\n\nThe method check is a **deny-list** instead of an **allow-list**; `GET` is absent. Compounding the issue, `SessionsBase.token` in `piccolo_api/session_auth/tables.py` is a `Varchar` without `secret=True`, so the default `exclude_secrets=True` in `PiccoloCRUD` does not strip it.\n\n## Preconditions\n\n1. Network reachability to the admin.\n2. Valid credentials for a non-superuser admin (`admin=True, superuser=False` \u2014 the default role created by `BaseUser.create_user(admin=True)`).\n3. The deployment includes the `Sessions` table (and typically the `User` table) in `create_admin([...])` \u2014 the documented pattern for \"active sessions\" management UIs.\n\n## Steps to reproduce\n\n1. **Log in as the non-superuser admin** (`john / john123`). Open the *Piccolo User* table and confirm john\u0027s `SUPERUSER` column is **\u2717**. *(See Screenshot 1.)*\n\u003cimg width=\"3024\" height=\"1430\" alt=\"01-john-piccolo_user-list\" src=\"https://github.com/user-attachments/assets/31a6f81e-7d12-434a-ac99-ff64e15511f9\" /\u003e\n\n2. **Attempt the target write directly.** Send the following request:\n\n ```http\n PATCH /api/tables/piccolo_user/2/ HTTP/1.1\n Host: target:8001\n Content-Type: application/json\n Cookie: id=\u003cjohn\u0027s session\u003e; csrftoken=\u003ctoken\u003e\n X-CSRFToken: \u003ctoken\u003e\n\n {\"superuser\": true}\n ```\n\n The server returns:\n\n ```\n HTTP/1.1 405\n {\"detail\":\"Only superusers can perform these actions.\"}\n ```\n\n The same response is shown both in the dashboard banner *(Screenshot 2)* and in Burp Repeater *(Screenshot 3)*. This establishes the privilege boundary that the bug will break.\n\u003cimg width=\"3024\" height=\"2158\" alt=\"02-john-save-blocked-405\" src=\"https://github.com/user-attachments/assets/81f4b0b6-fe58-43da-b63e-6161e5911fc0\" /\u003e\n\u003cimg width=\"1213\" height=\"713\" alt=\"03-john-save-blocked-405\" src=\"https://github.com/user-attachments/assets/2eb33b00-a209-4e92-b18b-1f6520dde702\" /\u003e\n\n3. **Leak the credential.** As the same john user, request:\n\n ```http\n GET /api/tables/sessions/ HTTP/1.1\n Host: target:8001\n Cookie: id=\u003cjohn\u0027s session\u003e; csrftoken=\u003ctoken\u003e\n ```\n\n Response: `200 OK` containing every active session in plaintext, e.g.\n\n ```json\n {\"rows\":[\n {\"token\":\"jeb1d-IXIC0BWTOV6G-ApTksrbvdBDkZV9KN4taN2nE\",\"user_id\":1, ...},\n {\"token\":\"...\",\"user_id\":2, ...},\n ...\n ]}\n ```\n\n Copy the `token` value of any row whose `user_id` matches the superuser. **That string IS the live session cookie of that user.** *(Screenshot 4.)*\n\u003cimg width=\"1512\" height=\"850\" alt=\"04-john-sees-all-session-tokens\" src=\"https://github.com/user-attachments/assets/3303231f-ed87-4b32-8cab-7aa480315529\" /\u003e\n\n4. **Replay the step-2 PATCH with the stolen cookie.** Send the exact same request as step 2, changing only the `Cookie: id=` value to the stolen token:\n\n ```http\n PATCH /api/tables/piccolo_user/2/ HTTP/1.1\n Host: target:8001\n Content-Type: application/json\n Cookie: id=jeb1d-IXIC0BWTOV6G-ApTksrbvdBDkZV9KN4taN2nE; csrftoken=\u003ctoken\u003e\n X-CSRFToken: \u003ctoken\u003e\n\n {\"superuser\": true}\n ```\n\n Response: `200 OK`, body shows `\"superuser\": true` for john. *(Screenshot 5.)*\n\u003cimg width=\"1213\" height=\"713\" alt=\"05-john-self-promote\" src=\"https://github.com/user-attachments/assets/4399866a-06e8-4568-b599-922a5b16805e\" /\u003e\n\n5. **Verify persistence.** Log in fresh as `john / john123` (no stolen cookie). John is now a superuser. The stolen cookie is no longer needed \u2014 the elevation is permanent on john\u0027s own row.\n\n## Impact\n\nFull superuser takeover of the admin from any non-superuser admin account. The promoted attacker can:\n\n- read/write/delete any row in any table the admin exposes;\n- revoke any other session, locking out other admins;\n- change any user\u0027s password;\n- export data (including via the bulk CSV download forms);\n- plant payloads (e.g. CSV-formula injections) that fire when higher-trust operators open exports.\n\nPersistence is automatic \u2014 once the attacker writes `superuser=true` on their own row in step 4, the stolen cookie can be discarded.\n\n## Suggested fix\n\n**Primary (single-line):** make `superuser_validators` reject **all** requests from non-superusers \u2014 there is no legitimate non-superuser use case for the user or session tables in this context:\n\n```python\ndef superuser_validators(piccolo_crud, request):\n if not request.user.user.superuser:\n raise HTTPException(\n status_code=403,\n detail=\"Only superusers can access this resource.\",\n )\n```\n\n**Defence in depth:** in `piccolo_api/session_auth/tables.py`, mark `SessionsBase.token` with `secret=True`. The existing `exclude_secrets=True` default on `PiccoloCRUD` then strips the field from every response, closing the leak even if the validator is later misconfigured by a downstream consumer.\n\n## Severity\n\n**CVSS 3.1: 8.8 HIGH** \u2014 `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`\n\nReasoning:\n- **AV:N** \u2014 accessible over the network.\n- **AC:L** \u2014 single GET; no race or timing dependency.\n- **PR:L** \u2014 requires non-superuser admin credentials (the default admin role).\n- **UI:N** \u2014 no victim interaction needed.\n- **S:U** \u2014 scope kept Unchanged to be conservative; some auditors may prefer `S:C` (which yields 9.9 Critical) because crossing from admin to superuser breaks an explicit, named privilege gate.\n- **C:H / I:H / A:H** \u2014 full read, full write, full availability impact on the admin\u0027s data and on other users\u0027 sessions.\n\n## Weaknesses\n\n- **CWE-269** Improper Privilege Management *(primary)*\n- **CWE-200** Exposure of Sensitive Information to an Unauthorized Actor\n- **CWE-863** Incorrect Authorization\n\n## Notes for the maintainer\n\n- The vulnerability is reachable on any version where `superuser_validators` uses a method deny-list and `SessionsBase.token` is not `secret=True`. I tested against `piccolo_admin 1.13.0` + `piccolo_api 1.9.0`.\n- The shipped `admin_demo` does not expose the `Sessions` table, so the bug is not reproducible against the demo as-shipped. The PoC harness used a minimal `create_admin([..., TableConfig(User), TableConfig(Sessions)], auth_table=User, session_table=Sessions)` configuration, which mirrors the documented \"Sessions admin view\" pattern.\n- I\u0027m happy to coordinate disclosure timing and validate any candidate patch.",
"id": "GHSA-2gh4-jmwq-rr8w",
"modified": "2026-08-28T18:14:13Z",
"published": "2026-08-28T18:14:13Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/piccolo-orm/piccolo_admin/security/advisories/GHSA-2gh4-jmwq-rr8w"
},
{
"type": "WEB",
"url": "https://github.com/piccolo-orm/piccolo_api/pull/331"
},
{
"type": "WEB",
"url": "https://github.com/piccolo-orm/piccolo_admin/commit/96ddae12baf12288056cbb0cda6f9e8d7e22c86d"
},
{
"type": "WEB",
"url": "https://github.com/piccolo-orm/piccolo_api/commit/520ec2567ae1d2cc417c8c0d1ad0ddc05549a8a4"
},
{
"type": "PACKAGE",
"url": "https://github.com/piccolo-orm/piccolo_admin"
},
{
"type": "WEB",
"url": "https://github.com/piccolo-orm/piccolo_admin/releases/tag/1.14.0"
},
{
"type": "WEB",
"url": "https://github.com/piccolo-orm/piccolo_api/releases/tag/1.10.0"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
],
"summary": "piccolo-admin has a privilege escalation issue - admin to superuser via session-token disclosure in GET /api/tables/sessions/."
}
Mitigation MIT-1
Very carefully manage the setting, management, and handling of privileges. Explicitly manage trust zones in the software.
Mitigation MIT-48
Strategy: Separation of Privilege
Follow the principle of least privilege when assigning access rights to entities in a software system.
Mitigation MIT-49
Strategy: Separation of Privilege
Consider following the principle of separation of privilege. Require multiple conditions to be met before permitting access to a system resource.
CAPEC-122: Privilege Abuse
An adversary is able to exploit features of the target that should be reserved for privileged users or administrators but are exposed to use by lower or non-privileged accounts. Access to sensitive information and functionality must be controlled to ensure that only authorized users are able to access these resources.
CAPEC-233: Privilege Escalation
An adversary exploits a weakness enabling them to elevate their privilege and perform an action that they are not supposed to be authorized to perform.
CAPEC-58: Restful Privilege Elevation
An adversary identifies a Rest HTTP (Get, Put, Delete) style permission method allowing them to perform various malicious actions upon server data due to lack of access control mechanisms implemented within the application service accepting HTTP messages.