Index: lams_common/src/java/org/lamsfoundation/lams/integration/security/Authenticator.java =================================================================== diff -u -rd55a76ed168ceba36a6b246b46096a4b27f71427 -r9d9f6831591a5a8253ccb65c59e4df7e9d9761ac --- lams_common/src/java/org/lamsfoundation/lams/integration/security/Authenticator.java (.../Authenticator.java) (revision d55a76ed168ceba36a6b246b46096a4b27f71427) +++ lams_common/src/java/org/lamsfoundation/lams/integration/security/Authenticator.java (.../Authenticator.java) (revision 9d9f6831591a5a8253ccb65c59e4df7e9d9761ac) @@ -36,6 +36,7 @@ public class Authenticator { public static void authenticate(ExtServerOrgMap map, String datetime, String username, String method, String hashValue) throws AuthenticationException{ if(map==null) throw new AuthenticationException("The third party server is not configured on LAMS server"); + if(map.getDisabled()) throw new AuthenticationException("The third party server is disabled"); String plaintext = datetime.toLowerCase().trim() + username.toLowerCase().trim() + method.toLowerCase().trim() + @@ -46,12 +47,14 @@ public static void authenticate(ExtServerOrgMap map, String datetime, String username, String hashValue) throws AuthenticationException{ if(map==null) throw new AuthenticationException("The third party server is not configured on LAMS server"); + if(map.getDisabled()) throw new AuthenticationException("The third party server is disabled"); String plaintext = datetime.toLowerCase().trim()+username.toLowerCase().trim()+map.getServerid().toLowerCase().trim()+map.getServerkey().toLowerCase().trim(); checkHash(plaintext, hashValue); } public static void authenticate(ExtServerOrgMap map, String datetime, String hashValue) throws AuthenticationException{ if(map==null) throw new AuthenticationException("The third party server is not configured on LAMS server"); + if(map.getDisabled()) throw new AuthenticationException("The third party server is disabled"); String plaintext = datetime.toLowerCase().trim()+map.getServerid().toLowerCase().trim()+map.getServerkey().toLowerCase().trim(); checkHash(plaintext, hashValue); }