The vulnerability allows unauthorized access to LiveQuery data due to missing or incorrect Class-Level Permission (CLP) checks. The analysis of the patch identified two key vulnerable functions in src/LiveQuery/ParseLiveQueryServer.ts.
First, the ParseLiveQueryServer._handleSubscribe function, which processes new subscription requests, completely lacked a CLP check. This allowed any user, regardless of their permissions, to subscribe to any data class enabled for LiveQuery. The patch rectifies this by adding a call to SchemaController.validatePermission at the beginning of the function, ensuring that permissions are checked before a subscription is established.
Second, the ParseLiveQueryServer._matchesCLP function, which is called when data changes to determine if a subscriber should receive a real-time update, had a flawed implementation. It used a try...catch block that would catch permission validation errors from SchemaController.validatePermission and simply return false. This suppressed the error, and the calling functions (like _onAfterSave) did not correctly interpret the false return value as a denial, leading to unauthorized data being pushed to clients. The patch removes the try...catch block, allowing the permission error to propagate up the call stack, which correctly prevents the event from being delivered to unauthorized subscribers.
Therefore, an exploit would first involve a call to the vulnerable _handleSubscribe to create an unauthorized subscription. Subsequently, during event delivery for the subscribed class, the flawed logic in _matchesCLP would be triggered, leading to the data leak.