]> git.ipfire.org Git - thirdparty/krb5.git/commitdiff
* lock-test.c: Changed to include server_internal.h instead of adb.h.
authorMitchell Berger <mitchb@mit.edu>
Wed, 20 Jun 2001 08:16:10 +0000 (08:16 +0000)
committerMitchell Berger <mitchb@mit.edu>
Wed, 20 Jun 2001 08:16:10 +0000 (08:16 +0000)
(main): kadm5_server_handle_rec added for use with the new
osa_adb_open_policy calling sequence.

git-svn-id: svn://anonsvn.mit.edu/krb5/branches/incremental-propagation-branch@13408 dc483132-0cff-0310-8789-dd5450dbe970

src/lib/kadm5/unit-test/ChangeLog
src/lib/kadm5/unit-test/lock-test.c

index aa8b2fed873aeb11e8a67770d21b342ab6c8c310..318c0a685c6480666a5a6775a47a5f25d3b974c4 100644 (file)
@@ -1,3 +1,9 @@
+2001-06-20  Mitchell Berger  <mitchb@mit.edu>
+
+       * lock-test.c: Changed to include server_internal.h instead of adb.h.
+       (main): kadm5_server_handle_rec added for use with the new
+       osa_adb_open_policy calling sequence.
+
 2001-06-20  Mitchell Berger  <mitchb@mit.edu>
 
        * api.0/init.exp: Silly typo fixed.
index 256954c857be5aaa0d197b9e8c71a60f4747607b..faa4a442d6af715cde3fc0a5beb1d054430790bb 100644 (file)
@@ -6,7 +6,7 @@
 #include <stdio.h>
 #include <krb5.h>
 #include <kadm5/admin.h>
-#include <kadm5/adb.h>
+#include <kadm5/server_internal.h>
 
 char *whoami;
 
@@ -26,6 +26,7 @@ int main(int argc, char **argv)
      krb5_context context;
      kadm5_config_params params;
      krb5_error_code kret;
+     kadm5_server_handle_rec kadm5_handle;
 
      whoami = argv[0];
 
@@ -52,7 +53,14 @@ int main(int argc, char **argv)
          exit(1);
      }
 
-     ret = osa_adb_open_policy(&policy_db, &params);
+     /* XXX Horrible kludge.  To get the generation number to increase for
+      * policy updates, the handle to the policy db needs a handle to the
+      * principal db so it can do a kdb_get_entry on the master principal.
+      * The only things it looks at are the context and params.
+      */
+     kadm5_handle.context = context;
+     kadm5_handle.params = params;
+     ret = osa_adb_open_policy(&policy_db, &params, &kadm5_handle);
      if (ret != OSA_ADB_OK) {
          com_err(whoami, ret, "while opening database");
          exit(1);