# GHSA-556J-6JH2-5RCV: Star Ratings does not enforce vote\_access on the server

- Database: GitHub
- Severity: CVSS 5.3 (Medium)
- Published: 2026-09-23
- Modified: 2026-09-23

## Affected versions

- getgrav/grav-plugin-star-ratings (Packagist): from 2.0.1, fixed in 2.0.4

## Description

## Summary

Star Ratings exposes a `vote_access` setting for restricting who may vote, and a `readonly` setting for disabling voting entirely. Both are enforced only by how the browser widget is rendered. The server-side vote handler checks neither.

## Affected versions

Star Ratings 2.0.1 through 2.0.3 are affected when `vote_access` is configured or `readonly` is enabled. Both are off by default.

## Details

`getData()` checks `vote_access` and sets client-side `readOnly` and `loginRequired` flags for an unauthorized viewer, and passes the configured `readonly` setting through as the same client-side flag. It still emits a valid anonymous vote nonce in the widget data. `addVote()` verifies that nonce and optional per-IP deduplication, but never authorizes the current user against `vote_access` and never consults `readonly`. A client can therefore ignore the read-only UI and submit the vote directly.

## Impact

An unauthenticated visitor can add and influence ratings on a site whose operator explicitly restricted voting to logged-in or otherwise authorized users, or disabled voting altogether. This crosses the operator-configured authorization boundary and affects rating integrity, including aggregate rating output.

## Patches

Upgrade to Star Ratings 2.0.4 when it is released. The fix enforces both `vote_access` and `readonly` in the server-side vote handler before changing stored ratings.

Note for that release: per-page `vote_access` and a per-widget `readOnly` passed to `stars()` are still not bound to the callback, so the fix covers the global configuration only.

## Credits

Reported by @AlpetGexha.

## References

- https://github.com/getgrav/grav/security/advisories/GHSA-556j-6jh2-5rcv

Page: https://cve.now/GHSA-556J-6JH2-5RCV

Wrong or missing data? Send feedback: POST https://cve.now/api/v1/feedback (see https://cve.now/agents#feedback).
