mirror of
				https://github.com/gyurix1968/guacamole-client.git
				synced 2025-10-31 00:53:21 +00:00 
			
		
		
		
	GUAC-587: Failed providers should throw "invalid" credential exceptions, not "insufficient".
This commit is contained in:
		| @@ -28,7 +28,7 @@ import org.glyptodon.guacamole.net.auth.AuthenticationProvider; | ||||
| import org.glyptodon.guacamole.net.auth.Credentials; | ||||
| import org.glyptodon.guacamole.net.auth.UserContext; | ||||
| import org.glyptodon.guacamole.net.auth.credentials.CredentialsInfo; | ||||
| import org.glyptodon.guacamole.net.auth.credentials.GuacamoleInsufficientCredentialsException; | ||||
| import org.glyptodon.guacamole.net.auth.credentials.GuacamoleInvalidCredentialsException; | ||||
| import org.slf4j.Logger; | ||||
| import org.slf4j.LoggerFactory; | ||||
|  | ||||
| @@ -124,7 +124,7 @@ public class AuthenticationProviderFacade implements AuthenticationProvider { | ||||
|         // Ignore auth attempts if no auth provider could be loaded | ||||
|         if (authProvider == null) { | ||||
|             logger.warn("Authentication attempt denied because the authentication system could not be loaded. Please for errors earlier in the logs."); | ||||
|             throw new GuacamoleInsufficientCredentialsException("Permission denied.", CredentialsInfo.USERNAME_PASSWORD); | ||||
|             throw new GuacamoleInvalidCredentialsException("Permission denied.", CredentialsInfo.USERNAME_PASSWORD); | ||||
|         } | ||||
|  | ||||
|         // Delegate to underlying auth provider | ||||
| @@ -139,7 +139,7 @@ public class AuthenticationProviderFacade implements AuthenticationProvider { | ||||
|         // Ignore auth attempts if no auth provider could be loaded | ||||
|         if (authProvider == null) { | ||||
|             logger.warn("Reauthentication attempt denied because the authentication system could not be loaded. Please for errors earlier in the logs."); | ||||
|             throw new GuacamoleInsufficientCredentialsException("Permission denied.", CredentialsInfo.USERNAME_PASSWORD); | ||||
|             throw new GuacamoleInvalidCredentialsException("Permission denied.", CredentialsInfo.USERNAME_PASSWORD); | ||||
|         } | ||||
|  | ||||
|         // Delegate to underlying auth provider | ||||
|   | ||||
		Reference in New Issue
	
	Block a user