auth-master-connection.c revision bbef8d37812f877525ca57e7ed206094e1efe288
/* Copyright (C) 2002 Timo Sirainen */
#include "common.h"
#include "buffer.h"
#include "hash.h"
#include "ioloop.h"
#include "ostream.h"
#include "network.h"
#include "mech.h"
#include "userdb.h"
#include "auth-client-connection.h"
#include "auth-master-connection.h"
static struct auth_master_reply failure_reply =
{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 };
struct master_userdb_request {
struct auth_master_connection *conn;
unsigned int tag;
};
{
return (size_t)-1;
return index;
}
static struct auth_master_reply *
{
char *p;
if (p == NULL) {
} else {
/* wu-ftpd like <chroot>/./<home> */
}
return reply_p;
}
struct auth_master_reply *reply,
{
for (;;) {
if (ret < 0) {
/* master died, kill ourself too */
break;
}
break;
/* buffer full, we have to block */
i_warning("Master transmit buffer full, blocking..");
/* transmit error, probably master died */
break;
}
}
}
{
struct auth_master_reply *reply;
sizeof(failure_reply),
} else {
}
}
}
struct auth_master_request *request)
{
struct auth_client_connection *client_conn;
struct auth_request *auth_request;
struct master_userdb_request *master_request;
if (auth_request == NULL) {
if (verbose) {
i_info("Master request %u.%u not found",
}
} else {
/* the auth request is finished, we don't need it anymore */
}
}
static void master_input(void *context)
{
int ret;
if (ret < 0) {
/* master died, kill ourself too */
return;
}
/* reply is now read */
conn->request_buf);
conn->request_pos = 0;
}
}
struct auth_master_connection *
{
struct auth_master_connection *conn;
/* just a note to master that we're ok. if we die before,
master should shutdown itself. */
return conn;
}
{
return;
}
{
return TRUE;
return FALSE;
}