krb5 commit: Improve error for kadmind -proponly without iprop

Greg Hudson ghudson at mit.edu
Wed Apr 25 11:43:40 EDT 2018


https://github.com/krb5/krb5/commit/20c0296e536b791d051db523cd067398a1c6441d
commit 20c0296e536b791d051db523cd067398a1c6441d
Author: sashan <anedvedicky at gmail.com>
Date:   Wed Apr 18 22:40:33 2018 +0200

    Improve error for kadmind -proponly without iprop
    
    If kadmind is run with the -proponly flag, check that iprop_enable is
    set and output a reasonable error message if it isn't.  Otherwise we
    see the confusing message "Invalid argument while initializing
    network".
    
    [ghudson at mit.edu: rewrote commit message; edited error message]
    
    ticket: 8673 (new)

 src/kadmin/server/ovsec_kadmd.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/src/kadmin/server/ovsec_kadmd.c b/src/kadmin/server/ovsec_kadmd.c
index 3d578ca..6a6b214 100644
--- a/src/kadmin/server/ovsec_kadmd.c
+++ b/src/kadmin/server/ovsec_kadmd.c
@@ -468,6 +468,10 @@ main(int argc, char *argv[])
         fail_to_start(0, _("Missing required realm configuration"));
     if (!(params.mask & KADM5_CONFIG_ACL_FILE))
         fail_to_start(0, _("Missing required ACL file configuration"));
+    if (proponly && !params.iprop_enabled) {
+        fail_to_start(0, _("-proponly can only be used when "
+                           "iprop_enable is true"));
+    }
 
     ret = setup_loop(&params, proponly, &vctx);
     if (ret)


More information about the cvs-krb5 mailing list