[ 
https://issues.apache.org/jira/browse/RANGER-674?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14976246#comment-14976246
 ] 

Gautam Borad commented on RANGER-674:
-------------------------------------

Committed to ranger-0.5 : 
https://github.com/apache/incubator-ranger/commit/2885928065e04e8956e92bff5f0304d4a347b9a6

> Ranger public rest api gives 200 response for wrong credential instead of 401
> -----------------------------------------------------------------------------
>
>                 Key: RANGER-674
>                 URL: https://issues.apache.org/jira/browse/RANGER-674
>             Project: Ranger
>          Issue Type: Bug
>          Components: admin
>    Affects Versions: 0.5.1
>            Reporter: Gautam Borad
>            Assignee: Gautam Borad
>             Fix For: 0.6.0
>
>         Attachments: RANGER-674.patch
>
>
> Getting 200 response from ranger server-side(as it is redirecting to login 
> page) using wrong credential instead of 401. 
> Because of this urllib2 python module gives 200 response code with no json 
> data in response and gets below error:
> {noformat}ValueError: No JSON object could be decoded{noformat}
> Used below rest public api url for above scenario
> {noformat} 
> http://{ranger_host}:6080/service/public/api/repository?name={repo_name}&type={repo_type}&status=true
>  {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to