Repository navigation
Fix: Missing Authorization to Unauthenticated Information Disclosure via handle_rest_pre_dispatch Function - #2179
Merged
Merged
Conversation
Version Update v4.7.3 [ master ]
gagan0123
approved these changes
Oct 3, 2025
5 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix issue: rtMedia for WordPress, BuddyPress and bbPress 4.7.0 – 4.7.1 — Missing Authorization to Unauthenticated Information Disclosure via handle_rest_pre_dispatch Function
Ref doc: https://docs.google.com/document/d/1Z2nAE-nn4SvmutUEckc6pA6SSN-rM_aF/edit
This pull request removes custom REST API integration logic from the
RTMediaJsonApicontroller. The main change is the deletion of the conditional registration and handling of therest_pre_dispatchfilter, which was used to intercept media GET requests and prepare custom responses.Explaination
On the rtMedia plugin, we are applying the
handle_rest_pre_dispatch()function onrest_pre_dispatchhook when the GoDAM plugin is active, to get the attachment information in all cases.I recall that initially, we were receiving a below response on the video editor for some media attachments (Note: users were receiving this message because they did not have sufficient permission to edit specific media). To resolve the issue, the rtMedia team may have added this function on the
rest_pre_dispatchhook, which is no longer needed.Related issue: https://github.com/rtCamp/rtmedia-io/issues/1684#event-20074973749