[wp-trac] [WordPress Trac] #48213: The XML-RPC endpoint should return a more appropriate HTTP status code when it's disabled
WordPress Trac
noreply at wordpress.org
Sat Nov 28 01:15:12 UTC 2020
#48213: The XML-RPC endpoint should return a more appropriate HTTP status code when
it's disabled
--------------------------+------------------------------
Reporter: johnbillion | Owner: (none)
Type: defect (bug) | Status: new
Priority: low | Milestone: Awaiting Review
Component: XML-RPC | Version:
Severity: normal | Resolution:
Keywords: has-patch | Focuses:
--------------------------+------------------------------
Comment (by ericmann):
Patch above created via GitHub does three things:
1. It adds a 405 header when XML-RPC is disabled.
1. It adds a 403 header when authentication fails.
1. It adds whatever error is encoded into `IXR_Error` automatically when
any other error is throw.
The last bullet might be unnecessary and is a little outside the scope of
the original ask, but was a relatively straightforward add to the behavior
of `IXR_Server::error()` so I threw it in for completeness.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/48213#comment:3>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list