From ea8129b5f025050620ec6338cdaf369df69d729c Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Tue, 29 Jul 2008 15:21:30 +0200 Subject: libnet keytab: use libnet_keytab_add_entry() in libnet_keytab_add(). This will in particular allow us to store ENCTYPE_NULL. Michael (This used to be commit 85c7e3ae29a6f25ed0b6917ff73baea9c6c905c6) --- source3/libnet/libnet_keytab.c | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git a/source3/libnet/libnet_keytab.c b/source3/libnet/libnet_keytab.c index 0b8327c38f..6fe718bb81 100644 --- a/source3/libnet/libnet_keytab.c +++ b/source3/libnet/libnet_keytab.c @@ -161,9 +161,7 @@ done: krb5_error_code libnet_keytab_add(struct libnet_keytab_context *ctx) { -#if defined(ENCTYPE_ARCFOUR_HMAC) krb5_error_code ret = 0; - krb5_enctype enctypes[2] = { ENCTYPE_ARCFOUR_HMAC, 0 }; int i; for (i=0; icount; i++) { @@ -174,14 +172,12 @@ krb5_error_code libnet_keytab_add(struct libnet_keytab_context *ctx) password.data = (char *)entry->password.data; password.length = entry->password.length; - ret = smb_krb5_kt_add_entry_ext(ctx->context, - ctx->keytab, - entry->kvno, - entry->principal, - enctypes, - password, - true, - true); + ret = libnet_keytab_add_entry(ctx->context, + ctx->keytab, + entry->kvno, + entry->principal, + entry->enctype, + password); if (ret) { DEBUG(1,("libnet_keytab_add: " "Failed to add entry to keytab file\n")); @@ -190,9 +186,6 @@ krb5_error_code libnet_keytab_add(struct libnet_keytab_context *ctx) } return ret; -#else - return -1; -#endif /* defined(ENCTYPE_ARCFOUR_HMAC) */ } struct libnet_keytab_entry *libnet_keytab_search(struct libnet_keytab_context *ctx, -- cgit