01: /*
02: * This file is part of the QuickServer library
03: * Copyright (C) 2003-2005 QuickServer.org
04: *
05: * Use, modification, copying and distribution of this software is subject to
06: * the terms and conditions of the GNU Lesser General Public License.
07: * You should have received a copy of the GNU LGP License along with this
08: * library; if not, you can download a copy from <http://www.quickserver.org/>.
09: *
10: * For questions, suggestions, bug-reports, enhancement-requests etc.
11: * visit http://www.quickserver.org
12: *
13: */
14:
15: package org.quickserver.net.server;
16:
17: import java.io.*;
18: import java.net.SocketTimeoutException;
19: import org.quickserver.net.AppException;
20: import org.quickserver.net.ConnectionLostException;
21: import org.quickserver.util.io.*;
22:
23: /**
24: * This class is used to authenticate a client when
25: * it connects to QuickServer. Only single instance of this class
26: * will be used per QuickServer to handle all authentication.
27: * Should have a default constructor.
28: *
29: </pre></BLOCKQUOTE></code></p>
30: * @author Akshathkumar Shetty
31: * @since 1.4.6
32: */
33: public abstract class QuickAuthenticationHandler implements
34: ClientAuthenticationHandler {
35:
36: public AuthStatus askAuthentication(ClientHandler handler)
37: throws IOException, AppException {
38: return null;
39: }
40:
41: public AuthStatus handleAuthentication(ClientHandler handler,
42: String data) throws IOException, AppException {
43: if (true)
44: throw new RuntimeException(
45: "String/Byte mode not implemented!");
46: return null;
47: }
48:
49: public AuthStatus handleAuthentication(ClientHandler handler,
50: Object data) throws IOException, AppException {
51: if (true)
52: throw new RuntimeException(
53: "String/Byte mode not implemented!");
54: return null;
55: }
56:
57: public AuthStatus handleAuthentication(ClientHandler handler,
58: byte data[]) throws IOException {
59: if (true)
60: throw new RuntimeException(
61: "String/Byte mode not implemented!");
62: return null;
63: }
64: }
|