changeset 3070:305ac76afcda HEAD

Removed SERVICE command. It's quite useless extra state to keep around.
author Timo Sirainen <tss@iki.fi>
date Sat, 08 Jan 2005 21:01:31 +0200
parents 131151e25e4b
children c7db6b291daa
files doc/auth-protocol.txt src/auth/auth-client-connection.c src/auth/auth-client-connection.h
diffstat 3 files changed, 0 insertions(+), 18 deletions(-) [+]
line wrap: on
line diff
--- a/doc/auth-protocol.txt	Sat Jan 08 18:56:04 2005 +0200
+++ b/doc/auth-protocol.txt	Sat Jan 08 21:01:31 2005 +0200
@@ -37,7 +37,6 @@
 The connection starts by both client and server sending handshakes:
 
  C: "VERSION" TAB <major> TAB <minor>
- C: "SERVICE" TAB <service> (optional)
  C: "CPID" TAB <pid>
 
  S: "VERSION" TAB <major> TAB <minor>
@@ -64,10 +63,6 @@
 
 CUID is currently useful only for APOP authentication.
 
-SERVICE command can be used to specify default service name for
-authentication requests. If it's not set, each request must specify the
-service separately.
-
 DONE finishes the handshake from server. CPID finishes the handshake from
 client.
 
--- a/src/auth/auth-client-connection.c	Sat Jan 08 18:56:04 2005 +0200
+++ b/src/auth/auth-client-connection.c	Sat Jan 08 21:01:31 2005 +0200
@@ -153,14 +153,6 @@
 }
 
 static int
-auth_client_input_service(struct auth_client_connection *conn, const char *args)
-{
-	if (conn->default_service == NULL)
-		conn->default_service = p_strdup(conn->pool, args);
-	return TRUE;
-}
-
-static int
 auth_client_input_cpid(struct auth_client_connection *conn, const char *args)
 {
         struct auth_client_connection *old;
@@ -267,8 +259,6 @@
 			valid_client_cert = TRUE;
 	}
 
-	if (request->service == NULL)
-		request->service = conn->default_service;
 	if (request->service == NULL) {
 		i_error("BUG: Authentication client %u "
 			"didn't specify service in request", conn->pid);
@@ -410,8 +400,6 @@
 			ret = auth_client_input_cont(conn, line + 5);
 		else if (strncmp(line, "CPID\t", 5) == 0)
 			ret = auth_client_input_cpid(conn, line + 5);
-		else if (strncmp(line, "SERVICE\t", 6) == 0)
-			ret = auth_client_input_service(conn, line + 6);
 		else {
 			/* ignore unknown command */
 			ret = TRUE;
--- a/src/auth/auth-client-connection.h	Sat Jan 08 18:56:04 2005 +0200
+++ b/src/auth/auth-client-connection.h	Sat Jan 08 21:01:31 2005 +0200
@@ -15,7 +15,6 @@
 
 	pool_t pool;
 	struct hash_table *auth_requests;
-	char *default_service;
 
 	unsigned int pid;
 	unsigned int connect_uid;