Reverb handles one edge case differently starting with this release: when an application in your config/reverb.php file does not define the accept_client_events_from key, Reverb now falls back to members instead of all. In practice, that means client events (whispers) may only be sent by clients that are actually subscribed to the target channel. The change only matters for configuration files that were published before Reverb 1.8.0 — if you installed Reverb recently, your published config already contains the key and nothing changes for you.
What changed
ConfigApplicationProvider::find() turns an entry in your config/reverb.php file into an Application object. When that entry lacked an accept_client_events_from option, the provider silently filled in all. It now fills in members:
// Before
$app['accept_client_events_from'] ?? 'all',
// After
$app['accept_client_events_from'] ?? 'members',
That single word is the entire runtime change. The rest of the pull request is documentation and test coverage, including a new unit test asserting that an unconfigured application rejects client events from non-members with a 4009 error.
Why the fallback existed and why it changed
The accept_client_events_from option was introduced in Reverb 1.8.0. It controls who is allowed to send client events — messages prefixed with client-, often called whispers — on a channel:
all: any connected client may send client events, even on channels it has not joined.members: only clients with an active subscription to the channel may send client events.none: client events are rejected entirely.
Fresh installs publish the option with members, and the Application constructor also defaults to members. But an application whose config/reverb.php predated the option had no key at all, so the ?? 'all' fallback quietly gave it different behavior from a brand new install. Aligning the provider fallback with the constructor default removes that drift: every application now behaves the same whether or not the key is present in the file.
How the new default behaves
With members in effect, a client must hold an active subscription to a channel before it can whisper on it. A client that sends a client- event to a channel it has not joined now receives an error frame:
{
"event": "pusher:error",
"data": "{\"code\":4009,\"message\":\"The client is not a member of the specified channel.\"}"
}
Typical usage is unaffected, because normal whisper flows subscribe first:
const channel = Echo.private('chat.1');
channel.whisper('typing', { name: 'Taylor' });
Here the client joins chat.1 before whispering, so the event is forwarded to the other subscribers exactly as before. Only clients pushing client- events into channels they never subscribed to — for example, hand-rolled WebSocket frames — will notice the rejection. This also tightens the invariant that a client cannot inject events into conversations it is not part of.
Keeping the previous behavior
If you depend on the old all semantics, add the option explicitly to each application in config/reverb.php:
'accept_client_events_from' => env('REVERB_APP_ACCEPT_CLIENT_EVENTS_FROM', 'all'),
Then restart the server so the running processes pick up the new configuration:
php artisan reverb:restart
If you would rather pin the new behavior in your config file — recommended, so future upgrades hold no surprises — set the same key to members, or re-publish a fresh config file and merge your custom values back in.
Takeaways
- A missing
accept_client_events_fromkey now behaves asmembers, notall. - Only config files published before Reverb 1.8.0 are affected; newer configs already set
membersexplicitly, and fresh installs are unchanged. - Clients that are not subscribed to a channel and try to send client events receive a
4009"not a member" error; ordinary whisper usage keeps working. - To preserve the old behavior, add
'accept_client_events_from' => env('REVERB_APP_ACCEPT_CLIENT_EVENTS_FROM', 'all')to each app inconfig/reverb.phpand restart Reverb.