char realm[REALM_SZ];
};
+enum clstate { CL_ACCEPTING, CL_ACTIVE, CL_CLOSING };
+
/*
* This structure holds all per-client information; one of these is
* allocated for each active client.
int con; /* Connection to the client */
int id; /* Unique id of client */
struct sockaddr_in haddr; /* IP address of client */
+ enum clstate state; /* State of the connection */
char clname[MAX_K_NAME_SZ]; /* Name client authenticated to */
struct krbname kname; /* Parsed version of the above */
char entity[9]; /* client program being used */
int users_id; /* Moira-internal ID of authenticated user */
int client_id; /* Moira-internal ID of client */
time_t last_time_used; /* Last time connection used */
+ mr_params req; /* Current request */
mr_params *tuples; /* Tuples waiting to send back to client */
int ntuples; /* Number of tuples waiting */
int tuplessize; /* Current size of tuple array */
int nexttuple; /* Next tuple to return */
- int done; /* Close up next time through loop */
+ char *hsbuf; /* Buffer for initial connection handshaking */
+ int hslen; /* Length of data in hsbuf */
} client;
extern char krb_realm[REALM_SZ];
void clist_delete(client *cp);
/* prototypes from mr_sauth.c */
-void do_auth(client *cl, mr_params req);
+void do_auth(client *cl);
/* prototypes from mr_scall.c */
void do_client(client *cl);
int setup_aftg(struct query *q, char *argv[], client *cl);
int setup_dnfp(struct query *q, char *argv[], client *cl);
int setup_dqot(struct query *q, char *argv[], client *cl);
-int setup_akum(struct query *q, char *argv[], client *cl);
int setup_dsnt(struct query *q, char *argv[], client *cl);
int setup_ahst(struct query *q, char *argv[], client *cl);
int setup_ahal(struct query *q, char *argv[], client *cl);
int delete_member_from_list(struct query *q, char *argv[], client *cl);
int register_user(struct query *q, char *argv[], client *cl);
-int get_list_info(struct query *q, char **argv, client *cl,
- int (*action)(int, char *[], void *), void *actarg);
int get_ace_use(struct query *q, char **argv, client *cl,
int (*action)(int, char *[], void *), void *actarg);
int qualified_get_lists(struct query *q, char **argv, client *cl,