summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSam Hartman <hartmans@mit.edu>1995-07-02 23:22:04 +0000
committerSam Hartman <hartmans@mit.edu>1995-07-02 23:22:04 +0000
commit14e78387eeb62b6f1c87f304b7dd4fe863b6c122 (patch)
treeed38c0102ed9804c097e891a9a2a19db68df2d75 /src
parent8ad59cabadf0ac64b4b8f0e6690e4689cd44094d (diff)
downloadkrb5-14e78387eeb62b6f1c87f304b7dd4fe863b6c122.tar.gz
krb5-14e78387eeb62b6f1c87f304b7dd4fe863b6c122.tar.xz
krb5-14e78387eeb62b6f1c87f304b7dd4fe863b6c122.zip
----------------------------------------------------------------------
automatically CVS: CVS: Committing in . CVS: CVS: Modified Files: ---------------------------------------------------------------------- Correct logic in krb5_recvauth so that it returns an error reply if authentication fails. CVS: git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6220 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src')
-rw-r--r--src/lib/krb5/krb/ChangeLog6
-rw-r--r--src/lib/krb5/krb/recvauth.c17
2 files changed, 16 insertions, 7 deletions
diff --git a/src/lib/krb5/krb/ChangeLog b/src/lib/krb5/krb/ChangeLog
index a8c0dc05b..be02d6e7f 100644
--- a/src/lib/krb5/krb/ChangeLog
+++ b/src/lib/krb5/krb/ChangeLog
@@ -1,3 +1,9 @@
+Sun Jul 2 18:59:53 1995 Sam Hartman <hartmans@tertius.mit.edu>
+
+ * recvauth.c (krb5_recvauth): recvauth should send an error reply
+ if problem is not zero. Removed if that caused it to only send a
+ reply on success.
+
Fri Jun 16 22:11:21 1995 Theodore Y. Ts'o (tytso@dcl)
* get_in_tkt.c (krb5_get_in_tkt): Allow the credentials cache
diff --git a/src/lib/krb5/krb/recvauth.c b/src/lib/krb5/krb/recvauth.c
index 77ea1cfc3..eb753f8ec 100644
--- a/src/lib/krb5/krb/recvauth.c
+++ b/src/lib/krb5/krb/recvauth.c
@@ -188,6 +188,11 @@ krb5_recvauth(context, auth_context,
memset((char *)&error, 0, sizeof(error));
krb5_us_timeofday(context, &error.stime, &error.susec);
error.server = server;
+
+
+
+
+
error.error = problem - ERROR_TABLE_BASE_krb5;
if (error.error > 127)
error.error = KRB_ERR_GENERIC;
@@ -208,17 +213,15 @@ krb5_recvauth(context, auth_context,
outbuf.data = 0;
}
- if (!problem) {
- retval = krb5_write_message(context, fd, &outbuf);
- if (outbuf.data)
- krb5_xfree(outbuf.data);
- if (retval)
- goto cleanup;
- } else {
+ retval = krb5_write_message(context, fd, &outbuf);
+ if (outbuf.data) {
+ krb5_xfree(outbuf.data);
/* We sent back an error, we need cleanup then return */
retval = problem;
goto cleanup;
}
+ if (retval)
+ goto cleanup;
/* Here lies the mutual authentication stuff... */
if ((ap_option & AP_OPTS_MUTUAL_REQUIRED)) {