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

Nick Couchman commented on GUACAMOLE-499:
-----------------------------------------

Well, submitted the PR that gets rid of the extra checks in the 
RESTExceptionWrapper and uses the getHttpStatusCode() output to grab the code.  
It compiles, and I did a basic test of making sure that the login still worked, 
and that works fine.  It might need some further testing to make sure, but 
seems pretty straight-forward.

I stumbled across this when taking another look at GUACAMOLE-29 to see if it 
was feasible to try to allow configuration of sending 401 instead of 403 during 
initial login to trigger a HTTP Authorization by a proxy or upstream firewall.

> REST API Error Codes should come from GuacamoleStatus
> -----------------------------------------------------
>
>                 Key: GUACAMOLE-499
>                 URL: https://issues.apache.org/jira/browse/GUACAMOLE-499
>             Project: Guacamole
>          Issue Type: Improvement
>          Components: guacamole
>            Reporter: Nick Couchman
>            Assignee: Nick Couchman
>            Priority: Trivial
>
> Currently the RESTExceptionWrapper catches specific GuacamoleException-types 
> and throws specific Response.Status types for those exceptions.  Since the 
> HTTP response code is embedded in the Exceptions via the GuacamoleStatus 
> object in those exceptions, and that status is used in the tunnel, already, 
> it seems to make sense to use this code in the REST API, as well.
> Unless there's some specific reason we're not?
> PR coming soon...



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to