nickva commented on code in PR #6190:
URL: https://github.com/apache/couchdb/pull/6190#discussion_r4445955610


##########
src/chttpd/src/chttpd.erl:
##########
@@ -426,7 +426,7 @@ handle_req_after_auth(HandlerKey, HttpReq) ->
             fun chttpd_db:handle_request/1
         ),
         AuthorizedReq = chttpd_auth:authorize(
-            possibly_hack(HttpReq),

Review Comment:
   A 400 could make sense for _replicate since it's a request with a bad input. 
A _replicator doc update gets a 403 as that's what we get on a VDU rejection. 
We do the same for a bad url: 400 for _replicate and a 403 for a bad 
_replicator doc.
   
   It seems like want tests for at least these cases: _replicate plain string 
source/target, _replicate with missing source/target, _replicator doc with 
plain string source/target, _replicator doc with a missing source/target. 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to