aboutsummaryrefslogtreecommitdiff
path: root/src/lib/krb5/ccache/stdio
diff options
context:
space:
mode:
authorSam Hartman <hartmans@mit.edu>1996-01-25 20:01:45 +0000
committerSam Hartman <hartmans@mit.edu>1996-01-25 20:01:45 +0000
commit2f0de7c22a5a554fff28c17ae7c0a741dfd48108 (patch)
tree013808ed19174bcccf3b280253b0198471c39e21 /src/lib/krb5/ccache/stdio
parent154715bdfc619cc55313daf595ee94f8b64805d7 (diff)
downloadkrb5-2f0de7c22a5a554fff28c17ae7c0a741dfd48108.zip
krb5-2f0de7c22a5a554fff28c17ae7c0a741dfd48108.tar.gz
krb5-2f0de7c22a5a554fff28c17ae7c0a741dfd48108.tar.bz2
Previously, ktype_match only made sure that the enctype was valid
and in the set of default tgs enctypes. Now, if matching on keytype, do an exact match, else use ktype_reasonable (renamed ktype_match) to make sure the ticket is in the default tgs enctypes. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@7384 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/lib/krb5/ccache/stdio')
-rw-r--r--src/lib/krb5/ccache/stdio/ChangeLog5
-rw-r--r--src/lib/krb5/ccache/stdio/scc_retrv.c11
2 files changed, 11 insertions, 5 deletions
diff --git a/src/lib/krb5/ccache/stdio/ChangeLog b/src/lib/krb5/ccache/stdio/ChangeLog
index 5a3939e..1b3e55b 100644
--- a/src/lib/krb5/ccache/stdio/ChangeLog
+++ b/src/lib/krb5/ccache/stdio/ChangeLog
@@ -1,3 +1,8 @@
+Thu Jan 25 14:44:48 1996 Sam Hartman <hartmans@tertius.mit.edu>
+
+ * scc_retrv.c (ktype_reasonable): Rename ktype_match; see fcc for explanation.
+ (krb5_scc_retrieve): Match exactly on enctype if requested to do so.
+
Wed Jan 10 22:44:43 1996 Theodore Y. Ts'o <tytso@dcl>
* scc.h (KRB5_SCC_DEFAULT_VNO): Remove KRB5_SCC_DEFAULT_VNO; now
diff --git a/src/lib/krb5/ccache/stdio/scc_retrv.c b/src/lib/krb5/ccache/stdio/scc_retrv.c
index 2f3340f..0c905d7 100644
--- a/src/lib/krb5/ccache/stdio/scc_retrv.c
+++ b/src/lib/krb5/ccache/stdio/scc_retrv.c
@@ -135,9 +135,9 @@ register const krb5_data *data1, *data2;
}
static krb5_boolean
-ktype_match(context, creds)
-register krb5_context context;
-register krb5_creds *creds;
+ktype_reasonable(context, creds)
+ register krb5_context context;
+ register krb5_creds *creds;
{
register int i;
krb5_enctype * ktypes = (krb5_enctype *) NULL;
@@ -223,8 +223,9 @@ krb5_scc_retrieve(context, id, whichfields, mcreds, creds)
(! set(KRB5_TC_MATCH_2ND_TKT) ||
data_match (&mcreds->second_ticket, &fetchcreds.second_ticket))
&&
- (! set(KRB5_TC_MATCH_KTYPE) ||
- ktype_match (context, &fetchcreds))
+ ((! set(KRB5_TC_MATCH_KTYPE)&&
+ ktype_reasonable (context, &fetchcreds))||
+ (mcreds->keyblock.enctype == fetchcreds.keyblock.enctype))
)
{
krb5_scc_end_seq_get(context, id, &cursor);