Page MenuHomePhabricator

CSRF in CodeReview ApiRevisionUpdate
Closed, ResolvedPublic

Description

The ApiRevisionUpdate module in CodeReview does not have any CSRF protection. The code says:

/**

  • Variation of CodeRevisionCommiter for use in the API. Removes the post and token checking from validPost
  • API can/will do the POST checking (and token?) */

No, it does not do token checking. ApiBase::needsToken() and ApiBase::getTokenSalt() must be overridden, which they aren't.


Version: unspecified
Severity: normal

Details

Reference
bz32870

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 12:05 AM
bzimport set Reference to bz32870.
bzimport added a subscriber: Unknown Object (MLST).

Note that the client code from r95435 will need to be updated, adding Hashar to the CC list for that.

r95435 was reverted, but the original code Tim mentioned the issue with is still there