krb5 commit: Remove dead variable def_kslist from two files

Greg Hudson <[email protected]>
Newsgroups gmane.comp.encryption.kerberos.cvs
Message-ID <[email protected]>
https://github.com/krb5/krb5/commit/6309f5e3508cd24151222b2cd095766283e205f2
commit 6309f5e3508cd24151222b2cd095766283e205f2
Author: Robbie Harwood <[email protected]>
Date:   Thu May 2 16:57:51 2019 -0400

    Remove dead variable def_kslist from two files
    
    def_kslist was part of kdb5_create.c since its addition (commit
    edf8b4d8a6a665c2aa150993cd813ea6c5cf12e1) and has always been
    irrelevant since the rblock structure is fully initialized in
    kdb5_create().
    
    def_klist was copied into kdb5_ldap_realm.c (present in addition at
    commit 42d9d6ab320ee3a661fe21472be542acd542d5be).  The global rblock
    structure (and therefore the initializer) was removed in commit
    9c850f8b62784170a5e42315c1a9552ddcf4ca2b, leaving def_kslist
    unreferenced.
    
    Remove def_kslist from both files, and remove the rblock initializer
    from kdb5_create.c.
    
    [[email protected]: edited commit message]

 src/kadmin/dbutil/kdb5_create.c                  |   12 +-----------
 src/plugins/kdb/ldap/ldap_util/kdb5_ldap_realm.c |    1 -
 2 files changed, 1 insertions(+), 12 deletions(-)

diff --git a/src/kadmin/dbutil/kdb5_create.c b/src/kadmin/dbutil/kdb5_create.c
index bc1b919..efdb8ad 100644
--- a/src/kadmin/dbutil/kdb5_create.c
+++ b/src/kadmin/dbutil/kdb5_create.c
@@ -66,8 +66,6 @@ enum ap_op {
     TGT_KEY                             /* special handling for tgt key */
 };
 
-krb5_key_salt_tuple def_kslist = { ENCTYPE_DES_CBC_CRC, KRB5_KDB_SALTTYPE_NORMAL };
-
 struct realm_info {
     krb5_deltat max_life;
     krb5_deltat max_rlife;
@@ -76,15 +74,7 @@ struct realm_info {
     krb5_keyblock *key;
     krb5_int32 nkslist;
     krb5_key_salt_tuple *kslist;
-} rblock = { /* XXX */
-    KRB5_KDB_MAX_LIFE,
-    KRB5_KDB_MAX_RLIFE,
-    KRB5_KDB_EXPIRATION,
-    KRB5_KDB_DEF_FLAGS,
-    (krb5_keyblock *) NULL,
-    1,
-    &def_kslist
-};
+} rblock;
 
 struct iterate_args {
     krb5_context        ctx;
diff --git a/src/plugins/kdb/ldap/ldap_util/kdb5_ldap_realm.c b/src/plugins/kdb/ldap/ldap_util/kdb5_ldap_realm.c
index 5a745e2..c21d199 100644
--- a/src/plugins/kdb/ldap/ldap_util/kdb5_ldap_realm.c
+++ b/src/plugins/kdb/ldap/ldap_util/kdb5_ldap_realm.c
@@ -91,7 +91,6 @@
 extern time_t get_date(char *); /* kadmin/cli/getdate.o */
 
 char *yes = "yes\n"; /* \n to compare against result of fgets */
-krb5_key_salt_tuple def_kslist = {ENCTYPE_DES_CBC_CRC, KRB5_KDB_SALTTYPE_NORMAL};
 
 krb5_data tgt_princ_entries[] = {
     {0, KRB5_TGS_NAME_SIZE, KRB5_TGS_NAME},
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.