From: zacheiss Date: Fri, 29 Mar 2002 02:24:25 +0000 (+0000) Subject: register_user() on a registered Kerberos-only account should provide you X-Git-Url: http://andersk.mit.edu/gitweb/moira.git/commitdiff_plain/7c95c11b0d7c14004290e14b92e799ea8bdd1eeb register_user() on a registered Kerberos-only account should provide you with a status 1 account. --- diff --git a/server/qsupport.pc b/server/qsupport.pc index c133a0ee..655ad2eb 100644 --- a/server/qsupport.pc +++ b/server/qsupport.pc @@ -1474,7 +1474,8 @@ int register_user(struct query *q, char **argv, client *cl) /* find user */ EXEC SQL SELECT users_id, status INTO :users_id, :ostatus FROM users - WHERE unix_uid = :uid AND (status = 0 OR status = 5 OR status = 6); + WHERE unix_uid = :uid AND + (status = 0 OR status = 5 OR status = 6 OR status = 9); if (sqlca.sqlerrd[2] == 0) return MR_NO_MATCH; @@ -1510,7 +1511,7 @@ int register_user(struct query *q, char **argv, client *cl) WHERE label = :login || '.po'; if (dbms_errno) return mr_errcode; - if ((ostatus == 0) || (tmp != users_id)) + if ((ostatus == 0 || ostatus == 9) || (tmp != users_id)) return MR_IN_USE; else po_exists = 1; @@ -1657,7 +1658,7 @@ int register_user(struct query *q, char **argv, client *cl) sprintf(buffer, "u.users_id = %d", users_id); incremental_before(USERS_TABLE, buffer, 0); nstatus = 2; - if (ostatus == 5 || ostatus == 6) + if (ostatus == 5 || ostatus == 6 || ostatus == 9) nstatus = 1; EXEC SQL UPDATE users SET login = :login, status = :nstatus, modtime = SYSDATE, modby = :who, modwith = :entity,