GHSA-wgvx-x5g3-9v29

Suggest an improvement
Source
https://github.com/advisories/GHSA-wgvx-x5g3-9v29
Import Source
https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/11/GHSA-wgvx-x5g3-9v29/GHSA-wgvx-x5g3-9v29.json
JSON Data
https://api.osv.dev/v1/vulns/GHSA-wgvx-x5g3-9v29
Aliases
Published
2026-11-20T00:18:35Z
Modified
2026-11-20T00:30:06Z
Severity
  • 6.5 (Medium) CVSS_V3 - CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N CVSS Calculator
Summary
baserCMS administrative API authorization bypass through session fallback
Details

Summary

An authorization bypass occurs against the API endpoint /baser/api/admin/ by abusing the session authentication fallback.

Details

The mail settings are used here as an example.

Admin side:

https://github.com/baserproject/basercms/blob/master/plugins/baser-core/config/permission.php#L100 With auth => false, it is not accessible with operator privileges.

API side:

https://github.com/baserproject/basercms/blob/master/plugins/baser-core/config/permission.php#L286 With auth => true, it is accessible even with operator privileges.


First, the default group for operators has auth_prefix = 'Admin', which does not include Api/Admin.

https://github.com/baserproject/basercms/blob/master/plugins/baser-core/src/Model/Table/UsersTable.php#L389

Because of this condition, when trying to access the Api/Admin API with a JWT, operators have auth_prefix = 'Admin', so they cannot obtain a JWT and should not be able to access it.

However, there is a problem in getAuthenticationService.

https://github.com/baserproject/basercms/blob/master/plugins/baser-core/src/BaserCorePlugin.php#L507

Here, session authentication is enabled even for the Api/Admin prefix. By accessing the API with a Referer header, session authentication becomes active, allowing access to the API without holding a JWT.

As a result, all APIs configured with auth => true in permission.php become accessible by operators.

PoC

  1. Log in with a site operator (operator) privileged account.
  2. Run the following code in DevTools:
fetch('/baser/api/admin/baser-core/site_configs/view.json', {
  headers: {
    'Referer': location.origin + '/baser/admin/' 
  }
})
.then(r => r.json())
.then(d => {
  console.table(d.siteConfig);
})
Screenshot_20260404_075242 Screenshot_20260404_075133
Database specific
{
    "cwe_ids": [
        "CWE-290"
    ],
    "github_reviewed": true,
    "github_reviewed_at": "2026-11-20T00:18:35Z",
    "nvd_published_at": "2026-11-19T21:18:03Z",
    "severity": "MODERATE"
}
References

Affected packages

Packagist / baserproject/baser-core

Package

Name
baserproject/baser-core
Purl
pkg:composer/baserproject/baser-core

Affected ranges

Type
ECOSYSTEM
Events
Introduced
0 Unknown introduced version / All previous versions are affected
Fixed
5.3.0

Affected versions

5.*
5.0.0-beta2
5.0.0-beta3
5.0.0-beta4
5.0.0
5.0.1
5.0.2
5.0.3
5.0.4
5.0.5
5.0.6
5.0.7
5.0.8
5.0.10
5.0.11
5.0.14
5.0.15
5.0.16
5.0.17
5.0.18
5.0.19
5.0.20
5.0.21
5.1.0
5.1.1
5.1.2
5.1.3
5.1.4
5.1.5
5.1.6
5.1.7
5.1.8
5.1.9
5.1.10
5.2.0
5.2.1
5.2.2
5.2.3
5.2.4
5.2.5
5.2.5.1
5.2.6
5.2.7
5.2.8
5.2.9
5.2.10

Database specific

last_known_affected_version_range
"<= 5.2.3"
source
"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/11/GHSA-wgvx-x5g3-9v29/GHSA-wgvx-x5g3-9v29.json"