From e7708a53d63af2b44d9833b11782405c8ce195b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Love=20H=C3=B6rnquist=20=C3=85strand?= Date: Mon, 16 Jul 2007 05:13:08 +0000 Subject: [PATCH] If its a Kerberos 4 error-code, remove the et BASE. git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@21572 ec53bebd-3082-4978-b11e-865c3cabbd6b --- lib/krb5/v4_glue.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/krb5/v4_glue.c b/lib/krb5/v4_glue.c index 9755db091..c0574f9ac 100644 --- a/lib/krb5/v4_glue.c +++ b/lib/krb5/v4_glue.c @@ -599,6 +599,9 @@ _krb5_krb_cr_err_reply(krb5_context context, RCHECK(ret, krb5_store_int8(sp, AUTH_MSG_ERR_REPLY), error); RCHECK(ret, put_nir(sp, name, inst, realm), error); RCHECK(ret, krb5_store_int32(sp, time_ws), error); + /* If its a Kerberos 4 error-code, remove the et BASE */ + if (e >= ERROR_TABLE_BASE_krb && e <= ERROR_TABLE_BASE_krb + 255) + e -= ERROR_TABLE_BASE_krb; RCHECK(ret, krb5_store_int32(sp, e), error); RCHECK(ret, krb5_store_stringz(sp, e_string), error);