From d4fa3bd9dd48f4d5e26850a23f5ba48a9c10ad64 Mon Sep 17 00:00:00 2001 From: Andrew Branson Date: Thu, 5 Jun 2014 15:02:07 +0200 Subject: LDAP refactored behind interfaces. All functions of LDAP now hidden behind interfaces: Authenticator, Lookup and NextKeyManager (LDAP property storage was already a ClusterStorage). Gateway holds additional objects, and Fixes #26 #191. Refs #27 (needs additional work for read perms and auth tokens) --- src/main/java/com/c2kernel/process/auth/Authenticator.java | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'src/main/java/com/c2kernel/process/auth/Authenticator.java') diff --git a/src/main/java/com/c2kernel/process/auth/Authenticator.java b/src/main/java/com/c2kernel/process/auth/Authenticator.java index ae18474..40defc4 100644 --- a/src/main/java/com/c2kernel/process/auth/Authenticator.java +++ b/src/main/java/com/c2kernel/process/auth/Authenticator.java @@ -1,12 +1,16 @@ package com.c2kernel.process.auth; -import java.util.Properties; +import com.c2kernel.common.InvalidDataException; +import com.c2kernel.common.ObjectNotFoundException; -import com.c2kernel.entity.proxy.AgentProxy; public interface Authenticator { - - public void initialize(Properties props) throws Exception; - public AgentProxy authenticate(String resource) throws Exception; + public boolean authenticate(String agentName, String password, String resource) throws InvalidDataException, ObjectNotFoundException; + + public boolean authenticate(String resource) throws InvalidDataException, ObjectNotFoundException; + + public Object getAuthObject(); + + public void disconnect(); } -- cgit v1.2.3