You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@guacamole.apache.org by GitBox <gi...@apache.org> on 2019/08/19 07:02:51 UTC

[GitHub] [guacamole-client] mike-jumper commented on issue #352: GUACAMOLE-684: Insufficient credentials should take precedence over other failures

mike-jumper commented on issue #352: GUACAMOLE-684: Insufficient credentials should take precedence over other failures
URL: https://github.com/apache/guacamole-client/pull/352#issuecomment-522440399
 
 
   I gave this a fair bit of thought over the course of today, and I think the changes you propose are fine. Rather than deviate from existing behavior, I believe these changes actually fill a gap in the original intent. My reasoning:
   
   * An extension throws `GuacamoleInsufficientCredentialsException` specifically to indicate tentative acceptance of the credentials passed thus far.
   * Just as such an extension that fully accepts credentials takes priority over an extension that refuses to accept the same, it makes sense to allow an extension that *tentatively* accepts those credentials to also take priority.
   
   With the above perspective, authentication result priorities are layered in the following order, with ties broken by the inherent order of the auth providers (extensions sorted by filename, multiple auth providers within an extension maintained in the order declared within `guac-manifest.json`):
   
   1. Acceptance (returning an `AuthenticedUser` instance).
   2. Tentative acceptance (throwing `GuacamoleInvalidCredentialsException`).
   3. Complete refusal (any other subclass of `GuacamoleCredentialsException`).
   4. Neither refusal nor acceptance (returning `null`).
   
   I don't foresee breakage as a result of this, and expect this will remove the need to rename extensions in all but unusual cases.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services