kdb/keytab.c: map KRB5_KDB_NO_MATCHING_KEY to KRB5_KT_KVNONOTFOUND.
authorSam Hartman <hartmans@mit.edu>
Wed, 7 Jan 2009 18:13:30 +0000 (18:13 +0000)
committerSam Hartman <hartmans@mit.edu>
Wed, 7 Jan 2009 18:13:30 +0000 (18:13 +0000)
At least in cases other than tgts, this  code handles its own enctype matching, so kvno not found is the only
thing that produces the no matching key error.

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@21718 dc483132-0cff-0310-8789-dd5450dbe970

src/lib/kdb/keytab.c

index fa95e48515e1630a2a1b8e2fe7832fe2947b9745..395b56d61e929c941b8ce616fd64b1f146cb54ba 100644 (file)
@@ -173,6 +173,8 @@ krb5_ktkdb_get_entry(in_context, id, principal, kvno, enctype, entry)
     kerror = krb5_dbe_find_enctype(context, &db_entry,
                                   xrealm_tgt?enctype:-1,
                                   -1, kvno, &key_data);
+    if (kerror == KRB5_KDB_NO_MATCHING_KEY)
+       kerror = KRB5_KT_KVNONOTFOUND;
     if (kerror)
        goto error;