adapt to new hdb_seal_keys and hdb_unseal_keys

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@9595 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Assar Westerlund
2001-01-30 01:24:29 +00:00
parent 0e0d1336bd
commit c7c19f07f3
11 changed files with 102 additions and 43 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 1997-2000 Kungliga Tekniska H<>gskolan
* Copyright (c) 1997-2001 Kungliga Tekniska H<>gskolan
* (Royal Institute of Technology, Stockholm, Sweden).
* All rights reserved.
*
@@ -84,7 +84,9 @@ change(void *server_handle,
if (ret)
goto out2;
hdb_seal_keys(context->context, context->db, &ent);
ret = hdb_seal_keys(context->context, context->db, &ent);
if (ret)
goto out2;
kadm5_log_modify (context,
&ent,
@@ -156,7 +158,9 @@ kadm5_s_chpass_principal_with_key(void *server_handle,
if (ret)
goto out2;
hdb_seal_keys(context->context, context->db, &ent);
ret = hdb_seal_keys(context->context, context->db, &ent);
if (ret)
goto out2;
kadm5_log_modify (context,
&ent,

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 1997-2000 Kungliga Tekniska H<>gskolan
* Copyright (c) 1997-2001 Kungliga Tekniska H<>gskolan
* (Royal Institute of Technology, Stockholm, Sweden).
* All rights reserved.
*
@@ -124,7 +124,9 @@ kadm5_s_create_principal_with_key(void *server_handle,
if(ret)
goto out;
hdb_seal_keys(context->context, context->db, &ent);
ret = hdb_seal_keys(context->context, context->db, &ent);
if (ret)
goto out;
kadm5_log_create (context, &ent);
@@ -175,8 +177,12 @@ kadm5_s_create_principal(void *server_handle,
ent.keys.val[2].salt->type = hdb_pw_salt;
ent.keys.val[3].key.keytype = ETYPE_DES3_CBC_SHA1;
ret = _kadm5_set_keys(context, &ent, password);
if (ret)
goto out;
hdb_seal_keys(context->context, context->db, &ent);
ret = hdb_seal_keys(context->context, context->db, &ent);
if (ret)
goto out;
kadm5_log_create (context, &ent);

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 1998, 1999 Kungliga Tekniska H<>gskolan
* Copyright (c) 1997 - 2001 Kungliga Tekniska H<>gskolan
* (Royal Institute of Technology, Stockholm, Sweden).
* All rights reserved.
*
@@ -57,7 +57,9 @@ kadm5_s_delete_principal(void *server_handle, krb5_principal princ)
goto out;
}
hdb_seal_keys(context->context, context->db, &ent);
ret = hdb_seal_keys(context->context, context->db, &ent);
if (ret)
goto out;
kadm5_log_delete (context, princ);

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 1997-2000 Kungliga Tekniska H<>gskolan
* Copyright (c) 1997-2001 Kungliga Tekniska H<>gskolan
* (Royal Institute of Technology, Stockholm, Sweden).
* All rights reserved.
*
@@ -63,7 +63,9 @@ modify_principal(void *server_handle,
if(ret)
goto out2;
hdb_seal_keys(context->context, context->db, &ent);
ret = hdb_seal_keys(context->context, context->db, &ent);
if (ret)
goto out2;
kadm5_log_modify (context,
&ent,

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 1997-1999 Kungliga Tekniska H<>gskolan
* Copyright (c) 1997-2001 Kungliga Tekniska H<>gskolan
* (Royal Institute of Technology, Stockholm, Sweden).
* All rights reserved.
*
@@ -72,7 +72,9 @@ kadm5_s_randkey_principal(void *server_handle,
if (ret)
goto out2;
hdb_seal_keys(context->context, context->db, &ent);
ret = hdb_seal_keys(context->context, context->db, &ent);
if (ret)
goto out2;
kadm5_log_modify (context,
&ent,

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 1998, 1999 Kungliga Tekniska H<>gskolan
* Copyright (c) 1997 - 2001 Kungliga Tekniska H<>gskolan
* (Royal Institute of Technology, Stockholm, Sweden).
* All rights reserved.
*
@@ -82,7 +82,11 @@ kadm5_s_rename_principal(void *server_handle,
ent2.principal = ent.principal;
ent.principal = target;
hdb_seal_keys(context->context, context->db, &ent);
ret = hdb_seal_keys(context->context, context->db, &ent);
if (ret) {
ent.principal = ent2.principal;
goto out2;
}
kadm5_log_rename (context,
source,